OSDN Git Service

i2c: dev: Handle 255 byte blocks for i2c ioctl
authorMatt Johnston <matt@codeconstruct.com.au>
Mon, 15 Nov 2021 02:49:22 +0000 (10:49 +0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 15 Nov 2021 14:11:24 +0000 (14:11 +0000)
commit84a107e68b34217eff536e81a6a6f419ee0d0f7e
tree3beaf1ebf78e6a4330445b81b4dba7b78dc8b453
parent13cae4a104d2b7205696229ba85d34cc035f8c84
i2c: dev: Handle 255 byte blocks for i2c ioctl

I2C_SMBUS is limited to 32 bytes due to compatibility with the
32 byte i2c_smbus_data.block

I2C_RDWR allows larger transfers if sufficient sized buffers are passed.

Signed-off-by: Matt Johnston <matt@codeconstruct.com.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/i2c/i2c-dev.c
include/uapi/linux/i2c-dev.h
include/uapi/linux/i2c.h