summaryrefslogtreecommitdiff
path: root/drivers/media/usb/cx231xx
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2013-05-29 10:00:04 (GMT)
committerMauro Carvalho Chehab <mchehab@redhat.com>2013-06-17 11:55:19 (GMT)
commit04ae4cf2cb0c5963b0ea6554f573705c37172313 (patch)
tree2293ad219a4bb9c8d56768c0081cd5582cfa360f /drivers/media/usb/cx231xx
parentead5bc4e0bd94e4540bea60b782e2acdb345b803 (diff)
downloadlinux-04ae4cf2cb0c5963b0ea6554f573705c37172313.tar.xz
[media] cx231xx: the reg->size field wasn't filled in
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/usb/cx231xx')
-rw-r--r--drivers/media/usb/cx231xx/cx231xx-video.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/media/usb/cx231xx/cx231xx-video.c b/drivers/media/usb/cx231xx/cx231xx-video.c
index 54cdd4d..9906261 100644
--- a/drivers/media/usb/cx231xx/cx231xx-video.c
+++ b/drivers/media/usb/cx231xx/cx231xx-video.c
@@ -1272,36 +1272,43 @@ int cx231xx_g_register(struct file *file, void *priv,
(u16)reg->reg, value, 4);
reg->val = value[0] | value[1] << 8 |
value[2] << 16 | value[3] << 24;
+ reg->size = 4;
break;
case 1: /* AFE - read byte */
ret = cx231xx_read_i2c_data(dev, AFE_DEVICE_ADDRESS,
(u16)reg->reg, 2, &data, 1);
reg->val = data;
+ reg->size = 1;
break;
case 2: /* Video Block - read byte */
ret = cx231xx_read_i2c_data(dev, VID_BLK_I2C_ADDRESS,
(u16)reg->reg, 2, &data, 1);
reg->val = data;
+ reg->size = 1;
break;
case 3: /* I2S block - read byte */
ret = cx231xx_read_i2c_data(dev, I2S_BLK_DEVICE_ADDRESS,
(u16)reg->reg, 1, &data, 1);
reg->val = data;
+ reg->size = 1;
break;
case 4: /* AFE - read dword */
ret = cx231xx_read_i2c_data(dev, AFE_DEVICE_ADDRESS,
(u16)reg->reg, 2, &data, 4);
reg->val = data;
+ reg->size = 4;
break;
case 5: /* Video Block - read dword */
ret = cx231xx_read_i2c_data(dev, VID_BLK_I2C_ADDRESS,
(u16)reg->reg, 2, &data, 4);
reg->val = data;
+ reg->size = 4;
break;
case 6: /* I2S Block - read dword */
ret = cx231xx_read_i2c_data(dev, I2S_BLK_DEVICE_ADDRESS,
(u16)reg->reg, 1, &data, 4);
reg->val = data;
+ reg->size = 4;
break;
default:
return -EINVAL;