summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Bettis <jbettis@google.com>2022-05-06 12:43:31 -0600
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-05-09 16:51:52 +0000
commit1f7729ef769edef30b973df227f9acf4344ad295 (patch)
treeba796a3617d8f02ea5fed091abeee8f96a0a358a
parent1ada55a5a0cd164621d387741df87735d8f571ce (diff)
downloadchrome-ec-1f7729ef769edef30b973df227f9acf4344ad295.tar.gz
ec: Changes to get usb_tcpmv2_compliance to pass
The command `make clobber ; make TEST_ASAN=y run-usb_tcpmv2_compliance` doesn't pass because of several mismatched enums and an array out of bounds error. BRANCH=None BUG=b:214087135 TEST=make clobber ; make TEST_ASAN=y run-usb_tcpmv2_compliance Change-Id: I27cad82d2350e43c7891d5ff86e565553199cd7a Signed-off-by: Jeremy Bettis <jbettis@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3632185 Commit-Queue: Yuval Peress <peress@google.com> Reviewed-by: Jameson Thies <jthies@google.com> Auto-Submit: Jeremy Bettis <jbettis@chromium.org> Tested-by: Jeremy Bettis <jbettis@chromium.org> Reviewed-by: Yuval Peress <peress@google.com>
-rw-r--r--test/usb_tcpmv2_compliance_common.c2
-rw-r--r--test/usb_tcpmv2_td_pd_src3_e7.c2
-rw-r--r--test/usb_tcpmv2_td_pd_src3_e8.c2
-rw-r--r--test/usb_tcpmv2_td_pd_src3_e9.c2
4 files changed, 4 insertions, 4 deletions
diff --git a/test/usb_tcpmv2_compliance_common.c b/test/usb_tcpmv2_compliance_common.c
index 67aba61f52..6145f59388 100644
--- a/test/usb_tcpmv2_compliance_common.c
+++ b/test/usb_tcpmv2_compliance_common.c
@@ -366,7 +366,7 @@ int handle_attach_expected_msgs(enum pd_data_role data_role)
{
int rv;
int found_index;
- struct possible_tx possible[4];
+ struct possible_tx possible[5];
if (data_role == PD_ROLE_DFP) {
possible[0].tx_type = TCPCI_MSG_SOP;
diff --git a/test/usb_tcpmv2_td_pd_src3_e7.c b/test/usb_tcpmv2_td_pd_src3_e7.c
index 409d0d6b80..fa2c68b64e 100644
--- a/test/usb_tcpmv2_td_pd_src3_e7.c
+++ b/test/usb_tcpmv2_td_pd_src3_e7.c
@@ -76,7 +76,7 @@ int test_td_pd_src3_e7(void)
possible[1].tx_type = TCPCI_MSG_SOP;
possible[1].ctrl_msg = 0;
- possible[1].data_msg = PD_EXT_SOURCE_CAP;
+ possible[1].data_msg = PD_DATA_SOURCE_CAP;
TEST_EQ(verify_tcpci_possible_tx(possible,
2,
diff --git a/test/usb_tcpmv2_td_pd_src3_e8.c b/test/usb_tcpmv2_td_pd_src3_e8.c
index dee52f1753..b884156d43 100644
--- a/test/usb_tcpmv2_td_pd_src3_e8.c
+++ b/test/usb_tcpmv2_td_pd_src3_e8.c
@@ -86,7 +86,7 @@ int test_td_pd_src3_e8(void)
possible[1].tx_type = TCPCI_MSG_SOP;
possible[1].ctrl_msg = 0;
- possible[1].data_msg = PD_EXT_SOURCE_CAP;
+ possible[1].data_msg = PD_DATA_SOURCE_CAP;
TEST_EQ(verify_tcpci_possible_tx(possible,
2,
diff --git a/test/usb_tcpmv2_td_pd_src3_e9.c b/test/usb_tcpmv2_td_pd_src3_e9.c
index faeed0922d..49b8209669 100644
--- a/test/usb_tcpmv2_td_pd_src3_e9.c
+++ b/test/usb_tcpmv2_td_pd_src3_e9.c
@@ -82,7 +82,7 @@ int test_td_pd_src3_e9(void)
possible[1].tx_type = TCPCI_MSG_SOP;
possible[1].ctrl_msg = 0;
- possible[1].data_msg = PD_EXT_SOURCE_CAP;
+ possible[1].data_msg = PD_DATA_SOURCE_CAP;
TEST_EQ(verify_tcpci_possible_tx(possible,
2,