diff options
author | Denis Brockus <dbrockus@chromium.org> | 2019-07-16 15:10:11 -0600 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-07-20 23:09:18 +0000 |
commit | 473bd883b60fd5b00377766dae2bacad246de0d2 (patch) | |
tree | 992d9f03104277934c22c869eceb634e2cf5f7ec /driver/als_bh1730.c | |
parent | 053491b560d2c4e374bb739373d8ae25c41f6315 (diff) | |
download | chrome-ec-473bd883b60fd5b00377766dae2bacad246de0d2.tar.gz |
Remove __7b, __8b and __7bf
The extentions were added to make the compiler perform most
of the verification that the conversion was being done correctly
to remove 8bit addressing as the standard I2C/SPI address type.
Now that the compiler has verified the code, the extra
extentions are being removed
BUG=chromium:971296
BRANCH=none
TEST=make buildall -j
TEST=verify sensor functionality on arcada_ish
Change-Id: I36894f8bb9daefb5b31b5e91577708f6f9af2a4f
Signed-off-by: Denis Brockus <dbrockus@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1704792
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Diffstat (limited to 'driver/als_bh1730.c')
-rw-r--r-- | driver/als_bh1730.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/driver/als_bh1730.c b/driver/als_bh1730.c index 4b0b50e0a1..9480b4c5f0 100644 --- a/driver/als_bh1730.c +++ b/driver/als_bh1730.c @@ -62,7 +62,7 @@ static int bh1730_read_lux(const struct motion_sensor_t *s, intv3_t v) int data0_1; /* read data0 and data1 from sensor */ - ret = i2c_read32__7bf(s->port, s->i2c_spi_addr__7bf, + ret = i2c_read32(s->port, s->i2c_spi_addr_flags, BH1730_DATA0LOW, &data0_1); if (ret != EC_SUCCESS) { CPRINTF("bh1730_read_lux - fail %d\n", ret); @@ -137,7 +137,7 @@ static int bh1730_init(const struct motion_sensor_t *s) int ret; /* power and measurement bit high */ - ret = i2c_write8__7bf(s->port, s->i2c_spi_addr__7bf, + ret = i2c_write8(s->port, s->i2c_spi_addr_flags, BH1730_CONTROL, BH1730_CONTROL_POWER_ENABLE | BH1730_CONTROL_ADC_EN_ENABLE); @@ -148,14 +148,14 @@ static int bh1730_init(const struct motion_sensor_t *s) } /* set timing */ - ret = i2c_write8__7bf(s->port, s->i2c_spi_addr__7bf, + ret = i2c_write8(s->port, s->i2c_spi_addr_flags, BH1730_TIMING, BH1730_CONF_ITIME); if (ret != EC_SUCCESS) { CPRINTF("bh1730_init_sensor - time fail %d\n", ret); return ret; } /* set ADC gain */ - ret = i2c_write8__7bf(s->port, s->i2c_spi_addr__7bf, + ret = i2c_write8(s->port, s->i2c_spi_addr_flags, BH1730_GAIN, BH1730_CONF_GAIN); if (ret != EC_SUCCESS) { |