diff options
author | Mika Westerberg <mika.westerberg@linux.intel.com> | 2016-02-18 11:54:13 +0300 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2016-02-19 18:52:45 +0300 |
commit | 5c6fab9d558470b4e53c6d113f7dbcb31049ffc5 (patch) | |
tree | 13253ccc8e2f0fc4b5364100ec8b0ceb02dd186e /drivers/ata/ahci.h | |
parent | 356fd2663cff131fb9db573a3e45830778cfdbdd (diff) | |
download | linux-5c6fab9d558470b4e53c6d113f7dbcb31049ffc5.tar.xz |
scsi: Drop runtime PM usage count after host is added
Runtime PM of the SCSI host is already handled by calls to
scsi_autopm_get_host() and scsi_autopm_put_host() from appropriate places
whenever the host needs to be powered on. This works fine when there is
device connected to the host as once it runtime suspends the host will too.
However, if there is no device connected the host is never runtime
suspended (the usage counter is always 0).
Allow runtime suspend of host even if it has no devices connected by
calling scsi_autopm_put_host() at the end of scsi_add_host_with_dma(). We
temporarily increase runtime PM usage counter first so call to
scsi_autopm_put_host() will result idle request to be scheduled for the
device.
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'drivers/ata/ahci.h')
0 files changed, 0 insertions, 0 deletions