i2c: dev: Check for I2C_FUNC_I2C before calling i2c_transfer
It is good practice to check that the underlying adapter supports I2C transfers before attempting them. The i2c core would eventually return an error, but it's more efficient to fail early. Signed-off-by:Jean Delvare <jdelvare@suse.de> Reviewed-by:
Andi Shyti <andi.shyti@kernel.org> Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com>
Loading
Please sign in to comment