[PATCH v2 0/2] usb: typec: ucsi_ccg: Add CC orientation sensing via GPIO
From: Akash Kumar
Date: Mon Nov 23 2026 - 04:10:36 EST
From: Akash Kumar <akakum@xxxxxxxxxxxxxxxx>
The CCGx chip has no HPI register exposing CC polarity, so on boards
that wire a sense line to the connector, pick it up via an optional
orientation-gpios property and report it through typec_set_orientation().
Patch 1 adds the dt-binding property, patch 2 wires it up in the
ucsi_ccg driver.
Changes in v2:
- Reworked ucsi_ccg_connector_status() to return early when the GPIO
read fails instead of wrapping the call in typec_set_orientation()
in a positive-case conditional (Heikki Krogerus).
Akash Kumar (2):
dt-bindings: usb: cypress,cypd4226: Add orientation-gpios property
usb: typec: ucsi_ccg: Add CC orientation sensing via GPIO
.../bindings/usb/cypress,cypd4226.yaml | 10 +++
drivers/usb/typec/ucsi/ucsi_ccg.c | 77 ++++++++++++++++++-
2 files changed, 86 insertions(+), 1 deletion(-)
base-commit: 8e31dedb9ad496ea7dd7064d77d6f7d459c1c90f
prerequisite-patch-id: 0ffa67d7d9ce66074ffa2e070249ee5b0cbedb2e
prerequisite-patch-id: 65ba14bc52b50cdf47ecdce1f4b3fe678704955e
--
2.43.0