public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] SCSI: remove dev->power.power_state from mesh driver
@ 2008-03-07 16:20 Alan Stern
  2008-05-23 20:53 ` [linux-pm] " Alan Stern
  2008-05-24 10:21 ` Paul Mackerras
  0 siblings, 2 replies; 5+ messages in thread
From: Alan Stern @ 2008-03-07 16:20 UTC (permalink / raw)
  To: James Bottomley
  Cc: Paul Mackerras, Benjamin Herrenschmidt, Linux-pm mailing list,
	SCSI development list

power.power_state is scheduled for removal.  This patch (as1055)
removes all uses of that field from the SCSI mesh driver.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
CC: Paul Mackerras <paulus@au.ibm.com>
CC: Benjamin Herrenschmidt <benh@kernel.crashing.org>

---

Index: usb-2.6/drivers/scsi/mesh.c
===================================================================
--- usb-2.6.orig/drivers/scsi/mesh.c
+++ usb-2.6/drivers/scsi/mesh.c
@@ -1765,7 +1765,7 @@ static int mesh_suspend(struct macio_dev
 	default:
 		return 0;
 	}
-	if (mesg.event == mdev->ofdev.dev.power.power_state.event)
+	if (ms->phase == sleeping)
 		return 0;
 
 	scsi_block_requests(ms->host);
@@ -1780,8 +1780,6 @@ static int mesh_suspend(struct macio_dev
 	disable_irq(ms->meshintr);
 	set_mesh_power(ms, 0);
 
-	mdev->ofdev.dev.power.power_state = mesg;
-
 	return 0;
 }
 
@@ -1790,7 +1788,7 @@ static int mesh_resume(struct macio_dev 
 	struct mesh_state *ms = (struct mesh_state *)macio_get_drvdata(mdev);
 	unsigned long flags;
 
-	if (mdev->ofdev.dev.power.power_state.event == PM_EVENT_ON)
+	if (ms->phase != sleeping)
 		return 0;
 
 	set_mesh_power(ms, 1);
@@ -1801,8 +1799,6 @@ static int mesh_resume(struct macio_dev 
 	enable_irq(ms->meshintr);
 	scsi_unblock_requests(ms->host);
 
-	mdev->ofdev.dev.power.power_state.event = PM_EVENT_ON;
-
 	return 0;
 }
 


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2008-05-24 10:21 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-07 16:20 [PATCH] SCSI: remove dev->power.power_state from mesh driver Alan Stern
2008-05-23 20:53 ` [linux-pm] " Alan Stern
2008-05-23 21:07   ` James Bottomley
2008-05-23 22:02     ` Benjamin Herrenschmidt
2008-05-24 10:21 ` Paul Mackerras

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox