summaryrefslogtreecommitdiff
path: root/include/linux/usb/tcpci.h
diff options
context:
space:
mode:
authorRD Babiera <rdbabiera@google.com>2024-01-08 19:16:17 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-01-27 17:38:25 -0800
commit3bbb9ba4f66006f27ad0d5ceaf2480117e16d489 (patch)
tree51cf759b0b04a5f633f1adff6ce77e1672582c33 /include/linux/usb/tcpci.h
parent59cd27a0cab1ceddcc4251309fd3643921ed9ab9 (diff)
usb: typec: tcpci: add tcpm_transmit_type to tcpm_pd_receive
tcpm_pd_receive adds the SOP type as a parameter, and passes it within the pd_rx_event struct for tcpm_pd_rx_handler to use. For now, the handler drops all SOP' messages. Maxim based tcpci drivers are capable of SOP' communication, so process_rx now takes the SOP type into account and passes the value to tcpm_pd_receive. tcpci_set_pd_rx now utilizes the cable_comm_capable flag to determine if TCPC_RX_DETECT_SOP1 should be added to the bitfield when enabling PD message reception. For all other consumers of tcpm_pd_receive, default the new field to TCPC_TX_SOP. Signed-off-by: RD Babiera <rdbabiera@google.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Link: https://lore.kernel.org/r/20240108191620.987785-18-rdbabiera@google.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/usb/tcpci.h')
-rw-r--r--include/linux/usb/tcpci.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/usb/tcpci.h b/include/linux/usb/tcpci.h
index 1d0b849defd0..9ed6d62c9c5f 100644
--- a/include/linux/usb/tcpci.h
+++ b/include/linux/usb/tcpci.h
@@ -145,6 +145,7 @@
#define TCPC_RX_BYTE_CNT 0x30
#define TCPC_RX_BUF_FRAME_TYPE 0x31
#define TCPC_RX_BUF_FRAME_TYPE_SOP 0
+#define TCPC_RX_BUF_FRAME_TYPE_SOP1 1
#define TCPC_RX_HDR 0x32
#define TCPC_RX_DATA 0x34 /* through 0x4f */