[PATCH v2 0/2] USB Type-C mode selection

From: Andrei Kuchynski

Date: Thu Oct 08 2026 - 09:44:45 EST


This patch series introduces priority-based alternate mode selection
support for cros_ec_typec.
The base patch series and UCSI support was submitted here:
https://lore.kernel.org/all/20260119131824.2529334-1-akuchynski@xxxxxxxxxxxx/

When AP-driven alternate mode selection is active, the driver enforces the
mode_selection bit for each registered Alternate Mode. This blocks
individual altmode drivers from self-activating. Once registration
completes, the driver evaluates USB4 capability. If USB4 is unsupported,
it falls back to priority-based negotiation via typec_mode_selection_start.

Additionally, we swap the registration sequence of the port's alternate
modes. Registering DisplayPort after Thunderbolt correctly ensures DP is
prioritized.

Changes in v2:
- Added this cover letter.
- Rebased on top of the latest platform-chrome tree.
- Tested on Redrix with Linux Fedora 7.3.0-rc5+.
v1 Link:
https://lore.kernel.org/all/20260129131928.794768-1-akuchynski@xxxxxxxxxxxx/

Andrei Kuchynski (2):
platform/chrome: cros_ec_typec: Enforce priority-based mode selection
platform/chrome: cros_ec_typec: Reorder altmode registration

drivers/platform/chrome/cros_ec_typec.c | 61 ++++++++++++++++----
drivers/platform/chrome/cros_typec_altmode.c | 8 ++-
2 files changed, 55 insertions(+), 14 deletions(-)

--
2.56.0.360.g66cac248cb-goog