diff options
author | Wolfram Sang <wsa@the-dreams.de> | 2016-04-03 20:44:48 +0200 |
---|---|---|
committer | Wolfram Sang <wsa@the-dreams.de> | 2016-04-11 18:54:59 +0200 |
commit | 191d738d847e63b24da7cacbdfb179e5b5a9145f (patch) | |
tree | 7465bfcbd01840bc52a9d1ef6587905a640b3d4b /drivers/i2c/busses/i2c-bcm-kona.c | |
parent | 32822bff880bd9c3b55145e258d03dc671f0d2ea (diff) | |
download | linux-191d738d847e63b24da7cacbdfb179e5b5a9145f.tar.bz2 |
i2c: bcm-kona: use new 8 bit address helper function
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c/busses/i2c-bcm-kona.c')
-rw-r--r-- | drivers/i2c/busses/i2c-bcm-kona.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/i2c/busses/i2c-bcm-kona.c b/drivers/i2c/busses/i2c-bcm-kona.c index 2c9d9b1c8e64..ac9f47679c3a 100644 --- a/drivers/i2c/busses/i2c-bcm-kona.c +++ b/drivers/i2c/busses/i2c-bcm-kona.c @@ -501,10 +501,7 @@ static int bcm_kona_i2c_do_addr(struct bcm_kona_i2c_dev *dev, return -EREMOTEIO; } } else { - addr = msg->addr << 1; - - if (msg->flags & I2C_M_RD) - addr |= 1; + addr = i2c_8bit_addr_from_msg(msg); if (bcm_kona_i2c_write_byte(dev, addr, 0) < 0) return -EREMOTEIO; |