diff options
author | Yuval Peress <peress@chromium.org> | 2020-12-10 00:27:07 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-01-15 03:55:44 +0000 |
commit | 3e278c99fdb82b839fafd8972402440e952c2cd4 (patch) | |
tree | a44db9b67b6383dedd09bb3ed99735bbd4275594 | |
parent | 432a327eb418c23e667443315a5255a8425df170 (diff) | |
download | chrome-ec-3e278c99fdb82b839fafd8972402440e952c2cd4.tar.gz |
volteer: Remove dependency on npcx specific registers
This change removes the dependency on the npcx specific headers
which are normally included via registers.h. It instead transitions
to relying on i2c/i2c.h which defines various enums and the
NAMED_I2C macro.
BUG=b:175249000
TEST=zmake testall
Cq-Depend: chromium:2582819
Change-Id: I7d8e98cc4228496b0c7603c0794eb92e0f79c01d
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/zephyr-chrome/+/2583272
Tested-by: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2630155
Reviewed-by: Simon Glass <sjg@chromium.org>
-rw-r--r-- | zephyr/projects/volteer/include/i2c_map.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/zephyr/projects/volteer/include/i2c_map.h b/zephyr/projects/volteer/include/i2c_map.h index de174e311a..337a056ebd 100644 --- a/zephyr/projects/volteer/include/i2c_map.h +++ b/zephyr/projects/volteer/include/i2c_map.h @@ -11,15 +11,15 @@ #include "config.h" /* We need registers.h to get the chip specific defines for now */ -#include "registers.h" +#include "i2c/i2c.h" #define I2C_PORT_ACCEL I2C_PORT_SENSOR -#define I2C_PORT_SENSOR NPCX_I2C_PORT0_0 -#define I2C_PORT_USB_C0 NPCX_I2C_PORT1_0 -#define I2C_PORT_USB_C1 NPCX_I2C_PORT2_0 -#define I2C_PORT_USB_1_MIX NPCX_I2C_PORT3_0 -#define I2C_PORT_POWER NPCX_I2C_PORT5_0 -#define I2C_PORT_EEPROM NPCX_I2C_PORT7_0 +#define I2C_PORT_SENSOR NAMED_I2C(sensor) +#define I2C_PORT_USB_C0 NAMED_I2C(usb_c0) +#define I2C_PORT_USB_C1 NAMED_I2C(usb_c1) +#define I2C_PORT_USB_1_MIX NAMED_I2C(usb1_mix) +#define I2C_PORT_POWER NAMED_I2C(power) +#define I2C_PORT_EEPROM NAMED_I2C(eeprom) #define I2C_ADDR_EEPROM_FLAGS 0x50 |