]> git.ipfire.org Git - people/arne_f/kernel.git/commit
usb: Avoid unnecessary LPM enabling and disabling during suspend and resume
authorMathias Nyman <mathias.nyman@linux.intel.com>
Thu, 15 Jun 2017 08:55:41 +0000 (11:55 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 15 Jun 2017 20:17:46 +0000 (22:17 +0200)
commitd590c23111505635e1beb01006612971e5ede8aa
tree001f8af0444da754732623cc4e8a5b99778b4e21
parentce046e5d9b489554c29ae9277cdc2f86dee76a84
usb: Avoid unnecessary LPM enabling and disabling during suspend and resume

The original motivation for disabling/enabling Link PM at device
suspend/resume was to force link state to go via U0 before suspend sets
the link state to U3. Going directly from U2 to U3 is not allowed.

Disabling LPM will forced the link state to U0, but will send a lot of
Set port feature requests for evert suspend and resume.

This is not needed as Hub hardware will take care of going via U0
when a U2 -> U3 transition is requested [1]

[1] USB 3.1 specification section 10.16.2.10 Set Port Feature:

"If the value is 3, then host software wants to selectively suspend the
device connected to this port. The hub shall transition the link to U3
from any of the other U states using allowed link state transitions.
If the port is not already in the U0 state, then it shall transition the
port to the U0 state and then initiate the transition to U3.
While this state is active, the hub does not propagate downstream-directed
traffic to this port, but the hub will respond to resume signaling from the
port"

Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/core/hub.c