On 01/23/2013 02:09 AM, Aaron Lu wrote:
This patch adds runtime pm support for sr. It did this by increasing the runtime usage_count of the device when its block device is accessed. And decreasing the runtime usage_count of the device when the access is done. If there is media inside, runtime suspend is not allowed as we don't always know if the ODD is being used or not. The idea is discussed here: http://thread.gmane.org/gmane.linux.acpi.devel/55243/focus=52703 and the restriction to check media inside is discussed here: http://thread.gmane.org/gmane.linux.ide/53665/focus=58836 Signed-off-by: Aaron Lu <aaron.lu@xxxxxxxxx> Acked-by: Alan Stern <stern@xxxxxxxxxxxxxxxxxxx> Acked-by: James Bottomley <James.Bottomley@xxxxxxxxxxxxxxxxxxxxx> --- drivers/scsi/sr.c | 42 +++++++++++++++++++++++++++++++++++++++--- 1 file changed, 39 insertions(+), 3 deletions(-)
applied 1-3 -- To unsubscribe from this list: send the line "unsubscribe linux-ide" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html