diff options
author | Diana Z <dzigterman@chromium.org> | 2022-10-20 11:22:35 -0600 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-10-27 22:39:29 +0000 |
commit | f0cd67d2e3fa39179749aaf9200128cf0d6d675f (patch) | |
tree | c1fb2cbdd8a114a737937a9e3e1afe761104d597 /include | |
parent | 57060e966622b8a856f81fa9c45bef17452bdc19 (diff) | |
download | chrome-ec-f0cd67d2e3fa39179749aaf9200128cf0d6d675f.tar.gz |
TCPMv2: Generalize VDM Attention send in DPM
The VDM Attenion interface as it is could be used to generally send any
VDM REQ, so open up the interface for such a use.
BRANCH=None
BUG=b:208884535
TEST=make -j buildall
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: I680b6ef2679d515b1500482de9a31a2e5470262e
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3969858
Code-Coverage: Zoss <zoss-cl-coverage@prod.google.com>
Reviewed-by: Abe Levkoy <alevkoy@chromium.org>
Reviewed-by: Scott Collyer <scollyer@chromium.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/usb_pd.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/include/usb_pd.h b/include/usb_pd.h index c5e8a4fb06..92580252a5 100644 --- a/include/usb_pd.h +++ b/include/usb_pd.h @@ -2906,18 +2906,19 @@ void pd_notify_event(int port, uint32_t event_mask); void pd_clear_events(int port, uint32_t clear_mask); /* - * Requests a VDM Attention message be sent. Attention is the only SVDM message - * that does not result in a response from the port partner. In addition, if - * it's a DP Attention message, then it will be requested from outside of the - * port's PD task. + * Requests a VDM REQ message be sent. It is assumed that this message may be + * coming from a task outside the PD task. * * @param port USB-C port number * @param *data pointer to the VDM Attention message * @param vdo_count number of VDOs (must be 1 or 2) + * @param tx_type partner type to transmit * @return EC_RES_SUCCESS if a VDM message is scheduled. + * EC_RES_BUSY if a message is already pending + * EC_RES_INVALID_PARAM if the parameters given are invalid */ -enum ec_status pd_request_vdm_attention(int port, const uint32_t *data, - int vdo_count); +enum ec_status pd_request_vdm(int port, const uint32_t *data, int vdo_count, + enum tcpci_msg_type tx_type); /* * Requests that the port enter the specified mode. A successful result just |