scsi: Fix 'unused variable' warning in scsi.c
PATCH 1/1 scsi: Fix 'unused variable' warning in scsi.c
From: John Daiker <[email protected]>
This patch applies cleanly to 2.6.19-git7
Fixes the following warning:
CC drivers/scsi/scsi.odrivers/scsi/scsi.c: In function ‘scsi_device_put’:drivers/scsi/scsi.c:874: warning: unused variable ‘module’
Signed-off-by John Daiker <[email protected]>
---drivers/scsi/scsi.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
drivers/scsi/scsi.c +0 -0
@@ -871,9 +871,9 @@ EXPORT_SYMBOL(scsi_device_get);
*/
void scsi_device_put(struct scsi_device *sdev) {
+#ifdef CONFIG_MODULE_UNLOAD
struct module *module = sdev->host->hostt->module;
-#ifdef CONFIG_MODULE_UNLOAD
/* The module refcount will be zero if scsi_device_get()
* was called from a module removal routine */ if (module && module_refcount(module) != 0)