summaryrefslogtreecommitdiff
path: root/zephyr/shim/include/usbc/tcpc_generic_emul.h
blob: 9000dfdf2024330a8f9d0da6ad468dafeeff3bd4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
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 "driver/tcpm/tcpci.h"

#include <zephyr/devicetree.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,                \
	},