diff options
author | Wolfram Sang | 2016-04-03 20:45:01 +0200 |
---|---|---|
committer | Wolfram Sang | 2016-04-11 18:54:59 +0200 |
commit | a51a79d50ebc21d47f73f1e7f695ef2f86ef3417 (patch) | |
tree | 16c4d9976f013e6f10ff35e98f90764af9aaaff9 /drivers | |
parent | 5c1274fab5c10aa193f5740dd76780010bda77d7 (diff) |
i2c: st: 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')
-rw-r--r-- | drivers/i2c/busses/i2c-st.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/i2c/busses/i2c-st.c b/drivers/i2c/busses/i2c-st.c index 6ee77159ac57..b3c182fea165 100644 --- a/drivers/i2c/busses/i2c-st.c +++ b/drivers/i2c/busses/i2c-st.c @@ -614,8 +614,7 @@ static int st_i2c_xfer_msg(struct st_i2c_dev *i2c_dev, struct i2c_msg *msg, unsigned long timeout; int ret; - c->addr = (u8)(msg->addr << 1); - c->addr |= (msg->flags & I2C_M_RD); + c->addr = i2c_8bit_addr_from_msg(msg); c->buf = msg->buf; c->count = msg->len; c->xfered = 0; |