diff options
author | Sylwester Nawrocki <s.nawrocki@samsung.com> | 2011-11-15 22:55:17 +0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-12-30 20:38:54 +0400 |
commit | f428948b98e3b9476057ee483e7e763a5ac61a69 (patch) | |
tree | 9c698f17522a6d3b749bbb617dbf1a2e0e2af8a1 /drivers/media/video/m5mols | |
parent | aa1f4601ed35820a9bd720cc5b1e3fe3c4ff7c5f (diff) | |
download | linux-f428948b98e3b9476057ee483e7e763a5ac61a69.tar.xz |
[media] m5mols: Do not reset the configured pixel format when unexpected
Initialize default pixel format in driver probe() rather than in
s_power handler. This also prevents resetting the configuration
applied before the device was powered on.
Acked-by: HeungJun Kim <riverful.kim@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/m5mols')
-rw-r--r-- | drivers/media/video/m5mols/m5mols_core.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/media/video/m5mols/m5mols_core.c b/drivers/media/video/m5mols/m5mols_core.c index ea594cf0fa56..12f223f3d0fd 100644 --- a/drivers/media/video/m5mols/m5mols_core.c +++ b/drivers/media/video/m5mols/m5mols_core.c @@ -864,13 +864,6 @@ static int m5mols_s_power(struct v4l2_subdev *sd, int on) ret = m5mols_sensor_power(info, true); if (!ret) ret = m5mols_fw_start(sd); - if (ret) - return ret; - - info->ffmt[M5MOLS_RESTYPE_MONITOR] = - m5mols_default_ffmt[M5MOLS_RESTYPE_MONITOR]; - info->ffmt[M5MOLS_RESTYPE_CAPTURE] = - m5mols_default_ffmt[M5MOLS_RESTYPE_CAPTURE]; return ret; } @@ -1007,6 +1000,8 @@ static int __devinit m5mols_probe(struct i2c_client *client, goto out_me; } info->res_type = M5MOLS_RESTYPE_MONITOR; + info->ffmt[0] = m5mols_default_ffmt[0]; + info->ffmt[1] = m5mols_default_ffmt[1]; ret = m5mols_sensor_power(info, true); if (ret) |