summaryrefslogtreecommitdiff
path: root/include/mock/usb_tc_sm_mock.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/mock/usb_tc_sm_mock.h')
-rw-r--r--include/mock/usb_tc_sm_mock.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/include/mock/usb_tc_sm_mock.h b/include/mock/usb_tc_sm_mock.h
new file mode 100644
index 0000000000..f56f6c7a0d
--- /dev/null
+++ b/include/mock/usb_tc_sm_mock.h
@@ -0,0 +1,20 @@
+/* Copyright 2020 The Chromium OS Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+/* Mock USB TC state machine*/
+
+#ifndef __MOCK_USB_TC_SM_MOCK_H
+#define __MOCK_USB_TC_SM_MOCK_H
+
+#include "common.h"
+#include "usb_tc_sm.h"
+
+struct mock_tc_port_t {
+ int pd_enable;
+ enum tcpc_rp_value lcl_rp;
+};
+
+extern struct mock_tc_port_t mock_tc_port[CONFIG_USB_PD_PORT_MAX_COUNT];
+
+#endif /* __MOCK_USB_TC_SM_MOCK_H */