From 4cd6d9cede73423e21ca01405e5eae820487748f Mon Sep 17 00:00:00 2001 From: Diana Z Date: Tue, 16 Feb 2021 11:13:48 -0700 Subject: COIL: Rename GT7288 address define Rename GT7288 address definition to match current I2C naming conventions. BRANCH=None BUG=None TEST=make -j buildall Signed-off-by: Diana Z Change-Id: Ief917ff36510150d2a6ea03875d6e95dcb57c350 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2697857 Reviewed-by: Daisuke Nojiri --- driver/touchpad_gt7288.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/driver/touchpad_gt7288.c b/driver/touchpad_gt7288.c index ccc98622d5..ac05b88323 100644 --- a/driver/touchpad_gt7288.c +++ b/driver/touchpad_gt7288.c @@ -18,7 +18,7 @@ #define CPRINTS(format, args...) cprints(CC_TOUCHPAD, format, ## args) -#define GT7288_SLAVE_ADDRESS 0x14 +#define GT7288_I2C_ADDR_FLAGS 0x14 #define GT7288_REPORT_ID_PTP 0x04 @@ -47,7 +47,7 @@ static int gt7288_read_desc(uint16_t register_id, uint8_t *data, uint8_t reg_bytes[] = { register_id & 0xFF, (register_id & 0xFF00) >> 8 }; - return i2c_xfer(CONFIG_TOUCHPAD_I2C_PORT, GT7288_SLAVE_ADDRESS, + return i2c_xfer(CONFIG_TOUCHPAD_I2C_PORT, GT7288_I2C_ADDR_FLAGS, reg_bytes, sizeof(reg_bytes), data, max_length); } @@ -88,7 +88,7 @@ static void gt7288_translate_contact(const uint8_t *data, static int gt7288_read(uint8_t *data, size_t max_length) { - return i2c_xfer(CONFIG_TOUCHPAD_I2C_PORT, GT7288_SLAVE_ADDRESS, + return i2c_xfer(CONFIG_TOUCHPAD_I2C_PORT, GT7288_I2C_ADDR_FLAGS, NULL, 0, data, max_length); } -- cgit v1.2.1