summaryrefslogtreecommitdiffstats
path: root/drivers/staging
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2023-01-13 16:51:54 +0100
committerMauro Carvalho Chehab <mchehab@kernel.org>2023-02-08 08:24:34 +0100
commitbca7822cbc76b22572faf2e17ca9517b68ebeb3e (patch)
tree6da5d32941a25ba8db8308be3773d6863e8cd4c5 /drivers/staging
parent8cf66250505e54e1d91f7cae7091f8cfefa4a01e (diff)
downloadlinux-stable-bca7822cbc76b22572faf2e17ca9517b68ebeb3e.tar.gz
linux-stable-bca7822cbc76b22572faf2e17ca9517b68ebeb3e.tar.bz2
linux-stable-bca7822cbc76b22572faf2e17ca9517b68ebeb3e.zip
media: atomisp: ov2680: Drop MAX_FMTS define
The ov2680 only supports a single format, there is no need to use a define for this. Reviewed-by: Andy Shevchenko <andy@kernel.org> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/media/atomisp/i2c/atomisp-ov2680.c3
-rw-r--r--drivers/staging/media/atomisp/i2c/ov2680.h2
2 files changed, 2 insertions, 3 deletions
diff --git a/drivers/staging/media/atomisp/i2c/atomisp-ov2680.c b/drivers/staging/media/atomisp/i2c/atomisp-ov2680.c
index b139c4167cf9..0e51a5f83f12 100644
--- a/drivers/staging/media/atomisp/i2c/atomisp-ov2680.c
+++ b/drivers/staging/media/atomisp/i2c/atomisp-ov2680.c
@@ -680,7 +680,8 @@ static int ov2680_enum_mbus_code(struct v4l2_subdev *sd,
struct v4l2_subdev_state *sd_state,
struct v4l2_subdev_mbus_code_enum *code)
{
- if (code->index >= MAX_FMTS)
+ /* We support only a single format */
+ if (code->index)
return -EINVAL;
code->code = MEDIA_BUS_FMT_SBGGR10_1X10;
diff --git a/drivers/staging/media/atomisp/i2c/ov2680.h b/drivers/staging/media/atomisp/i2c/ov2680.h
index adf38359afbc..feb8ad055b40 100644
--- a/drivers/staging/media/atomisp/i2c/ov2680.h
+++ b/drivers/staging/media/atomisp/i2c/ov2680.h
@@ -46,8 +46,6 @@
#define OV2680_FOCAL_LENGTH_NUM 334 /*3.34mm*/
-#define MAX_FMTS 1
-
#define OV2680_INTEGRATION_TIME_MARGIN 8
#define OV2680_ID 0x2680