diff options
Diffstat (limited to 'Documentation/usb/power-management.txt')
-rw-r--r-- | Documentation/usb/power-management.txt | 34 |
1 files changed, 30 insertions, 4 deletions
diff --git a/Documentation/usb/power-management.txt b/Documentation/usb/power-management.txt index c9ffa9ced7ee..12511c98cc4f 100644 --- a/Documentation/usb/power-management.txt +++ b/Documentation/usb/power-management.txt | |||
@@ -439,10 +439,10 @@ cause autosuspends to fail with -EBUSY if the driver needs to use the | |||
439 | device. | 439 | device. |
440 | 440 | ||
441 | External suspend calls should never be allowed to fail in this way, | 441 | External suspend calls should never be allowed to fail in this way, |
442 | only autosuspend calls. The driver can tell them apart by checking | 442 | only autosuspend calls. The driver can tell them apart by applying |
443 | the PM_EVENT_AUTO bit in the message.event argument to the suspend | 443 | the PMSG_IS_AUTO() macro to the message argument to the suspend |
444 | method; this bit will be set for internal PM events (autosuspend) and | 444 | method; it will return True for internal PM events (autosuspend) and |
445 | clear for external PM events. | 445 | False for external PM events. |
446 | 446 | ||
447 | 447 | ||
448 | Mutual exclusion | 448 | Mutual exclusion |
@@ -487,3 +487,29 @@ succeed, it may still remain active and thus cause the system to | |||
487 | resume as soon as the system suspend is complete. Or the remote | 487 | resume as soon as the system suspend is complete. Or the remote |
488 | wakeup may fail and get lost. Which outcome occurs depends on timing | 488 | wakeup may fail and get lost. Which outcome occurs depends on timing |
489 | and on the hardware and firmware design. | 489 | and on the hardware and firmware design. |
490 | |||
491 | |||
492 | xHCI hardware link PM | ||
493 | --------------------- | ||
494 | |||
495 | xHCI host controller provides hardware link power management to usb2.0 | ||
496 | (xHCI 1.0 feature) and usb3.0 devices which support link PM. By | ||
497 | enabling hardware LPM, the host can automatically put the device into | ||
498 | lower power state(L1 for usb2.0 devices, or U1/U2 for usb3.0 devices), | ||
499 | which state device can enter and resume very quickly. | ||
500 | |||
501 | The user interface for controlling USB2 hardware LPM is located in the | ||
502 | power/ subdirectory of each USB device's sysfs directory, that is, in | ||
503 | /sys/bus/usb/devices/.../power/ where "..." is the device's ID. The | ||
504 | relevant attribute files is usb2_hardware_lpm. | ||
505 | |||
506 | power/usb2_hardware_lpm | ||
507 | |||
508 | When a USB2 device which support LPM is plugged to a | ||
509 | xHCI host root hub which support software LPM, the | ||
510 | host will run a software LPM test for it; if the device | ||
511 | enters L1 state and resume successfully and the host | ||
512 | supports USB2 hardware LPM, this file will show up and | ||
513 | driver will enable hardware LPM for the device. You | ||
514 | can write y/Y/1 or n/N/0 to the file to enable/disable | ||
515 | USB2 hardware LPM manually. This is for test purpose mainly. | ||