summaryrefslogtreecommitdiff
path: root/Documentation/ABI/testing/sysfs-bus-usb
diff options
context:
space:
mode:
authorMichael Grzeschik <m.grzeschik@pengutronix.de>2022-06-07 13:45:22 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-06-12 06:49:46 +0200
commitf061f43d7418cb62b8d073e221ec75d3f5b89e17 (patch)
tree59d311ae1af0105d165ee26ec129c122c9e6e545 /Documentation/ABI/testing/sysfs-bus-usb
parent5fd6c4f0a649c956b2c50c18e0da765b7f5e3eff (diff)
downloadlwn-f061f43d7418cb62b8d073e221ec75d3f5b89e17.tar.gz
lwn-f061f43d7418cb62b8d073e221ec75d3f5b89e17.zip
usb: hub: port: add sysfs entry to switch port power
In some cases the port of an hub needs to be disabled or switched off and on again. E.g. when the connected device needs to be re-enumerated. Or it needs to be explicitly disabled while the rest of the usb tree stays working. For this purpose this patch adds an sysfs switch to enable/disable the port on any hub. In the case the hub is supporting power switching, the power line will be disabled to the connected device. When the port gets disabled, the associated device gets disconnected and removed from the logical usb tree. No further device will be enumerated on that port until the port gets enabled again. Reviewed-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de> Link: https://lore.kernel.org/r/20220607114522.3359148-1-m.grzeschik@pengutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'Documentation/ABI/testing/sysfs-bus-usb')
-rw-r--r--Documentation/ABI/testing/sysfs-bus-usb11
1 files changed, 11 insertions, 0 deletions
diff --git a/Documentation/ABI/testing/sysfs-bus-usb b/Documentation/ABI/testing/sysfs-bus-usb
index 7efe31ed3a25..568103d3376e 100644
--- a/Documentation/ABI/testing/sysfs-bus-usb
+++ b/Documentation/ABI/testing/sysfs-bus-usb
@@ -253,6 +253,17 @@ Description:
only if the system firmware is capable of describing the
connection between a port and its connector.
+What: /sys/bus/usb/devices/.../<hub_interface>/port<X>/disable
+Date: June 2022
+Contact: Michael Grzeschik <m.grzeschik@pengutronix.de>
+Description:
+ This file controls the state of a USB port, including
+ Vbus power output (but only on hubs that support
+ power switching -- most hubs don't support it). If
+ a port is disabled, the port is unusable: Devices
+ attached to the port will not be detected, initialized,
+ or enumerated.
+
What: /sys/bus/usb/devices/.../power/usb2_lpm_l1_timeout
Date: May 2013
Contact: Mathias Nyman <mathias.nyman@linux.intel.com>