summaryrefslogtreecommitdiff
path: root/Documentation/ABI
diff options
context:
space:
mode:
authorAndrei Kuchynski <akuchynski@chromium.org>2026-01-19 13:18:20 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2026-01-23 17:18:01 +0100
commit027b304ca3f6989f6946b5b3bcc727cf3f54774f (patch)
tree980fb1a0605f873a3ad8f0ffbd3cd2922313a018 /Documentation/ABI
parent4ec128733f68f77af452b0d97d8688cd33cd963e (diff)
downloadlinux-next-027b304ca3f6989f6946b5b3bcc727cf3f54774f.tar.gz
linux-next-027b304ca3f6989f6946b5b3bcc727cf3f54774f.zip
usb: typec: Expose alternate mode priority via sysfs
This patch introduces a priority sysfs attribute to the USB Type-C alternate mode port interface. This new attribute allows user-space to configure the numeric priority of alternate modes managing their preferred order of operation. If a new priority value conflicts with an existing mode's priority, the priorities of the conflicting mode and all subsequent modes are automatically incremented to ensure uniqueness. Signed-off-by: Andrei Kuchynski <akuchynski@chromium.org> Reviewed-by: Benson Leung <bleung@chromium.org> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Link: https://patch.msgid.link/20260119131824.2529334-4-akuchynski@chromium.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'Documentation/ABI')
-rw-r--r--Documentation/ABI/testing/sysfs-class-typec11
1 files changed, 11 insertions, 0 deletions
diff --git a/Documentation/ABI/testing/sysfs-class-typec b/Documentation/ABI/testing/sysfs-class-typec
index 38e101c17a00..737b76828b50 100644
--- a/Documentation/ABI/testing/sysfs-class-typec
+++ b/Documentation/ABI/testing/sysfs-class-typec
@@ -162,6 +162,17 @@ Description: Lists the supported USB Modes. The default USB mode that is used
- usb3 (USB 3.2)
- usb4 (USB4)
+What: /sys/class/typec/<port>/<alt-mode>/priority
+Date: July 2025
+Contact: Andrei Kuchynski <akuchynski@chromium.org>
+Description:
+ Displays and allows setting the priority for a specific alternate mode.
+ The priority is an integer in the range 0-255. A lower numerical value
+ indicates a higher priority (0 is the highest).
+ If the new value is already in use by another mode, the priority of the
+ conflicting mode and any subsequent modes will be incremented until they
+ are all unique.
+
USB Type-C partner devices (eg. /sys/class/typec/port0-partner/)
What: /sys/class/typec/<port>-partner/accessory_mode