[SCSI] add flag to skip the runtime PM calls on the host
authorLin Ming <ming.m.lin@intel.com>
Mon, 5 Dec 2011 01:20:24 +0000 (09:20 +0800)
committerJeff Garzik <jgarzik@redhat.com>
Mon, 9 Jan 2012 00:14:57 +0000 (19:14 -0500)
commitae0751ffc77e7f21629970fdab5528c573e637f8
treee42ad3d5a5d2c5b742c6b129fd3bb532f29389f7
parent9a6d6a2ddabbd32c07f6a38b659e5f3db319fa5a
[SCSI] add flag to skip the runtime PM calls on the host

With previous change, now the ata port runtime suspend will happen as:

disk suspend --> scsi target suspend --> scsi host suspend --> ata port
suspend

ata port(parent device) suspend need to schedule scsi EH which will resume
scsi host(child device). Then the child device resume will in turn make
parent device resume first. This is kind of recursive.

This patch adds a new flag Scsi_Host::eh_noresume.
ata port will set this flag to skip the runtime PM calls on scsi host.

Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
drivers/scsi/scsi_error.c
include/scsi/scsi_host.h