diff options
Diffstat (limited to 'driver/ioexpander')
-rw-r--r-- | driver/ioexpander/it8801.c | 8 | ||||
-rw-r--r-- | driver/ioexpander/it8801.h | 3 |
2 files changed, 6 insertions, 5 deletions
diff --git a/driver/ioexpander/it8801.c b/driver/ioexpander/it8801.c index ebe1809f18..165e88f1df 100644 --- a/driver/ioexpander/it8801.c +++ b/driver/ioexpander/it8801.c @@ -22,14 +22,14 @@ static int it8801_ioex_set_level(int ioex, int port, int mask, int value); static int it8801_read(int reg, int *data) { - return i2c_read8(I2C_PORT_IO_EXPANDER_IT8801, IT8801_I2C_ADDR, - reg, data); + return i2c_read8(IT8801_KEYBOARD_PWM_I2C_PORT, + IT8801_KEYBOARD_PWM_I2C_ADDR_FLAGS, reg, data); } static int it8801_write(int reg, int data) { - return i2c_write8(I2C_PORT_IO_EXPANDER_IT8801, IT8801_I2C_ADDR, - reg, data); + return i2c_write8(IT8801_KEYBOARD_PWM_I2C_PORT, + IT8801_KEYBOARD_PWM_I2C_ADDR_FLAGS, reg, data); } struct it8801_vendor_id_t { diff --git a/driver/ioexpander/it8801.h b/driver/ioexpander/it8801.h index 2b16c40bd6..ec38bba6af 100644 --- a/driver/ioexpander/it8801.h +++ b/driver/ioexpander/it8801.h @@ -10,7 +10,8 @@ #define __CROS_EC_IO_EXPANDER_IT8801_H /* I2C address flags (7-bit without R/W) */ -#define IT8801_I2C_ADDR 0x38 +#define IT8801_I2C_ADDR1 0x38 +#define IT8801_I2C_ADDR2 0x39 /* Keyboard Matrix Scan control (KBS) */ #define IT8801_REG_KSOMCR 0x40 |