History

platform/chrome: cros_ec: Add VDM attention headers

Incorporate updates to the EC headers to support the retrieval of VDM Attention messages from port partners. These headers are already present in the ChromeOS EC codebase. [1] [1] https://source.chromium.org/chromium/chromiumos/platform/ec/+/main:include/ec_commands.h

Prashant Malani committed 3 years ago

Commit 4b1936c1 parent 478f32a1 file · +13 −3Browse files

Showing the changes to include/linux/platform_data (1 of 1 file). Show all

Unified · Split

include/linux/platform_data/cros_ec_commands.h+13−3
@@ -5862,6 +5862,7 @@ enum tcpc_cc_polarity { · 5861 unmodified lines
58625862 #define PD_STATUS_EVENT_MUX_1_SET_DONE BIT(5)
58635863 #define PD_STATUS_EVENT_VDM_REQ_REPLY BIT(6)
58645864 #define PD_STATUS_EVENT_VDM_REQ_FAILED BIT(7)
5865+#define PD_STATUS_EVENT_VDM_ATTENTION BIT(8)
58655866
58665867 struct ec_params_typec_status {
58675868 uint8_t port;
@@ -5906,7 +5907,8 @@ struct ec_response_typec_status { · 38 unmodified lines
59065907 } __ec_align1;
59075908
59085909 /*
5909− * Gather the response to the most recent VDM REQ from the AP
5910+ * Gather the response to the most recent VDM REQ from the AP, as well
5911+ * as popping the oldest VDM:Attention from the DPM queue
59105912 */
59115913 #define EC_CMD_TYPEC_VDM_RESPONSE 0x013C
59125914
@@ -5919,10 +5921,18 @@ struct ec_response_typec_vdm_response { · 6 unmodified lines
59195921 uint8_t vdm_data_objects;
59205922 /* Partner to address - see enum typec_partner_type */
59215923 uint8_t partner_type;
5922− /* Reserved */
5923− uint16_t reserved;
5924+ /* enum ec_status describing VDM response */
5925+ uint16_t vdm_response_err;
59245926 /* VDM data, including VDM header */
59255927 uint32_t vdm_response[VDO_MAX_SIZE];
5928+ /* Number of 32-bit Attention fields filled in */
5929+ uint8_t vdm_attention_objects;
5930+ /* Number of remaining messages to consume */
5931+ uint8_t vdm_attention_left;
5932+ /* Reserved */
5933+ uint16_t reserved1;
5934+ /* VDM:Attention contents */
5935+ uint32_t vdm_attention[2];
59265936 } __ec_align1;
59275937
59285938 #undef VDO_MAX_SIZE

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t