[PATCH v8 00/18] port power control reworks

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Changes since v7 [1]:
* Added patch 8 "usb: make usb_port flags atomic"

* Added patch 15 "usb: hub_handle_remote_wakeup() depends on
  CONFIG_PM_RUNTIME=y"

* Fixed patch 16 "usb: resume (wakeup) child device when port is powered
  on"
  - added USB_PORTDEV_WAKE flag to force usb_remote_wakeup() in
    hub_handle_remote_wakeup()

* Added a port_event() comment in patch 13 "usb: synchronize port
  poweroff and khubd"

* Reworked patch 12 "usb: refactor port handling in hub_events()" to
  avoid indentation churn and a cleanup to consolidate calls to
  usb_reset_device()

See a summary of the review state of the series below.

=====

This series addresses the following disconnect scenarios when attempting
to use port power-off.

1/ Superspeed devices downgrade to their hispeed connection when
   rx-detection fails on the superspeed pins.  Address this by
   preventing superspeed port poweroff/suspension until the peer port is
   suspended, and powering on the superspeed port before the hispeed
   port is resumed.  This depends on the ability to identify peer ports
   (patches 4-7, and patch 9 implements the policy).

2/ khubd prematurely disconnects ports that are in the process of being
   resumed or reset.  After this series khubd will ignore ports in the
   pm-runtime-suspended or suspending state, or force active ports in the
   resuming state (patch 13).  While it is running it holds a new port
   status lock to synchronize the port status changes of
   usb_port_{suspend|resume} and usb_reset_and_verify_device() (patch 14).

3/ Superspeed devices fail to reconnect after a 2 second timeout  This
   event has two causes:

   3.1/ Repeated {Set|Clear}PortFeature(PORT_POWER) toggles results in
        the the device switching to its hispeed connection (due to
        perceived instability of the superspeed connection).  Address
        this by arranging for the child device to be woken up
        and complete a resume cycle when the parent port resumes (patch 16).

   3.2/ Devices may require a warm reset when recovering the power
        session.  When the child device is woken up per above and the
        port timed out on reconnect, force a warm-reset during the
        child's reset-resume (patch 17).

[1]: v7: http://marc.info/?l=linux-usb&m=139526512014030&w=2

---

ACK => Acked-by: Alan Stern <stern@xxxxxxxxxxxxxxxxxxx>
ack => Acked-by another reviewer

ACK [01/18] usb: disable port power control if not supported in wHubCharacteristics
ACK [02/18] usb: rename usb_port device objects
ACK [03/18] usb: cleanup setting udev->removable from port_dev->connect_type
ACK [04/18] usb: assign default peer ports for root hubs
ACK [05/18] usb: assign usb3 external hub port peers
ACK [06/18] usb: find internal hub tier mismatch via acpi
ACK [07/18] usb: sysfs link peer ports
    [08/18] usb: make usb_port flags atomic
ACK [09/18] usb: block suspension of superspeed port while hispeed peer is active
ACK [10/18] usb: don't clear FEAT_C_ENABLE on usb_port_runtime_resume failure
ACK [11/18] usb: usb3 ports do not support FEAT_C_ENABLE
    [12/18] usb: refactor port handling in hub_events()
    [13/18] usb: synchronize port poweroff and khubd
    [14/18] usb: introduce port status lock
    [15/18] usb: hub_handle_remote_wakeup() depends on CONFIG_PM_RUNTIME=y
    [16/18] usb: resume (wakeup) child device when port is powered on
ack [17/18] usb: force warm reset to break link re-connect livelock
    [18/18] usb: documentation for usb port power off mechanisms

 Documentation/usb/power-management.txt |  242 +++++++++-
 drivers/usb/core/hcd.c                 |   45 ++-
 drivers/usb/core/hub.c                 |  877 +++++++++++++++++---------------
 drivers/usb/core/hub.h                 |   48 ++-
 drivers/usb/core/port.c                |  297 ++++++++++-
 drivers/usb/core/usb-acpi.c            |  107 ++---
 drivers/usb/core/usb.h                 |   16 +-
 7 files changed, 1110 insertions(+), 522 deletions(-)
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux