From: Bart Van Assche <bvanassche@acm.org>
To: Bart Van Assche <bvanassche@acm.org>
Cc: linux-scsi <linux-scsi@vger.kernel.org>,
James Bottomley <jbottomley@parallels.com>,
Mike Christie <michaelc@cs.wisc.edu>,
Jun'ichi Nomura <j-nomura@ce.jp.nec.com>,
Stefan Richter <stefanr@s5r6.in-berlin.de>
Subject: [PATCH 3/4] scsi: Change return type of scsi_queue_insert() into void
Date: Tue, 05 Jun 2012 17:12:46 +0000 [thread overview]
Message-ID: <4FCE3E0E.3000802@acm.org> (raw)
In-Reply-To: <4FCE3D20.4000205@acm.org>
The return value of scsi_queue_insert() is ignored by all its
callers, hence change the return type of this function into
void.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Cc: James Bottomley <JBottomley@parallels.com>
Cc: Mike Christie <michaelc@cs.wisc.edu>
Cc: <stable@kernel.org>
---
drivers/scsi/scsi_lib.c | 8 +++-----
drivers/scsi/scsi_priv.h | 2 +-
2 files changed, 4 insertions(+), 6 deletions(-)
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
index c26ef49..082c1e5 100644
--- a/drivers/scsi/scsi_lib.c
+++ b/drivers/scsi/scsi_lib.c
@@ -109,7 +109,7 @@ static void scsi_unprep_request(struct request *req)
* for a requeue after completion, which should only occur in this
* file.
*/
-static int __scsi_queue_insert(struct scsi_cmnd *cmd, int reason, int unbusy)
+static void __scsi_queue_insert(struct scsi_cmnd *cmd, int reason, int unbusy)
{
struct Scsi_Host *host = cmd->device->host;
struct scsi_device *device = cmd->device;
@@ -162,8 +162,6 @@ static int __scsi_queue_insert(struct scsi_cmnd *cmd, int reason, int unbusy)
spin_unlock_irqrestore(q->queue_lock, flags);
kblockd_schedule_work(q, &device->requeue_work);
-
- return 0;
}
/*
@@ -185,9 +183,9 @@ static int __scsi_queue_insert(struct scsi_cmnd *cmd, int reason, int unbusy)
* Notes: This could be called either from an interrupt context or a
* normal process context.
*/
-int scsi_queue_insert(struct scsi_cmnd *cmd, int reason)
+void scsi_queue_insert(struct scsi_cmnd *cmd, int reason)
{
- return __scsi_queue_insert(cmd, reason, 1);
+ __scsi_queue_insert(cmd, reason, 1);
}
/**
* scsi_execute - insert request and wait for the result
diff --git a/drivers/scsi/scsi_priv.h b/drivers/scsi/scsi_priv.h
index 2b8d8b5..cacb0e7 100644
--- a/drivers/scsi/scsi_priv.h
+++ b/drivers/scsi/scsi_priv.h
@@ -79,7 +79,7 @@ int scsi_noretry_cmd(struct scsi_cmnd *scmd);
/* scsi_lib.c */
extern int scsi_maybe_unblock_host(struct scsi_device *sdev);
extern void scsi_device_unbusy(struct scsi_device *sdev);
-extern int scsi_queue_insert(struct scsi_cmnd *cmd, int reason);
+extern void scsi_queue_insert(struct scsi_cmnd *cmd, int reason);
extern void scsi_next_command(struct scsi_cmnd *cmd);
extern void scsi_io_completion(struct scsi_cmnd *, unsigned int);
extern void scsi_run_host_queues(struct Scsi_Host *shost);
next prev parent reply other threads:[~2012-06-05 17:12 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-05 17:08 [PATCH 0/4 v7] Fixes for SCSI device removal Bart Van Assche
2012-06-05 17:10 ` [PATCH 1/4] block: Fix race on request_queue.end_io invocations Bart Van Assche
2012-06-05 21:32 ` Tejun Heo
2012-06-06 12:44 ` Bart Van Assche
2012-06-06 12:45 ` Jens Axboe
2012-06-06 13:10 ` Bart Van Assche
2012-06-05 17:11 ` [PATCH 2/4] scsi: Fix device removal NULL pointer dereference Bart Van Assche
2012-06-05 17:12 ` Bart Van Assche [this message]
2012-06-05 17:14 ` [PATCH 4/4] scsi: Stop accepting SCSI requests before removing a device Bart Van Assche
2012-06-05 21:36 ` Mike Christie
2012-06-06 12:17 ` Bart Van Assche
2012-06-06 13:29 ` Mike Christie
2012-06-06 14:53 ` Bart Van Assche
2012-06-06 15:21 ` Mike Christie
2012-06-05 22:08 ` Mike Christie
2012-06-06 12:25 ` Bart Van Assche
2012-06-06 13:43 ` Mike Christie
2012-06-06 14:01 ` Mike Christie
2012-06-06 14:12 ` Mike Christie
2012-06-06 15:04 ` Bart Van Assche
2012-06-06 15:28 ` Mike Christie
2012-06-06 16:18 ` Bart Van Assche
2012-06-06 15:07 ` Bart Van Assche
-- strict thread matches above, loose matches on Subject: below --
2012-06-07 18:39 [PATCH 0/4 v8] Fixes for SCSI device removal Bart Van Assche
2012-06-07 18:44 ` [PATCH 3/4] scsi: Change return type of scsi_queue_insert() into void Bart Van Assche
2012-06-25 18:12 [PATCH 0/4 v9] SCSI device removal fixes Bart Van Assche
2012-06-25 18:16 ` [PATCH 3/4] scsi: Change return type of scsi_queue_insert() into void Bart Van Assche
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=4FCE3E0E.3000802@acm.org \
--to=bvanassche@acm.org \
--cc=j-nomura@ce.jp.nec.com \
--cc=jbottomley@parallels.com \
--cc=linux-scsi@vger.kernel.org \
--cc=michaelc@cs.wisc.edu \
--cc=stefanr@s5r6.in-berlin.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.