diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2014-01-01 14:40:35 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2015-04-02 21:30:26 -0300 |
commit | 2d01209fd2d96cb9cd07b5c353efc47b525d71dc (patch) | |
tree | 806bb7e1b3685e638c372678ef6539c66e7e0b20 /drivers/media/i2c/mt9v032.c | |
parent | 7c3be9f812be6c2466ecb705200fc13cc34caa9c (diff) | |
download | linux-stable-2d01209fd2d96cb9cd07b5c353efc47b525d71dc.tar.gz linux-stable-2d01209fd2d96cb9cd07b5c353efc47b525d71dc.tar.bz2 linux-stable-2d01209fd2d96cb9cd07b5c353efc47b525d71dc.zip |
[media] v4l: mt9v032: Consider control initialization errors as fatal
The device requires control to be properly operated, they're not
optional.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/i2c/mt9v032.c')
-rw-r--r-- | drivers/media/i2c/mt9v032.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/media/i2c/mt9v032.c b/drivers/media/i2c/mt9v032.c index 3793d317772b..6d64e23b1f94 100644 --- a/drivers/media/i2c/mt9v032.c +++ b/drivers/media/i2c/mt9v032.c @@ -961,9 +961,12 @@ static int mt9v032_probe(struct i2c_client *client, mt9v032->subdev.ctrl_handler = &mt9v032->ctrls; - if (mt9v032->ctrls.error) - printk(KERN_INFO "%s: control initialization error %d\n", - __func__, mt9v032->ctrls.error); + if (mt9v032->ctrls.error) { + dev_err(&client->dev, "control initialization error %d\n", + mt9v032->ctrls.error); + ret = mt9v032->ctrls.error; + goto err; + } mt9v032->crop.left = MT9V032_COLUMN_START_DEF; mt9v032->crop.top = MT9V032_ROW_START_DEF; |