[PATCH v1 0/3] Restrict alternate modes based on cable capabilities
From: Andrei Kuchynski
Date: Thu Jun 11 2026 - 08:22:22 EST
Currently, alternate mode drivers (like DisplayPort and Thunderbolt)
automatically assign operational callbacks (`typec_altmode_set_ops`)
during probing, even if the underlying cable capabilities cannot support
them. This can lead to incorrectly advertised state configurations or
initialization failures later on.
The first patch introduces the core helper function, and the subsequent
patches update the DisplayPort and Thunderbolt altmode drivers to
utilize this check during their respective probe phases.
Andrei Kuchynski (3):
usb: typec: Add helper to check cable altmode support
usb: typec: thunderbolt: Check cable altmode support
usb: typec: displayport: Check cable altmode support
drivers/usb/typec/altmodes/displayport.c | 5 +++-
drivers/usb/typec/altmodes/thunderbolt.c | 4 +++
drivers/usb/typec/class.c | 35 ++++++++++++++++++++++++
include/linux/usb/typec.h | 1 +
4 files changed, 44 insertions(+), 1 deletion(-)
--
2.54.0.1099.g489fc7bff1-goog