diff options
author | Ahbong Chang <cwahbong@google.com> | 2018-03-31 16:17:34 +0800 |
---|---|---|
committer | Wolfram Sang <wsa@the-dreams.de> | 2018-04-03 16:37:45 +0200 |
commit | 4a3f7691e2f722421b231d3f3fa05b0a6670a20a (patch) | |
tree | 9ee72890001907a7f908ac2ecbfc05c9883edda1 /drivers/i2c | |
parent | d9a22d713acb484f9d60861598a71e28129c0afa (diff) | |
download | linux-4a3f7691e2f722421b231d3f3fa05b0a6670a20a.tar.bz2 |
i2c: fix parameter of trace_i2c_result
According to the event i2c_result defined in include/trace/events/i2c.h,
the second parameter should be the number of messages instead of the
ended loop index. The value of ended loop index is the same as ret.
Signed-off-by: Ahbong Chang <cwahbong@google.com>
Reviewed-by: Todd Poynor <toddpoynor@google.com>
Reviewed-by: David Howells <dhowells@redhat.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c')
-rw-r--r-- | drivers/i2c/i2c-core-base.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/i2c-core-base.c b/drivers/i2c/i2c-core-base.c index c8bfe008f208..a7909d196f4c 100644 --- a/drivers/i2c/i2c-core-base.c +++ b/drivers/i2c/i2c-core-base.c @@ -1876,7 +1876,7 @@ int __i2c_transfer(struct i2c_adapter *adap, struct i2c_msg *msgs, int num) for (i = 0; i < ret; i++) if (msgs[i].flags & I2C_M_RD) trace_i2c_reply(adap, &msgs[i], i); - trace_i2c_result(adap, i, ret); + trace_i2c_result(adap, num, ret); } return ret; |