Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[media] V4L2: sh_mobile_ceu: manage lower 8bit bus

CAMCR::DTIF feild controls camera bus as upper8bit/16bit/lower8bit.
This patch manages unmanaged lower 8bit bus

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>

authored by

Kuninori Morimoto and committed by
Mauro Carvalho Chehab
2564f67b fec0f72f

+6 -3
+5 -3
drivers/media/video/sh_mobile_ceu_camera.c
··· 870 870 871 871 value |= common_flags & V4L2_MBUS_VSYNC_ACTIVE_LOW ? 1 << 1 : 0; 872 872 value |= common_flags & V4L2_MBUS_HSYNC_ACTIVE_LOW ? 1 << 0 : 0; 873 - value |= pcdev->is_16bit ? 1 << 12 : 0; 874 873 875 - /* CSI2 mode */ 876 - if (pcdev->pdata->csi2) 874 + if (pcdev->pdata->csi2) /* CSI2 mode */ 877 875 value |= 3 << 12; 876 + else if (pcdev->is_16bit) 877 + value |= 1 << 12; 878 + else if (pcdev->pdata->flags & SH_CEU_FLAG_LOWER_8BIT) 879 + value |= 2 << 12; 878 880 879 881 ceu_write(pcdev, CAMCR, value); 880 882
+1
include/media/sh_mobile_ceu.h
··· 5 5 #define SH_CEU_FLAG_USE_16BIT_BUS (1 << 1) /* use 16bit bus width */ 6 6 #define SH_CEU_FLAG_HSYNC_LOW (1 << 2) /* default High if possible */ 7 7 #define SH_CEU_FLAG_VSYNC_LOW (1 << 3) /* default High if possible */ 8 + #define SH_CEU_FLAG_LOWER_8BIT (1 << 4) /* default upper 8bit */ 8 9 9 10 struct device; 10 11 struct resource;