diff options
author | Sakari Ailus <sakari.ailus@linux.intel.com> | 2018-09-24 10:38:11 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2018-10-03 11:58:24 -0400 |
commit | af8e15620efdfe335a7cf9c0a4d8bd89c2402e2b (patch) | |
tree | 37b104fa26d830bfac0d9db329cd480d9807cf9e /drivers/media/i2c/soc_camera | |
parent | 654be7dde76b1897450c49d526af11067601e5b9 (diff) | |
download | linux-af8e15620efdfe335a7cf9c0a4d8bd89c2402e2b.tar.gz linux-af8e15620efdfe335a7cf9c0a4d8bd89c2402e2b.tar.bz2 linux-af8e15620efdfe335a7cf9c0a4d8bd89c2402e2b.zip |
media: v4l: Remove support for crop default target in subdev drivers
The V4L2 sub-device API does not support the crop default target. A number
of drivers apparently still did support this, likely as it was needed by
the SoC camera framework. Drop support for the default crop rectaingle in
sub-device drivers, and use the bounds rectangle in SoC camera instead.
Reported-by: Helmut Grohne <h.grohne@intenta.de>
Suggested-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media/i2c/soc_camera')
-rw-r--r-- | drivers/media/i2c/soc_camera/mt9m001.c | 1 | ||||
-rw-r--r-- | drivers/media/i2c/soc_camera/mt9t112.c | 6 | ||||
-rw-r--r-- | drivers/media/i2c/soc_camera/mt9v022.c | 1 | ||||
-rw-r--r-- | drivers/media/i2c/soc_camera/ov5642.c | 1 | ||||
-rw-r--r-- | drivers/media/i2c/soc_camera/ov772x.c | 1 | ||||
-rw-r--r-- | drivers/media/i2c/soc_camera/ov9640.c | 1 | ||||
-rw-r--r-- | drivers/media/i2c/soc_camera/ov9740.c | 1 | ||||
-rw-r--r-- | drivers/media/i2c/soc_camera/rj54n1cb0c.c | 1 |
8 files changed, 0 insertions, 13 deletions
diff --git a/drivers/media/i2c/soc_camera/mt9m001.c b/drivers/media/i2c/soc_camera/mt9m001.c index 1bfb0d53059e..a1a85ff838c5 100644 --- a/drivers/media/i2c/soc_camera/mt9m001.c +++ b/drivers/media/i2c/soc_camera/mt9m001.c @@ -243,7 +243,6 @@ static int mt9m001_get_selection(struct v4l2_subdev *sd, switch (sel->target) { case V4L2_SEL_TGT_CROP_BOUNDS: - case V4L2_SEL_TGT_CROP_DEFAULT: sel->r.left = MT9M001_COLUMN_SKIP; sel->r.top = MT9M001_ROW_SKIP; sel->r.width = MT9M001_MAX_WIDTH; diff --git a/drivers/media/i2c/soc_camera/mt9t112.c b/drivers/media/i2c/soc_camera/mt9t112.c index b53c36dfa469..ea1ff270bc2d 100644 --- a/drivers/media/i2c/soc_camera/mt9t112.c +++ b/drivers/media/i2c/soc_camera/mt9t112.c @@ -884,12 +884,6 @@ static int mt9t112_get_selection(struct v4l2_subdev *sd, sel->r.width = MAX_WIDTH; sel->r.height = MAX_HEIGHT; return 0; - case V4L2_SEL_TGT_CROP_DEFAULT: - sel->r.left = 0; - sel->r.top = 0; - sel->r.width = VGA_WIDTH; - sel->r.height = VGA_HEIGHT; - return 0; case V4L2_SEL_TGT_CROP: sel->r = priv->frame; return 0; diff --git a/drivers/media/i2c/soc_camera/mt9v022.c b/drivers/media/i2c/soc_camera/mt9v022.c index 762f06919329..6d922b17ea94 100644 --- a/drivers/media/i2c/soc_camera/mt9v022.c +++ b/drivers/media/i2c/soc_camera/mt9v022.c @@ -368,7 +368,6 @@ static int mt9v022_get_selection(struct v4l2_subdev *sd, switch (sel->target) { case V4L2_SEL_TGT_CROP_BOUNDS: - case V4L2_SEL_TGT_CROP_DEFAULT: sel->r.left = MT9V022_COLUMN_SKIP; sel->r.top = MT9V022_ROW_SKIP; sel->r.width = MT9V022_MAX_WIDTH; diff --git a/drivers/media/i2c/soc_camera/ov5642.c b/drivers/media/i2c/soc_camera/ov5642.c index 39f420db9c70..c6c41b03c0ef 100644 --- a/drivers/media/i2c/soc_camera/ov5642.c +++ b/drivers/media/i2c/soc_camera/ov5642.c @@ -896,7 +896,6 @@ static int ov5642_get_selection(struct v4l2_subdev *sd, switch (sel->target) { case V4L2_SEL_TGT_CROP_BOUNDS: - case V4L2_SEL_TGT_CROP_DEFAULT: sel->r.left = 0; sel->r.top = 0; sel->r.width = OV5642_MAX_WIDTH; diff --git a/drivers/media/i2c/soc_camera/ov772x.c b/drivers/media/i2c/soc_camera/ov772x.c index 14377af7c888..fafd372527b2 100644 --- a/drivers/media/i2c/soc_camera/ov772x.c +++ b/drivers/media/i2c/soc_camera/ov772x.c @@ -862,7 +862,6 @@ static int ov772x_get_selection(struct v4l2_subdev *sd, sel->r.top = 0; switch (sel->target) { case V4L2_SEL_TGT_CROP_BOUNDS: - case V4L2_SEL_TGT_CROP_DEFAULT: sel->r.width = OV772X_MAX_WIDTH; sel->r.height = OV772X_MAX_HEIGHT; return 0; diff --git a/drivers/media/i2c/soc_camera/ov9640.c b/drivers/media/i2c/soc_camera/ov9640.c index c63948989688..eb91b8240083 100644 --- a/drivers/media/i2c/soc_camera/ov9640.c +++ b/drivers/media/i2c/soc_camera/ov9640.c @@ -554,7 +554,6 @@ static int ov9640_get_selection(struct v4l2_subdev *sd, sel->r.top = 0; switch (sel->target) { case V4L2_SEL_TGT_CROP_BOUNDS: - case V4L2_SEL_TGT_CROP_DEFAULT: case V4L2_SEL_TGT_CROP: sel->r.width = W_SXGA; sel->r.height = H_SXGA; diff --git a/drivers/media/i2c/soc_camera/ov9740.c b/drivers/media/i2c/soc_camera/ov9740.c index 755de2289c39..a07d3145d1b4 100644 --- a/drivers/media/i2c/soc_camera/ov9740.c +++ b/drivers/media/i2c/soc_camera/ov9740.c @@ -730,7 +730,6 @@ static int ov9740_get_selection(struct v4l2_subdev *sd, switch (sel->target) { case V4L2_SEL_TGT_CROP_BOUNDS: - case V4L2_SEL_TGT_CROP_DEFAULT: case V4L2_SEL_TGT_CROP: sel->r.left = 0; sel->r.top = 0; diff --git a/drivers/media/i2c/soc_camera/rj54n1cb0c.c b/drivers/media/i2c/soc_camera/rj54n1cb0c.c index 02398d0bc649..f0cb49a6167b 100644 --- a/drivers/media/i2c/soc_camera/rj54n1cb0c.c +++ b/drivers/media/i2c/soc_camera/rj54n1cb0c.c @@ -591,7 +591,6 @@ static int rj54n1_get_selection(struct v4l2_subdev *sd, switch (sel->target) { case V4L2_SEL_TGT_CROP_BOUNDS: - case V4L2_SEL_TGT_CROP_DEFAULT: sel->r.left = RJ54N1_COLUMN_SKIP; sel->r.top = RJ54N1_ROW_SKIP; sel->r.width = RJ54N1_MAX_WIDTH; |