USB: UHCI: fix for suspend of virtual HP controller
authorAlan Stern <stern@rowland.harvard.edu>
Tue, 14 May 2013 17:55:29 +0000 (13:55 -0400)
committerBen Hutchings <ben@decadent.org.uk>
Thu, 30 May 2013 13:35:00 +0000 (14:35 +0100)
commit4e3a840b91c1591888fdec16fbd50e15cb1d6a63
tree4fb86073fa31c95dc39c6b41527e78ec42ee25ca
parent90f20d722e132a7e2a2588c3d11734a375fe7bd7
USB: UHCI: fix for suspend of virtual HP controller

commit 997ff893603c6455da4c5e26ba1d0f81adfecdfc upstream.

HP's virtual UHCI host controller takes a long time to suspend
(several hundred microseconds), even when no devices are attached.
This provokes a warning message from uhci-hcd in the auto-stop case.

To prevent this from happening, this patch adds a test to avoid
performing an auto-stop when the wait_for_hp quirk flag is set.  The
controller will still suspend through the normal runtime PM mechanism.
And since that pathway includes a 1-ms delay, the slowness of the
virtual hardware won't matter.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Reported-and-tested-by: ZhenHua <zhen-hual@hp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
drivers/usb/host/uhci-hub.c