diff options
Diffstat (limited to 'zephyr/shim/include/usbc/tcpc_generic_emul.h')
-rw-r--r-- | zephyr/shim/include/usbc/tcpc_generic_emul.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/zephyr/shim/include/usbc/tcpc_generic_emul.h b/zephyr/shim/include/usbc/tcpc_generic_emul.h new file mode 100644 index 0000000000..7dc46c51ba --- /dev/null +++ b/zephyr/shim/include/usbc/tcpc_generic_emul.h @@ -0,0 +1,20 @@ +/* Copyright 2022 The ChromiumOS Authors + * Use of this source code is governed by a BSD-style license that can be + * found in the LICENSE file. + */ + +#include <zephyr/devicetree.h> + +#include "driver/tcpm/tcpci.h" + +#define TCPCI_EMUL_COMPAT cros_tcpci_generic_emul + +#define TCPC_CONFIG_TCPCI_EMUL(id) \ + { \ + .bus_type = EC_BUS_TYPE_I2C, \ + .i2c_info = { \ + .port = I2C_PORT_BY_DEV(id), \ + .addr_flags = DT_REG_ADDR(id), \ + }, \ + .drv = &tcpci_tcpm_drv, \ + }, |