aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJavier Martinez Canillas <javier@osg.samsung.com>2016-04-14 22:00:08 -0300
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2016-05-09 14:44:38 -0300
commiteca4ca84a965d7fcc3430439898d0728818edc56 (patch)
treed0d92f8a3d03fb218252d5bace02ff7b2b736d19
parentcacdd6a4a8d5115da2767769b44bd435455f6424 (diff)
[media] tvp5150: propagate I2C write error in .s_register callback
The tvp5150_write() function can fail so don't return 0 unconditionally in tvp5150_s_register() but propagate what's returned by tvp5150_write(). Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
-rw-r--r--drivers/media/i2c/tvp5150.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/i2c/tvp5150.c b/drivers/media/i2c/tvp5150.c
index 283836514e6a..0b6d46c453bf 100644
--- a/drivers/media/i2c/tvp5150.c
+++ b/drivers/media/i2c/tvp5150.c
@@ -1161,8 +1161,7 @@ static int tvp5150_g_register(struct v4l2_subdev *sd, struct v4l2_dbg_register *
static int tvp5150_s_register(struct v4l2_subdev *sd, const struct v4l2_dbg_register *reg)
{
- tvp5150_write(sd, reg->reg & 0xff, reg->val & 0xff);
- return 0;
+ return tvp5150_write(sd, reg->reg & 0xff, reg->val & 0xff);
}
#endif

Privacy Policy