mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Michael Opdenacker <michael.opdenacker@free-electrons.com>
To: harshavardhan.r.kharche@intel.com, ashutosh.dixit@intel.com,
	gregkh@linuxfoundation.org, nikhil.rao@intel.com,
	sudeep.dutt@intel.com
Cc: linux-kernel@vger.kernel.org,
	Michael Opdenacker <michael.opdenacker@free-electrons.com>
Subject: [PATCH] misc: mic: dead code removal and minor cleanup
Date: Sat,  9 Nov 2013 05:13:42 +0100	[thread overview]
Message-ID: <1383970422-16973-1-git-send-email-michael.opdenacker@free-electrons.com> (raw)

This removes the below test in drivers/misc/mic/card/mic_virtio.c:

if (!retry) {
...
}

This is dead code because the "retry" variable was set to 100
earlier in the same function.

This also removes dev_dbg statements to print the value of this variable.
That's not interesting to print the value of a variable which value is
always the same.

Signed-off-by: Michael Opdenacker <michael.opdenacker@free-electrons.com>
---
 drivers/misc/mic/card/mic_virtio.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/misc/mic/card/mic_virtio.c b/drivers/misc/mic/card/mic_virtio.c
index 914cc9b2caad..0f387504b3fa 100644
--- a/drivers/misc/mic/card/mic_virtio.c
+++ b/drivers/misc/mic/card/mic_virtio.c
@@ -167,8 +167,6 @@ static void mic_reset_inform_host(struct virtio_device *vdev)
 		msleep(100);
 	};
 
-	dev_dbg(mic_dev(mvdev), "%s: retry: %d\n", __func__, retry);
-
 	/* Reset status to 0 in case we timed out */
 	iowrite8(0, &mvdev->desc->status);
 }
@@ -337,12 +335,6 @@ static int mic_find_vqs(struct virtio_device *vdev, unsigned nvqs,
 		msleep(100);
 	};
 
-	dev_dbg(mic_dev(mvdev), "%s: retry: %d\n", __func__, retry);
-	if (!retry) {
-		err = -ENODEV;
-		goto error;
-	}
-
 	return 0;
 error:
 	mic_del_vqs(vdev);
-- 
1.8.1.2


             reply	other threads:[~2013-11-09  4:14 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-09  4:13 Michael Opdenacker [this message]
2013-11-09  5:06 ` Dixit, Ashutosh
2013-11-09  5:35   ` Michael Opdenacker

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1383970422-16973-1-git-send-email-michael.opdenacker@free-electrons.com \
    --to=michael.opdenacker@free-electrons.com \
    --cc=ashutosh.dixit@intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=harshavardhan.r.kharche@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nikhil.rao@intel.com \
    --cc=sudeep.dutt@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®