[media] media/i2c: fill in missing reg->size fields
authorHans Verkuil <hans.verkuil@cisco.com>
Wed, 29 May 2013 10:00:07 +0000 (07:00 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Mon, 17 Jun 2013 11:56:55 +0000 (08:56 -0300)
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Cc: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/i2c/ak881x.c
drivers/media/i2c/soc_camera/mt9t031.c
drivers/media/i2c/soc_camera/tw9910.c
drivers/media/i2c/tvp7002.c

index fcd8a3f626fa64961b447bd918c371a7e2fcc122..c14e66756b98471e0e3833303bd996b272895cac 100644 (file)
@@ -69,6 +69,7 @@ static int ak881x_g_register(struct v4l2_subdev *sd,
        if (reg->reg > 0x26)
                return -EINVAL;
 
+       reg->size = 1;
        reg->val = reg_read(client, reg->reg);
 
        if (reg->val > 0xffff)
index 1d2cc27767feea1a65920cf8edbe5b18e7d84e2a..8f71c9a02cf0a7c7116bffe1742b6fe1f4ef6c9e 100644 (file)
@@ -398,6 +398,7 @@ static int mt9t031_g_register(struct v4l2_subdev *sd,
        if (reg->reg > 0xff)
                return -EINVAL;
 
+       reg->size = 1;
        reg->val = reg_read(client, reg->reg);
 
        if (reg->val > 0xffff)
index 8a2ac244d0b3f907f88e948152dd0d1e89163d5d..b5407dfad4ce852147490c88868b3583283e6af2 100644 (file)
@@ -527,6 +527,7 @@ static int tw9910_g_register(struct v4l2_subdev *sd,
        if (reg->reg > 0xff)
                return -EINVAL;
 
+       reg->size = 1;
        ret = i2c_smbus_read_byte_data(client, reg->reg);
        if (ret < 0)
                return ret;
index c2d0280ef3dcdfbff3adf458da2c2b4de69ecef1..36ad565e5a3310a7e7f2441e710969e545ee7f8c 100644 (file)
@@ -722,6 +722,7 @@ static int tvp7002_g_register(struct v4l2_subdev *sd,
 
        ret = tvp7002_read(sd, reg->reg & 0xff, &val);
        reg->val = val;
+       reg->size = 1;
        return ret;
 }