From: Wolfram Sang Date: Sun, 3 Apr 2016 18:44:49 +0000 (+0200) Subject: i2c: brcmstb: use new 8 bit address helper function X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=fa5ce47a994867e79bd595ec2eef5178834c2570;p=linux-beck.git i2c: brcmstb: use new 8 bit address helper function Reviewed-by: Andy Shevchenko Signed-off-by: Wolfram Sang --- diff --git a/drivers/i2c/busses/i2c-brcmstb.c b/drivers/i2c/busses/i2c-brcmstb.c index 4a45408dd820..6a8cfc1344b2 100644 --- a/drivers/i2c/busses/i2c-brcmstb.c +++ b/drivers/i2c/busses/i2c-brcmstb.c @@ -446,9 +446,7 @@ static int brcmstb_i2c_do_addr(struct brcmstb_i2c_dev *dev, } } else { - addr = msg->addr << 1; - if (msg->flags & I2C_M_RD) - addr |= 1; + addr = i2c_8bit_addr_from_msg(msg); bsc_writel(dev, addr, chip_address); }