commit | 1eace8344c02c625ee99cc3ffa50187ded2c87b5 | [log] [tgz] |
---|---|---|
author | Ard Biesheuvel <ard.biesheuvel@linaro.org> | Tue Apr 03 21:11:50 2018 +0200 |
committer | Wolfram Sang <wsa@the-dreams.de> | Wed Apr 11 23:33:46 2018 +0200 |
tree | b8aabc3206f9064036a78593069ddf824f095aa2 | |
parent | 090cecc669d4336a6ce2eeaa3074b628d3fb7678 [diff] |
i2c: add param sanity check to i2c_transfer() The API docs describe i2c_transfer() as taking a pointer to an array of i2c_msg containing at least 1 entry, but leaves it to the individual drivers to sanity check the msgs and num parameters. Let's do this in core code instead. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> [wsa: changed '<= 0' to '< 1'] Signed-off-by: Wolfram Sang <wsa@the-dreams.de>