diff options
Diffstat (limited to 'zephyr/shim/include/usbc/tcpc_nct38xx.h')
-rw-r--r-- | zephyr/shim/include/usbc/tcpc_nct38xx.h | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/zephyr/shim/include/usbc/tcpc_nct38xx.h b/zephyr/shim/include/usbc/tcpc_nct38xx.h index 87b222c794..87ba3379c8 100644 --- a/zephyr/shim/include/usbc/tcpc_nct38xx.h +++ b/zephyr/shim/include/usbc/tcpc_nct38xx.h @@ -1,4 +1,4 @@ -/* Copyright 2021 The Chromium OS Authors. All rights reserved. +/* Copyright 2021 The ChromiumOS Authors * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ @@ -11,16 +11,15 @@ #define NCT38XX_TCPC_COMPAT nuvoton_nct38xx -#define TCPC_CONFIG_NCT38XX(id) \ - { \ - .bus_type = EC_BUS_TYPE_I2C, \ - .i2c_info = { \ - .port = I2C_PORT(DT_PHANDLE(id, port)), \ - .addr_flags = DT_STRING_UPPER_TOKEN( \ - id, i2c_addr_flags), \ - }, \ - .drv = &nct38xx_tcpm_drv, \ - .flags = DT_PROP(id, tcpc_flags), \ +#define TCPC_CONFIG_NCT38XX(id) \ + { \ + .bus_type = EC_BUS_TYPE_I2C, \ + .i2c_info = { \ + .port = I2C_PORT_BY_DEV(id), \ + .addr_flags = DT_REG_ADDR(id), \ + }, \ + .drv = &nct38xx_tcpm_drv, \ + .flags = DT_PROP(id, tcpc_flags), \ }, /** |