diff options
author | Dan Williams <dan.j.williams@intel.com> | 2014-05-21 03:09:20 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-05-28 01:51:50 +0200 |
commit | 097a155f05e88dc71184ceb93ad1aab1a13d1e41 (patch) | |
tree | 04cd559056bf81a6b53cbba88c41d0247f884f8a /arch | |
parent | usb: refactor port handling in hub_events() (diff) | |
download | linux-097a155f05e88dc71184ceb93ad1aab1a13d1e41.tar.xz linux-097a155f05e88dc71184ceb93ad1aab1a13d1e41.zip |
usb: synchronize port poweroff and khubd
If a port is powered-off, or in the process of being powered-off, prevent
khubd from operating on it. Otherwise, the following sequence of events
leading to an unintended disconnect may occur:
Events:
(0) <set pm_qos_no_poweroff to '0' for port1>
(1) hub 2-2:1.0: hub_resume
(2) hub 2-2:1.0: port 1: status 0301 change 0000
(3) hub 2-2:1.0: state 7 ports 4 chg 0002 evt 0000
(4) hub 2-2:1.0: port 1, power off status 0000, change 0000, 12 Mb/s
(5) usb 2-2.1: USB disconnect, device number 5
Description:
(1) hub is resumed before sending a ClearPortFeature request
(2) hub_activate() notices the port is connected and sets
hub->change_bits for the port
(3) hub_events() starts, but at the same time the port suspends
(4) hub_connect_change() sees the disabled port and triggers disconnect
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch')
0 files changed, 0 insertions, 0 deletions