[media] mipi-csis: get rid of a warning
authorMauro Carvalho Chehab <m.chehab@samsung.com>
Tue, 26 Aug 2014 14:17:16 +0000 (11:17 -0300)
committerMauro Carvalho Chehab <m.chehab@samsung.com>
Tue, 26 Aug 2014 21:52:13 +0000 (18:52 -0300)
drivers/media/platform/exynos4-is/mipi-csis.c: In function 's5pcsis_parse_dt':
drivers/media/platform/exynos4-is/mipi-csis.c:756:2: warning: comparison is always false due to limited range of data type [-Wtype-limits]
  if (state->index < 0 || state->index >= CSIS_MAX_ENTITIES)
  ^

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/media/platform/exynos4-is/mipi-csis.c

index ae54ef5f535d9c105f643d76e3f78c72ee341095..8be8897bc6cde7edf4f23f6dff31851f96fe20af 100644 (file)
@@ -752,7 +752,7 @@ static int s5pcsis_parse_dt(struct platform_device *pdev,
        v4l2_of_parse_endpoint(node, &endpoint);
 
        state->index = endpoint.base.port - FIMC_INPUT_MIPI_CSI2_0;
-       if (state->index < 0 || state->index >= CSIS_MAX_ENTITIES)
+       if (state->index >= CSIS_MAX_ENTITIES)
                return -ENXIO;
 
        /* Get MIPI CSI-2 bus configration from the endpoint node. */