]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
media: rcar-vin: Remove unnecessary checks
authorTomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
Thu, 24 Apr 2025 07:05:34 +0000 (10:05 +0300)
committerHans Verkuil <hverkuil@xs4all.nl>
Fri, 2 May 2025 08:16:43 +0000 (10:16 +0200)
Remove unnecessary checks wrt. formats and interfaces in rvin_setup().
The validity of the formats has already been checked earlier.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Tested-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Link: https://lore.kernel.org/r/20250424-rcar-fix-raw-v2-2-f6afca378124@ideasonboard.com
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
drivers/media/platform/renesas/rcar-vin/rcar-dma.c

index 374396bcf8b994c959b869e9ee03d646a947f2f0..e0464eb49b599f22cf2bd86f5609929e9afb1290 100644 (file)
@@ -782,29 +782,6 @@ static int rvin_setup(struct rvin_dev *vin)
                break;
        }
 
-       /* Make sure input interface and input format is valid. */
-       if (vin->info->model == RCAR_GEN3 || vin->info->model == RCAR_GEN4) {
-               switch (vnmc & VNMC_INF_MASK) {
-               case VNMC_INF_YUV8_BT656:
-               case VNMC_INF_YUV10_BT656:
-               case VNMC_INF_YUV16:
-               case VNMC_INF_RGB666:
-                       if (vin->is_csi) {
-                               vin_err(vin, "Invalid setting in MIPI CSI2\n");
-                               return -EINVAL;
-                       }
-                       break;
-               case VNMC_INF_RAW8:
-                       if (!vin->is_csi) {
-                               vin_err(vin, "Invalid setting in Digital Pins\n");
-                               return -EINVAL;
-                       }
-                       break;
-               default:
-                       break;
-               }
-       }
-
        /* Enable VSYNC Field Toggle mode after one VSYNC input */
        if (vin->info->model == RCAR_GEN3 || vin->info->model == RCAR_GEN4)
                dmr2 = VNDMR2_FTEV;