linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] [SCSI] scsi_pm: fix passing incompatible pointer for scsi_device_resume()
@ 2012-05-19 10:08 Axel Lin
  0 siblings, 0 replies; only message in thread
From: Axel Lin @ 2012-05-19 10:08 UTC (permalink / raw)
  To: linux-kernel; +Cc: Aaron Lu, Alan Stern, James Bottomley, linux-scsi

Fix below build warning:

  CC      drivers/scsi/scsi_pm.o
drivers/scsi/scsi_pm.c: In function 'scsi_dev_type_suspend':
drivers/scsi/scsi_pm.c:30:5: warning: passing argument 1 of 'scsi_device_resume' from incompatible pointer type [enabled by default]
include/scsi/scsi_device.h:368:13: note: expected 'struct scsi_device *' but argument is of type 'struct device *'

Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
 drivers/scsi/scsi_pm.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/scsi_pm.c b/drivers/scsi/scsi_pm.c
index 9bd2c41..d4201de 100644
--- a/drivers/scsi/scsi_pm.c
+++ b/drivers/scsi/scsi_pm.c
@@ -27,7 +27,7 @@ static int scsi_dev_type_suspend(struct device *dev, pm_message_t msg)
 		if (drv && drv->suspend) {
 			err = drv->suspend(dev, msg);
 			if (err)
-				scsi_device_resume(dev);
+				scsi_device_resume(to_scsi_device(dev));
 		}
 	}
 	dev_dbg(dev, "scsi suspend: %d\n", err);
-- 
1.7.5.4




^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-05-19 10:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-19 10:08 [PATCH] [SCSI] scsi_pm: fix passing incompatible pointer for scsi_device_resume() Axel Lin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).