linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST
@ 2018-04-05 20:29 Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 01/19] omap: omap-iommu.h: allow building drivers " Mauro Carvalho Chehab
                   ` (18 more replies)
  0 siblings, 19 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List, Mauro Carvalho Chehab

The current media policy has been for a while to only accept new drivers 
that compile with COMPILE_TEST.

However, there are still several drivers under that  doesn't build
with COMPILE_TEST.

So, this series makes the existing ones also compatible with it.

Not building with COMPILE_TEST is a bad thing, for several reasons.

The main ones is that:

1) the licence the Kernel community has for Coverity only builds for 
   x86. So, drivers that don't build on such archtecture were likely 
   never tested by it.

2) That affects my per-patch handling process, with should be quick 
   enough to not delay my patch handling process. So, I only build for one 
   architecture (i386).

3) When appliying a patch, I always run two static code analyzers (W=1, 
   smatch and sparse). Those drivers weren't checked by me. At the end 
   of the day, that leads to a lower quality check for the drivers that 
   don't build on i386.

There are two situations on this patch series that proof the lower 
quality of those drivers:

- There is a case of a driver that was added broken in 2013. Only two 
  years later, someone noticed and "fixed" it by markin it as BROKEN!

- 5 patches in this series (about 1/3) are just to fix build issues on 
  those drivers, most of them due to gcc warnings.

With this patch series, all "config FOO" and "menuconfig FOO"
symbols under media will be built with allyes config.

Tested with:
	$ make ARCH=i386 allyesconfig
	$ for i in  $(grep "config " $(find drivers/staging/media/ -name Kconfig) $(find drivers/media/ -name Kconfig) |grep -v "\#.*Kconfig"|cut -d' ' -f 2) ; do if [ "$(grep $i .config)" == "" ]; then echo $i; fi;done

v2:

- did some changes as per Laurent's feedback from the past series;
- added a patch to compile both si470x drivers at the same time;
- added patches to also build all media staging drivers.

I opted to preserve patch 03/16 (omap3isp build) as I don't see
any strong reason why this driver should not be allowed to
build with COMPILE_TEST.

Mauro Carvalho Chehab (19):
  omap: omap-iommu.h: allow building drivers with COMPILE_TEST
  media: omap3isp: allow it to build with COMPILE_TEST
  media: omap3isp/isp: remove an unused static var
  media: fsl-viu: mark static functions as such
  media: fsl-viu: allow building it with COMPILE_TEST
  media: cec_gpio: allow building CEC_GPIO with COMPILE_TEST
  media: exymos4-is: allow compile test for EXYNOS FIMC-LITE
  media: mmp-camera.h: add missing platform data
  media: marvel-ccic: re-enable mmp-driver build
  media: mmp-driver: make two functions static
  media: davinci: allow building isif code
  media: davinci: allow build vpbe_display with COMPILE_TEST
  media: vpbe_venc: don't store return codes if they won't be used
  media: davinci: get rid of lots of kernel-doc warnings
  omap2: omapfb: allow building it with COMPILE_TEST
  media: omap: allow building it with COMPILE_TEST
  media: omap4iss: make it build with COMPILE_TEST
  media: si470x: allow build both USB and I2C at the same time
  media: staging: davinci_vpfe: allow building with COMPILE_TEST

 drivers/media/platform/Kconfig                   | 12 ++---
 drivers/media/platform/davinci/Kconfig           |  6 ++-
 drivers/media/platform/davinci/isif.c            |  2 -
 drivers/media/platform/davinci/vpbe.c            | 38 ++++++++-------
 drivers/media/platform/davinci/vpbe_display.c    | 21 ++++----
 drivers/media/platform/davinci/vpbe_osd.c        | 16 ++++---
 drivers/media/platform/davinci/vpbe_venc.c       |  9 ++--
 drivers/media/platform/exynos4-is/Kconfig        |  4 +-
 drivers/media/platform/fsl-viu.c                 | 20 +++++---
 drivers/media/platform/marvell-ccic/Kconfig      |  5 +-
 drivers/media/platform/marvell-ccic/mmp-driver.c |  4 +-
 drivers/media/platform/omap/Kconfig              |  8 ++--
 drivers/media/platform/omap3isp/isp.c            | 14 +++---
 drivers/media/radio/Kconfig                      |  4 --
 drivers/media/radio/si470x/Kconfig               | 16 ++++++-
 drivers/media/radio/si470x/Makefile              |  8 ++--
 drivers/media/radio/si470x/radio-si470x-common.c | 61 +++++++++++++++++-------
 drivers/media/radio/si470x/radio-si470x-i2c.c    | 18 ++++---
 drivers/media/radio/si470x/radio-si470x-usb.c    | 18 ++++---
 drivers/media/radio/si470x/radio-si470x.h        | 15 +++---
 drivers/staging/media/davinci_vpfe/Kconfig       |  3 +-
 drivers/staging/media/davinci_vpfe/Makefile      |  5 ++
 drivers/staging/media/davinci_vpfe/TODO          |  1 +
 drivers/staging/media/omap4iss/Kconfig           |  3 +-
 drivers/video/fbdev/omap2/Kconfig                |  2 +-
 include/linux/omap-iommu.h                       |  5 ++
 include/linux/platform_data/media/mmp-camera.h   | 19 ++++++++
 27 files changed, 217 insertions(+), 120 deletions(-)

-- 
2.14.3

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v2 01/19] omap: omap-iommu.h: allow building drivers with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 02/19] media: omap3isp: allow it to build " Mauro Carvalho Chehab
                   ` (17 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List, Mauro Carvalho Chehab

Drivers that depend on omap-iommu.h (currently, just omap3isp)
need a stub implementation in order to be built with COMPILE_TEST.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 include/linux/omap-iommu.h | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/include/linux/omap-iommu.h b/include/linux/omap-iommu.h
index c1aede46718b..0c21fc5b002e 100644
--- a/include/linux/omap-iommu.h
+++ b/include/linux/omap-iommu.h
@@ -13,7 +13,12 @@
 #ifndef _OMAP_IOMMU_H_
 #define _OMAP_IOMMU_H_
 
+#ifdef CONFIG_OMAP_IOMMU
 extern void omap_iommu_save_ctx(struct device *dev);
 extern void omap_iommu_restore_ctx(struct device *dev);
+#else
+static inline void omap_iommu_save_ctx(struct device *dev) {};
+static inline void omap_iommu_restore_ctx(struct device *dev) {};
+#endif
 
 #endif
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 02/19] media: omap3isp: allow it to build with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 01/19] omap: omap-iommu.h: allow building drivers " Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06 12:56   ` kbuild test robot
  2018-04-07 13:31   ` Laurent Pinchart
  2018-04-05 20:29 ` [PATCH v2 03/19] media: omap3isp/isp: remove an unused static var Mauro Carvalho Chehab
                   ` (16 subsequent siblings)
  18 siblings, 2 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Laurent Pinchart, Hans Verkuil,
	Arnd Bergmann, Stanimir Varbanov, Benjamin Gaignard,
	Philipp Zabel, Ramesh Shanmugasundaram

There aren't much things required for it to build with COMPILE_TEST.
It just needs to provide stub for an arm-dependent include.

Let's replicate the same solution used by ipmmu-vmsa, in order
to allow building omap3 with COMPILE_TEST.

The actual logic here came from this driver:

   drivers/iommu/ipmmu-vmsa.c

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/Kconfig        | 8 ++++----
 drivers/media/platform/omap3isp/isp.c | 7 +++++++
 2 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/drivers/media/platform/Kconfig b/drivers/media/platform/Kconfig
index c7a1cf8a1b01..03c9dfeb7781 100644
--- a/drivers/media/platform/Kconfig
+++ b/drivers/media/platform/Kconfig
@@ -62,12 +62,12 @@ config VIDEO_MUX
 
 config VIDEO_OMAP3
 	tristate "OMAP 3 Camera support"
-	depends on VIDEO_V4L2 && I2C && VIDEO_V4L2_SUBDEV_API && ARCH_OMAP3
+	depends on VIDEO_V4L2 && I2C && VIDEO_V4L2_SUBDEV_API
 	depends on HAS_DMA && OF
-	depends on OMAP_IOMMU
-	select ARM_DMA_USE_IOMMU
+	depends on ((ARCH_OMAP3 && OMAP_IOMMU) || COMPILE_TEST)
+	select ARM_DMA_USE_IOMMU if OMAP_IOMMU
 	select VIDEOBUF2_DMA_CONTIG
-	select MFD_SYSCON
+	select MFD_SYSCON if ARCH_OMAP3
 	select V4L2_FWNODE
 	---help---
 	  Driver for an OMAP 3 camera controller.
diff --git a/drivers/media/platform/omap3isp/isp.c b/drivers/media/platform/omap3isp/isp.c
index 8eb000e3d8fd..2a11a709aa4f 100644
--- a/drivers/media/platform/omap3isp/isp.c
+++ b/drivers/media/platform/omap3isp/isp.c
@@ -61,7 +61,14 @@
 #include <linux/sched.h>
 #include <linux/vmalloc.h>
 
+#if defined(CONFIG_ARM) && !defined(CONFIG_IOMMU_DMA)
 #include <asm/dma-iommu.h>
+#else
+#define arm_iommu_create_mapping(...)	NULL
+#define arm_iommu_attach_device(...)	-ENODEV
+#define arm_iommu_release_mapping(...)	do {} while (0)
+#define arm_iommu_detach_device(...)	do {} while (0)
+#endif
 
 #include <media/v4l2-common.h>
 #include <media/v4l2-fwnode.h>
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 03/19] media: omap3isp/isp: remove an unused static var
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 01/19] omap: omap-iommu.h: allow building drivers " Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 02/19] media: omap3isp: allow it to build " Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 04/19] media: fsl-viu: mark static functions as such Mauro Carvalho Chehab
                   ` (15 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Laurent Pinchart

The isp_xclk_init_data const data isn't used anywere.

drivers/media/platform/omap3isp/isp.c:294:35: warning: ‘isp_xclk_init_data’ defined but not used [-Wunused-const-variable=]
 static const struct clk_init_data isp_xclk_init_data = {
                                   ^~~~~~~~~~~~~~~~~~

Fixes: 9b28ee3c9122 ("[media] omap3isp: Use the common clock framework")
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/omap3isp/isp.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/media/platform/omap3isp/isp.c b/drivers/media/platform/omap3isp/isp.c
index 2a11a709aa4f..9e4b5fb8a8b5 100644
--- a/drivers/media/platform/omap3isp/isp.c
+++ b/drivers/media/platform/omap3isp/isp.c
@@ -291,13 +291,6 @@ static const struct clk_ops isp_xclk_ops = {
 
 static const char *isp_xclk_parent_name = "cam_mclk";
 
-static const struct clk_init_data isp_xclk_init_data = {
-	.name = "cam_xclk",
-	.ops = &isp_xclk_ops,
-	.parent_names = &isp_xclk_parent_name,
-	.num_parents = 1,
-};
-
 static struct clk *isp_xclk_src_get(struct of_phandle_args *clkspec, void *data)
 {
 	unsigned int idx = clkspec->args[0];
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 04/19] media: fsl-viu: mark static functions as such
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (2 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 03/19] media: omap3isp/isp: remove an unused static var Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 05/19] media: fsl-viu: allow building it with COMPILE_TEST Mauro Carvalho Chehab
                   ` (14 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Hans Verkuil, Bhumika Goyal, Al Viro, Lad,
	Prabhakar, Arvind Yadav, Kees Cook, Geliang Tang

There are several functions that are used only inside the
driver. Stop exposing that to global symbolspace.

Get rid of the following gcc warnings:

drivers/media/platform/fsl-viu.c:240:17: warning: no previous prototype for ‘format_by_fourcc’ [-Wmissing-prototypes]
 struct viu_fmt *format_by_fourcc(int fourcc)
                 ^~~~~~~~~~~~~~~~
drivers/media/platform/fsl-viu.c:253:6: warning: no previous prototype for ‘viu_start_dma’ [-Wmissing-prototypes]
 void viu_start_dma(struct viu_dev *dev)
      ^~~~~~~~~~~~~
drivers/media/platform/fsl-viu.c:262:6: warning: no previous prototype for ‘viu_stop_dma’ [-Wmissing-prototypes]
 void viu_stop_dma(struct viu_dev *dev)
      ^~~~~~~~~~~~
drivers/media/platform/fsl-viu.c:807:5: warning: no previous prototype for ‘vidioc_g_fbuf’ [-Wmissing-prototypes]
 int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg)
     ^~~~~~~~~~~~~
drivers/media/platform/fsl-viu.c:818:5: warning: no previous prototype for ‘vidioc_s_fbuf’ [-Wmissing-prototypes]
 int vidioc_s_fbuf(struct file *file, void *priv, const struct v4l2_framebuffer *arg)
     ^~~~~~~~~~~~~
drivers/media/platform/fsl-viu.c: In function ‘viu_open’:
drivers/media/platform/fsl-viu.c:1170:6: warning: variable ‘status_cfg’ set but not used [-Wunused-but-set-variable]
  u32 status_cfg;
      ^~~~~~~~~~
drivers/media/platform/fsl-viu.c: At top level:
drivers/media/platform/fsl-viu.c:1304:6: warning: no previous prototype for ‘viu_reset’ [-Wmissing-prototypes]
 void viu_reset(struct viu_reg *reg)
      ^~~~~~~~~

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/fsl-viu.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/media/platform/fsl-viu.c b/drivers/media/platform/fsl-viu.c
index 200c47c69a75..9abe79779659 100644
--- a/drivers/media/platform/fsl-viu.c
+++ b/drivers/media/platform/fsl-viu.c
@@ -229,7 +229,7 @@ enum status_config {
 
 static irqreturn_t viu_intr(int irq, void *dev_id);
 
-struct viu_fmt *format_by_fourcc(int fourcc)
+static struct viu_fmt *format_by_fourcc(int fourcc)
 {
 	int i;
 
@@ -242,7 +242,7 @@ struct viu_fmt *format_by_fourcc(int fourcc)
 	return NULL;
 }
 
-void viu_start_dma(struct viu_dev *dev)
+static void viu_start_dma(struct viu_dev *dev)
 {
 	struct viu_reg *vr = dev->vr;
 
@@ -253,7 +253,7 @@ void viu_start_dma(struct viu_dev *dev)
 	out_be32(&vr->status_cfg, INT_FIELD_EN);
 }
 
-void viu_stop_dma(struct viu_dev *dev)
+static void viu_stop_dma(struct viu_dev *dev)
 {
 	struct viu_reg *vr = dev->vr;
 	int cnt = 100;
@@ -802,7 +802,7 @@ static int vidioc_overlay(struct file *file, void *priv, unsigned int on)
 	return 0;
 }
 
-int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg)
+static int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg)
 {
 	struct viu_fh  *fh = priv;
 	struct viu_dev *dev = fh->dev;
@@ -813,7 +813,7 @@ int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg)
 	return 0;
 }
 
-int vidioc_s_fbuf(struct file *file, void *priv, const struct v4l2_framebuffer *arg)
+static int vidioc_s_fbuf(struct file *file, void *priv, const struct v4l2_framebuffer *arg)
 {
 	struct viu_fh  *fh = priv;
 	struct viu_dev *dev = fh->dev;
@@ -1305,7 +1305,7 @@ static int viu_release(struct file *file)
 	return 0;
 }
 
-void viu_reset(struct viu_reg *reg)
+static void viu_reset(struct viu_reg *reg)
 {
 	out_be32(&reg->status_cfg, 0);
 	out_be32(&reg->luminance, 0x9512a254);
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 05/19] media: fsl-viu: allow building it with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (3 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 04/19] media: fsl-viu: mark static functions as such Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06 10:43   ` kbuild test robot
  2018-04-06 14:03   ` kbuild test robot
  2018-04-05 20:29 ` [PATCH v2 06/19] media: cec_gpio: allow building CEC_GPIO " Mauro Carvalho Chehab
                   ` (13 subsequent siblings)
  18 siblings, 2 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Hans Verkuil, Arnd Bergmann,
	Stanimir Varbanov, Benjamin Gaignard, Philipp Zabel,
	Ramesh Shanmugasundaram, Al Viro, Bhumika Goyal, Geliang Tang,
	Kees Cook

There aren't many things that would be needed to allow it
to build with compile test.

Add the needed bits.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/Kconfig   | 2 +-
 drivers/media/platform/fsl-viu.c | 8 ++++++++
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/drivers/media/platform/Kconfig b/drivers/media/platform/Kconfig
index 03c9dfeb7781..e6eb1eb776e1 100644
--- a/drivers/media/platform/Kconfig
+++ b/drivers/media/platform/Kconfig
@@ -42,7 +42,7 @@ config VIDEO_SH_VOU
 
 config VIDEO_VIU
 	tristate "Freescale VIU Video Driver"
-	depends on VIDEO_V4L2 && PPC_MPC512x
+	depends on VIDEO_V4L2 && (PPC_MPC512x || COMPILE_TEST)
 	select VIDEOBUF_DMA_CONTIG
 	default y
 	---help---
diff --git a/drivers/media/platform/fsl-viu.c b/drivers/media/platform/fsl-viu.c
index 9abe79779659..466053e00378 100644
--- a/drivers/media/platform/fsl-viu.c
+++ b/drivers/media/platform/fsl-viu.c
@@ -36,6 +36,14 @@
 #define DRV_NAME		"fsl_viu"
 #define VIU_VERSION		"0.5.1"
 
+/* Allow building this driver with COMPILE_TEST */
+#ifndef CONFIG_PPC_MPC512x
+#define NO_IRQ   0
+
+#define out_be32(v, a)	writel(a, v)
+#define in_be32(a) readl(a)
+#endif
+
 #define BUFFER_TIMEOUT		msecs_to_jiffies(500)  /* 0.5 seconds */
 
 #define	VIU_VID_MEM_LIMIT	4	/* Video memory limit, in Mb */
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 06/19] media: cec_gpio: allow building CEC_GPIO with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (4 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 05/19] media: fsl-viu: allow building it with COMPILE_TEST Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 07/19] media: exymos4-is: allow compile test for EXYNOS FIMC-LITE Mauro Carvalho Chehab
                   ` (12 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Hans Verkuil, Arnd Bergmann,
	Stanimir Varbanov, Benjamin Gaignard, Ramesh Shanmugasundaram

At least on i386, building with allyesconfig doesn't enable
PREEMPT, causing cec_gpio to not build.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/platform/Kconfig b/drivers/media/platform/Kconfig
index e6eb1eb776e1..e8d8bbc976af 100644
--- a/drivers/media/platform/Kconfig
+++ b/drivers/media/platform/Kconfig
@@ -558,7 +558,7 @@ config VIDEO_MESON_AO_CEC
 
 config CEC_GPIO
 	tristate "Generic GPIO-based CEC driver"
-	depends on PREEMPT
+	depends on PREEMPT || COMPILE_TEST
 	select CEC_CORE
 	select CEC_PIN
 	select GPIOLIB
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 07/19] media: exymos4-is: allow compile test for EXYNOS FIMC-LITE
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (5 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 06/19] media: cec_gpio: allow building CEC_GPIO " Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 08/19] media: mmp-camera.h: add missing platform data Mauro Carvalho Chehab
                   ` (11 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Kyungmin Park, Sylwester Nawrocki,
	Kukjin Kim, Krzysztof Kozlowski, linux-arm-kernel,
	linux-samsung-soc

There's nothing that prevents building this driver with
COMPILE_TEST. So, enable it.

While here, make the Kconfig dependency cleaner by removing
the unneeded if block.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/exynos4-is/Kconfig | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/media/platform/exynos4-is/Kconfig b/drivers/media/platform/exynos4-is/Kconfig
index 7b2c49e5a592..c8e5ad8f8294 100644
--- a/drivers/media/platform/exynos4-is/Kconfig
+++ b/drivers/media/platform/exynos4-is/Kconfig
@@ -41,11 +41,10 @@ config VIDEO_S5P_MIPI_CSIS
 	  To compile this driver as a module, choose M here: the
 	  module will be called s5p-csis.
 
-if SOC_EXYNOS4412 || SOC_EXYNOS5250
-
 config VIDEO_EXYNOS_FIMC_LITE
 	tristate "EXYNOS FIMC-LITE camera interface driver"
 	depends on I2C
+	depends on SOC_EXYNOS4412 || SOC_EXYNOS5250 || COMPILE_TEST
 	depends on HAS_DMA
 	select VIDEOBUF2_DMA_CONTIG
 	select VIDEO_EXYNOS4_IS_COMMON
@@ -55,7 +54,6 @@ config VIDEO_EXYNOS_FIMC_LITE
 
 	  To compile this driver as a module, choose M here: the
 	  module will be called exynos-fimc-lite.
-endif
 
 config VIDEO_EXYNOS4_FIMC_IS
 	tristate "EXYNOS4x12 FIMC-IS (Imaging Subsystem) driver"
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 08/19] media: mmp-camera.h: add missing platform data
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (6 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 07/19] media: exymos4-is: allow compile test for EXYNOS FIMC-LITE Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 09/19] media: marvel-ccic: re-enable mmp-driver build Mauro Carvalho Chehab
                   ` (10 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List, Mauro Carvalho Chehab

Those definitions used to be part of the original patch:
	https://patchwork.kernel.org/patch/2815221/

But, somehow, nobody ever noticed until today. Years later,
Arnd discovered that mmp-camera driver doesn't build and make
it depend on BROKEN.

Add the missing bits here, in order to remove BROKEN dependency.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 include/linux/platform_data/media/mmp-camera.h | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/include/linux/platform_data/media/mmp-camera.h b/include/linux/platform_data/media/mmp-camera.h
index 83804028115c..d2d3a443eedf 100644
--- a/include/linux/platform_data/media/mmp-camera.h
+++ b/include/linux/platform_data/media/mmp-camera.h
@@ -3,8 +3,27 @@
  * Information for the Marvell Armada MMP camera
  */
 
+#include <media/v4l2-mediabus.h>
+
+enum dphy3_algo {
+	DPHY3_ALGO_DEFAULT = 0,
+	DPHY3_ALGO_PXA910,
+	DPHY3_ALGO_PXA2128
+};
+
 struct mmp_camera_platform_data {
 	struct platform_device *i2c_device;
 	int sensor_power_gpio;
 	int sensor_reset_gpio;
+	enum v4l2_mbus_type bus_type;
+	int mclk_min;	/* The minimal value of MCLK */
+	int mclk_src;	/* which clock source the MCLK derives from */
+	int mclk_div;	/* Clock Divider Value for MCLK */
+	/*
+	 * MIPI support
+	 */
+	int dphy[3];		/* DPHY: CSI2_DPHY3, CSI2_DPHY5, CSI2_DPHY6 */
+	enum dphy3_algo dphy3_algo;	/* algos for calculate CSI2_DPHY3 */
+	int lane;		/* ccic used lane number; 0 means DVP mode */
+	int lane_clk;
 };
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 09/19] media: marvel-ccic: re-enable mmp-driver build
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (7 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 08/19] media: mmp-camera.h: add missing platform data Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06 14:52   ` kbuild test robot
  2018-04-05 20:29 ` [PATCH v2 10/19] media: mmp-driver: make two functions static Mauro Carvalho Chehab
                   ` (9 subsequent siblings)
  18 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Jonathan Corbet

This driver was disabled back in 2015 from builds because
of some troubles with the platform_data definition. Now
that this got fixed, re-enable it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/marvell-ccic/Kconfig | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/media/platform/marvell-ccic/Kconfig b/drivers/media/platform/marvell-ccic/Kconfig
index 4bf5bd1e90d6..21dacef7c2fc 100644
--- a/drivers/media/platform/marvell-ccic/Kconfig
+++ b/drivers/media/platform/marvell-ccic/Kconfig
@@ -13,8 +13,9 @@ config VIDEO_CAFE_CCIC
 
 config VIDEO_MMP_CAMERA
 	tristate "Marvell Armada 610 integrated camera controller support"
-	depends on ARCH_MMP && I2C && VIDEO_V4L2
-	depends on HAS_DMA && BROKEN
+	depends on I2C && VIDEO_V4L2
+	depends on HAS_DMA
+	depends on ARCH_MMP || COMPILE_TEST
 	select VIDEO_OV7670
 	select I2C_GPIO
 	select VIDEOBUF2_DMA_SG
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 10/19] media: mmp-driver: make two functions static
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (8 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 09/19] media: marvel-ccic: re-enable mmp-driver build Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 11/19] media: davinci: allow building isif code Mauro Carvalho Chehab
                   ` (8 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Jonathan Corbet

Those functions are used only internally:

  CC      drivers/media/platform/marvell-ccic/mmp-driver.o
drivers/media/platform/marvell-ccic/mmp-driver.c:186:6: warning: no previous prototype for ‘mcam_ctlr_reset’ [-Wmissing-prototypes]
 void mcam_ctlr_reset(struct mcam_camera *mcam)
      ^~~~~~~~~~~~~~~
drivers/media/platform/marvell-ccic/mmp-driver.c:217:6: warning: no previous prototype for ‘mmpcam_calc_dphy’ [-Wmissing-prototypes]
 void mmpcam_calc_dphy(struct mcam_camera *mcam)
      ^~~~~~~~~~~~~~~~

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/marvell-ccic/mmp-driver.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/media/platform/marvell-ccic/mmp-driver.c b/drivers/media/platform/marvell-ccic/mmp-driver.c
index 816f4b6a7b8e..17d79480e75c 100644
--- a/drivers/media/platform/marvell-ccic/mmp-driver.c
+++ b/drivers/media/platform/marvell-ccic/mmp-driver.c
@@ -183,7 +183,7 @@ static void mmpcam_power_down(struct mcam_camera *mcam)
 	mcam_clk_disable(mcam);
 }
 
-void mcam_ctlr_reset(struct mcam_camera *mcam)
+static void mcam_ctlr_reset(struct mcam_camera *mcam)
 {
 	unsigned long val;
 	struct mmp_camera *cam = mcam_to_cam(mcam);
@@ -214,7 +214,7 @@ void mcam_ctlr_reset(struct mcam_camera *mcam)
  * CSI2_DPHY3 and CSI2_DPHY6 can be set with a default value
  * or be calculated dynamically
  */
-void mmpcam_calc_dphy(struct mcam_camera *mcam)
+static void mmpcam_calc_dphy(struct mcam_camera *mcam)
 {
 	struct mmp_camera *cam = mcam_to_cam(mcam);
 	struct mmp_camera_platform_data *pdata = cam->pdev->dev.platform_data;
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 11/19] media: davinci: allow building isif code
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (9 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 10/19] media: mmp-driver: make two functions static Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06 16:17   ` kbuild test robot
  2018-04-05 20:29 ` [PATCH v2 12/19] media: davinci: allow build vpbe_display with COMPILE_TEST Mauro Carvalho Chehab
                   ` (7 subsequent siblings)
  18 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Lad, Prabhakar

The only reason why this driver doesn't build with COMPILE_TEST
is because it includes mach/mux.h. It turns that none of the
macros defined there are used.

So, get rid of it, in order to allow it to build with
COMPILE_TEST.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/davinci/Kconfig | 3 ++-
 drivers/media/platform/davinci/isif.c  | 2 --
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/media/platform/davinci/Kconfig b/drivers/media/platform/davinci/Kconfig
index 55982e681d77..babdb4877b3f 100644
--- a/drivers/media/platform/davinci/Kconfig
+++ b/drivers/media/platform/davinci/Kconfig
@@ -67,7 +67,8 @@ config VIDEO_DM355_CCDC
 
 config VIDEO_DM365_ISIF
 	tristate "TI DM365 ISIF video capture driver"
-	depends on VIDEO_V4L2 && ARCH_DAVINCI
+	depends on VIDEO_V4L2
+	depends on ARCH_DAVINCI || COMPILE_TEST
 	depends on HAS_DMA
 	depends on I2C
 	select VIDEOBUF_DMA_CONTIG
diff --git a/drivers/media/platform/davinci/isif.c b/drivers/media/platform/davinci/isif.c
index d5ff58494c1e..b14caadcd0df 100644
--- a/drivers/media/platform/davinci/isif.c
+++ b/drivers/media/platform/davinci/isif.c
@@ -31,8 +31,6 @@
 #include <linux/err.h>
 #include <linux/module.h>
 
-#include <mach/mux.h>
-
 #include <media/davinci/isif.h>
 #include <media/davinci/vpss.h>
 
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 12/19] media: davinci: allow build vpbe_display with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (10 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 11/19] media: davinci: allow building isif code Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06 18:08   ` kbuild test robot
  2018-04-05 20:29 ` [PATCH v2 13/19] media: vpbe_venc: don't store return codes if they won't be used Mauro Carvalho Chehab
                   ` (6 subsequent siblings)
  18 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Lad, Prabhakar

Except for some includes (with doesn't seem to be used), this
driver builds fine with COMPILE_TEST.

So, add checks there to avoid building it if ARCH_DAVINCI
is not selected.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/davinci/Kconfig        | 3 ++-
 drivers/media/platform/davinci/vpbe_display.c | 3 +++
 drivers/media/platform/davinci/vpbe_osd.c     | 2 ++
 drivers/media/platform/davinci/vpbe_venc.c    | 3 +++
 4 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/drivers/media/platform/davinci/Kconfig b/drivers/media/platform/davinci/Kconfig
index babdb4877b3f..b463d1726335 100644
--- a/drivers/media/platform/davinci/Kconfig
+++ b/drivers/media/platform/davinci/Kconfig
@@ -82,7 +82,8 @@ config VIDEO_DM365_ISIF
 
 config VIDEO_DAVINCI_VPBE_DISPLAY
 	tristate "TI DaVinci VPBE V4L2-Display driver"
-	depends on VIDEO_V4L2 && ARCH_DAVINCI
+	depends on VIDEO_V4L2
+	depends on ARCH_DAVINCI || COMPILE_TEST
 	depends on HAS_DMA
 	depends on I2C
 	select VIDEOBUF2_DMA_CONTIG
diff --git a/drivers/media/platform/davinci/vpbe_display.c b/drivers/media/platform/davinci/vpbe_display.c
index 6aabd21fe69f..7b6cd4b3ccc4 100644
--- a/drivers/media/platform/davinci/vpbe_display.c
+++ b/drivers/media/platform/davinci/vpbe_display.c
@@ -26,7 +26,10 @@
 #include <linux/slab.h>
 
 #include <asm/pgtable.h>
+
+#ifdef CONFIG_ARCH_DAVINCI
 #include <mach/cputype.h>
+#endif
 
 #include <media/v4l2-dev.h>
 #include <media/v4l2-common.h>
diff --git a/drivers/media/platform/davinci/vpbe_osd.c b/drivers/media/platform/davinci/vpbe_osd.c
index 66449791c70c..10f2bf11edf3 100644
--- a/drivers/media/platform/davinci/vpbe_osd.c
+++ b/drivers/media/platform/davinci/vpbe_osd.c
@@ -24,8 +24,10 @@
 #include <linux/clk.h>
 #include <linux/slab.h>
 
+#ifdef CONFIG_ARCH_DAVINCI
 #include <mach/cputype.h>
 #include <mach/hardware.h>
+#endif
 
 #include <media/davinci/vpss.h>
 #include <media/v4l2-device.h>
diff --git a/drivers/media/platform/davinci/vpbe_venc.c b/drivers/media/platform/davinci/vpbe_venc.c
index 3a4e78595149..add72a39ef2d 100644
--- a/drivers/media/platform/davinci/vpbe_venc.c
+++ b/drivers/media/platform/davinci/vpbe_venc.c
@@ -21,8 +21,11 @@
 #include <linux/videodev2.h>
 #include <linux/slab.h>
 
+#ifdef CONFIG_ARCH_DAVINCI
 #include <mach/hardware.h>
 #include <mach/mux.h>
+#endif
+
 #include <linux/platform_data/i2c-davinci.h>
 
 #include <linux/io.h>
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 13/19] media: vpbe_venc: don't store return codes if they won't be used
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (11 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 12/19] media: davinci: allow build vpbe_display with COMPILE_TEST Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 14/19] media: davinci: get rid of lots of kernel-doc warnings Mauro Carvalho Chehab
                   ` (5 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Lad, Prabhakar

Fix those two warnings

drivers/media/platform/davinci/vpbe_venc.c: In function ‘venc_set_ntsc’:
drivers/media/platform/davinci/vpbe_venc.c:230:6: warning: variable ‘val’ set but not used [-Wunused-but-set-variable]
  u32 val;
      ^~~
drivers/media/platform/davinci/vpbe_venc.c: In function ‘venc_sub_dev_init’:
drivers/media/platform/davinci/vpbe_venc.c:611:6: warning: variable ‘err’ set but not used [-Wunused-but-set-variable]
  int err;
      ^~~
  AR      drivers/media/platform/davinci/built-in.a

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/davinci/vpbe_venc.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/media/platform/davinci/vpbe_venc.c b/drivers/media/platform/davinci/vpbe_venc.c
index add72a39ef2d..5c255de3b3f8 100644
--- a/drivers/media/platform/davinci/vpbe_venc.c
+++ b/drivers/media/platform/davinci/vpbe_venc.c
@@ -227,7 +227,6 @@ venc_enable_vpss_clock(int venc_type,
  */
 static int venc_set_ntsc(struct v4l2_subdev *sd)
 {
-	u32 val;
 	struct venc_state *venc = to_state(sd);
 	struct venc_platform_data *pdata = venc->pdata;
 
@@ -244,7 +243,7 @@ static int venc_set_ntsc(struct v4l2_subdev *sd)
 	if (venc->venc_type == VPBE_VERSION_3) {
 		venc_write(sd, VENC_CLKCTL, 0x01);
 		venc_write(sd, VENC_VIDCTL, 0);
-		val = vdaccfg_write(sd, VDAC_CONFIG_SD_V3);
+		vdaccfg_write(sd, VDAC_CONFIG_SD_V3);
 	} else if (venc->venc_type == VPBE_VERSION_2) {
 		venc_write(sd, VENC_CLKCTL, 0x01);
 		venc_write(sd, VENC_VIDCTL, 0);
@@ -608,9 +607,8 @@ struct v4l2_subdev *venc_sub_dev_init(struct v4l2_device *v4l2_dev,
 		const char *venc_name)
 {
 	struct venc_state *venc;
-	int err;
 
-	err = bus_for_each_dev(&platform_bus_type, NULL, &venc,
+	bus_for_each_dev(&platform_bus_type, NULL, &venc,
 			venc_device_get);
 	if (venc == NULL)
 		return NULL;
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 14/19] media: davinci: get rid of lots of kernel-doc warnings
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (12 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 13/19] media: vpbe_venc: don't store return codes if they won't be used Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST Mauro Carvalho Chehab
                   ` (4 subsequent siblings)
  18 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Lad, Prabhakar

Driver build produce lots of warnings due to wrong kernel-doc markups:

    drivers/media/platform/davinci/vpbe.c:60: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_current_encoder_info'
    drivers/media/platform/davinci/vpbe.c:78: warning: Function parameter or member 'cfg' not described in 'vpbe_find_encoder_sd_index'
    drivers/media/platform/davinci/vpbe.c:78: warning: Function parameter or member 'index' not described in 'vpbe_find_encoder_sd_index'
    drivers/media/platform/davinci/vpbe.c:105: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_g_cropcap'
    drivers/media/platform/davinci/vpbe.c:105: warning: Function parameter or member 'cropcap' not described in 'vpbe_g_cropcap'
    drivers/media/platform/davinci/vpbe.c:127: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_enum_outputs'
    drivers/media/platform/davinci/vpbe.c:127: warning: Function parameter or member 'output' not described in 'vpbe_enum_outputs'
    drivers/media/platform/davinci/vpbe.c:221: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_set_output'
    drivers/media/platform/davinci/vpbe.c:221: warning: Function parameter or member 'index' not described in 'vpbe_set_output'
    drivers/media/platform/davinci/vpbe.c:316: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_get_output'
    drivers/media/platform/davinci/vpbe.c:328: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_s_dv_timings'
    drivers/media/platform/davinci/vpbe.c:328: warning: Function parameter or member 'dv_timings' not described in 'vpbe_s_dv_timings'
    drivers/media/platform/davinci/vpbe.c:380: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_g_dv_timings'
    drivers/media/platform/davinci/vpbe.c:380: warning: Function parameter or member 'dv_timings' not described in 'vpbe_g_dv_timings'
    drivers/media/platform/davinci/vpbe.c:405: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_enum_dv_timings'
    drivers/media/platform/davinci/vpbe.c:405: warning: Function parameter or member 'timings' not described in 'vpbe_enum_dv_timings'
    drivers/media/platform/davinci/vpbe.c:436: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_s_std'
    drivers/media/platform/davinci/vpbe.c:436: warning: Function parameter or member 'std_id' not described in 'vpbe_s_std'
    drivers/media/platform/davinci/vpbe.c:475: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_g_std'
    drivers/media/platform/davinci/vpbe.c:475: warning: Function parameter or member 'std_id' not described in 'vpbe_g_std'
    drivers/media/platform/davinci/vpbe.c:500: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_set_mode'
    drivers/media/platform/davinci/vpbe.c:500: warning: Function parameter or member 'mode_info' not described in 'vpbe_set_mode'
    drivers/media/platform/davinci/vpbe.c:585: warning: Function parameter or member 'dev' not described in 'vpbe_initialize'
    drivers/media/platform/davinci/vpbe.c:585: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_initialize'
    drivers/media/platform/davinci/vpbe.c:779: warning: Function parameter or member 'dev' not described in 'vpbe_deinitialize'
    drivers/media/platform/davinci/vpbe.c:779: warning: Function parameter or member 'vpbe_dev' not described in 'vpbe_deinitialize'
    drivers/media/platform/davinci/vpbe_osd.c:144: warning: Function parameter or member 'sd' not described in '_osd_dm6446_vid0_pingpong'
    drivers/media/platform/davinci/vpbe_osd.c:144: warning: Function parameter or member 'field_inversion' not described in '_osd_dm6446_vid0_pingpong'
    drivers/media/platform/davinci/vpbe_osd.c:144: warning: Function parameter or member 'fb_base_phys' not described in '_osd_dm6446_vid0_pingpong'
    drivers/media/platform/davinci/vpbe_osd.c:144: warning: Function parameter or member 'lconfig' not described in '_osd_dm6446_vid0_pingpong'
    drivers/media/platform/davinci/vpbe_osd.c:799: warning: Function parameter or member 'sd' not described in 'try_layer_config'
    drivers/media/platform/davinci/vpbe_osd.c:799: warning: Function parameter or member 'layer' not described in 'try_layer_config'
    drivers/media/platform/davinci/vpbe_osd.c:799: warning: Function parameter or member 'lconfig' not described in 'try_layer_config'
    drivers/media/platform/davinci/vpbe_display.c:578: warning: Function parameter or member 'disp_dev' not described in 'vpbe_try_format'
    drivers/media/platform/davinci/vpbe_display.c:578: warning: Function parameter or member 'pixfmt' not described in 'vpbe_try_format'
    drivers/media/platform/davinci/vpbe_display.c:578: warning: Function parameter or member 'check' not described in 'vpbe_try_format'
    drivers/media/platform/davinci/vpbe_display.c:943: warning: Function parameter or member 'file' not described in 'vpbe_display_s_std'
    drivers/media/platform/davinci/vpbe_display.c:943: warning: Function parameter or member 'priv' not described in 'vpbe_display_s_std'
    drivers/media/platform/davinci/vpbe_display.c:943: warning: Function parameter or member 'std_id' not described in 'vpbe_display_s_std'
    drivers/media/platform/davinci/vpbe_display.c:975: warning: Function parameter or member 'file' not described in 'vpbe_display_g_std'
    drivers/media/platform/davinci/vpbe_display.c:975: warning: Function parameter or member 'priv' not described in 'vpbe_display_g_std'
    drivers/media/platform/davinci/vpbe_display.c:975: warning: Function parameter or member 'std_id' not described in 'vpbe_display_g_std'
    drivers/media/platform/davinci/vpbe_display.c:998: warning: Function parameter or member 'file' not described in 'vpbe_display_enum_output'
    drivers/media/platform/davinci/vpbe_display.c:998: warning: Function parameter or member 'priv' not described in 'vpbe_display_enum_output'
    drivers/media/platform/davinci/vpbe_display.c:998: warning: Function parameter or member 'output' not described in 'vpbe_display_enum_output'
    drivers/media/platform/davinci/vpbe_display.c:1025: warning: Function parameter or member 'file' not described in 'vpbe_display_s_output'
    drivers/media/platform/davinci/vpbe_display.c:1025: warning: Function parameter or member 'priv' not described in 'vpbe_display_s_output'
    drivers/media/platform/davinci/vpbe_display.c:1025: warning: Function parameter or member 'i' not described in 'vpbe_display_s_output'
    drivers/media/platform/davinci/vpbe_display.c:1054: warning: Function parameter or member 'file' not described in 'vpbe_display_g_output'
    drivers/media/platform/davinci/vpbe_display.c:1054: warning: Function parameter or member 'priv' not described in 'vpbe_display_g_output'
    drivers/media/platform/davinci/vpbe_display.c:1054: warning: Function parameter or member 'i' not described in 'vpbe_display_g_output'
    drivers/media/platform/davinci/vpbe_display.c:1074: warning: Function parameter or member 'file' not described in 'vpbe_display_enum_dv_timings'
    drivers/media/platform/davinci/vpbe_display.c:1074: warning: Function parameter or member 'priv' not described in 'vpbe_display_enum_dv_timings'
    drivers/media/platform/davinci/vpbe_display.c:1074: warning: Function parameter or member 'timings' not described in 'vpbe_display_enum_dv_timings'
    drivers/media/platform/davinci/vpbe_display.c:1104: warning: Function parameter or member 'file' not described in 'vpbe_display_s_dv_timings'
    drivers/media/platform/davinci/vpbe_display.c:1104: warning: Function parameter or member 'priv' not described in 'vpbe_display_s_dv_timings'
    drivers/media/platform/davinci/vpbe_display.c:1104: warning: Function parameter or member 'timings' not described in 'vpbe_display_s_dv_timings'
    drivers/media/platform/davinci/vpbe_display.c:1137: warning: Function parameter or member 'file' not described in 'vpbe_display_g_dv_timings'
    drivers/media/platform/davinci/vpbe_display.c:1137: warning: Function parameter or member 'priv' not described in 'vpbe_display_g_dv_timings'
    drivers/media/platform/davinci/vpbe_display.c:1137: warning: Function parameter or member 'dv_timings' not described in 'vpbe_display_g_dv_timings'

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/davinci/vpbe.c         | 38 ++++++++++++++-------------
 drivers/media/platform/davinci/vpbe_display.c | 18 ++++++-------
 drivers/media/platform/davinci/vpbe_osd.c     | 14 +++++-----
 3 files changed, 36 insertions(+), 34 deletions(-)

diff --git a/drivers/media/platform/davinci/vpbe.c b/drivers/media/platform/davinci/vpbe.c
index 7f6462562579..18c035ef84cf 100644
--- a/drivers/media/platform/davinci/vpbe.c
+++ b/drivers/media/platform/davinci/vpbe.c
@@ -51,7 +51,7 @@ MODULE_AUTHOR("Texas Instruments");
 
 /**
  * vpbe_current_encoder_info - Get config info for current encoder
- * @vpbe_dev - vpbe device ptr
+ * @vpbe_dev: vpbe device ptr
  *
  * Return ptr to current encoder config info
  */
@@ -68,8 +68,8 @@ vpbe_current_encoder_info(struct vpbe_device *vpbe_dev)
 /**
  * vpbe_find_encoder_sd_index - Given a name find encoder sd index
  *
- * @vpbe_config - ptr to vpbe cfg
- * @output_index - index used by application
+ * @cfg: ptr to vpbe cfg
+ * @index: index used by application
  *
  * Return sd index of the encoder
  */
@@ -94,8 +94,8 @@ static int vpbe_find_encoder_sd_index(struct vpbe_config *cfg,
 
 /**
  * vpbe_g_cropcap - Get crop capabilities of the display
- * @vpbe_dev - vpbe device ptr
- * @cropcap - cropcap is a ptr to struct v4l2_cropcap
+ * @vpbe_dev: vpbe device ptr
+ * @cropcap: cropcap is a ptr to struct v4l2_cropcap
  *
  * Update the crop capabilities in crop cap for current
  * mode
@@ -116,8 +116,8 @@ static int vpbe_g_cropcap(struct vpbe_device *vpbe_dev,
 
 /**
  * vpbe_enum_outputs - enumerate outputs
- * @vpbe_dev - vpbe device ptr
- * @output - ptr to v4l2_output structure
+ * @vpbe_dev: vpbe device ptr
+ * @output: ptr to v4l2_output structure
  *
  * Enumerates the outputs available at the vpbe display
  * returns the status, -EINVAL if end of output list
@@ -212,8 +212,8 @@ static int vpbe_get_std_info_by_name(struct vpbe_device *vpbe_dev,
 
 /**
  * vpbe_set_output - Set output
- * @vpbe_dev - vpbe device ptr
- * @index - index of output
+ * @vpbe_dev: vpbe device ptr
+ * @index: index of output
  *
  * Set vpbe output to the output specified by the index
  */
@@ -308,7 +308,7 @@ static int vpbe_set_default_output(struct vpbe_device *vpbe_dev)
 
 /**
  * vpbe_get_output - Get output
- * @vpbe_dev - vpbe device ptr
+ * @vpbe_dev: vpbe device ptr
  *
  * return current vpbe output to the the index
  */
@@ -317,7 +317,7 @@ static unsigned int vpbe_get_output(struct vpbe_device *vpbe_dev)
 	return vpbe_dev->current_out_index;
 }
 
-/**
+/*
  * vpbe_s_dv_timings - Set the given preset timings in the encoder
  *
  * Sets the timings if supported by the current encoder. Return the status.
@@ -369,7 +369,7 @@ static int vpbe_s_dv_timings(struct vpbe_device *vpbe_dev,
 	return ret;
 }
 
-/**
+/*
  * vpbe_g_dv_timings - Get the timings in the current encoder
  *
  * Get the timings in the current encoder. Return the status. 0 - success
@@ -394,7 +394,7 @@ static int vpbe_g_dv_timings(struct vpbe_device *vpbe_dev,
 	return -EINVAL;
 }
 
-/**
+/*
  * vpbe_enum_dv_timings - Enumerate the dv timings in the current encoder
  *
  * Get the timings in the current encoder. Return the status. 0 - success
@@ -426,7 +426,7 @@ static int vpbe_enum_dv_timings(struct vpbe_device *vpbe_dev,
 	return 0;
 }
 
-/**
+/*
  * vpbe_s_std - Set the given standard in the encoder
  *
  * Sets the standard if supported by the current encoder. Return the status.
@@ -465,7 +465,7 @@ static int vpbe_s_std(struct vpbe_device *vpbe_dev, v4l2_std_id std_id)
 	return ret;
 }
 
-/**
+/*
  * vpbe_g_std - Get the standard in the current encoder
  *
  * Get the standard in the current encoder. Return the status. 0 - success
@@ -488,7 +488,7 @@ static int vpbe_g_std(struct vpbe_device *vpbe_dev, v4l2_std_id *std_id)
 	return -EINVAL;
 }
 
-/**
+/*
  * vpbe_set_mode - Set mode in the current encoder using mode info
  *
  * Use the mode string to decide what timings to set in the encoder
@@ -572,7 +572,8 @@ static int platform_device_get(struct device *dev, void *data)
 
 /**
  * vpbe_initialize() - Initialize the vpbe display controller
- * @vpbe_dev - vpbe device ptr
+ * @dev: Master and slave device ptr
+ * @vpbe_dev: vpbe device ptr
  *
  * Master frame buffer device drivers calls this to initialize vpbe
  * display controller. This will then registers v4l2 device and the sub
@@ -769,7 +770,8 @@ static int vpbe_initialize(struct device *dev, struct vpbe_device *vpbe_dev)
 
 /**
  * vpbe_deinitialize() - de-initialize the vpbe display controller
- * @dev - Master and slave device ptr
+ * @dev: Master and slave device ptr
+ * @vpbe_dev: vpbe device ptr
  *
  * vpbe_master and slave frame buffer devices calls this to de-initialize
  * the display controller. It is called when master and slave device
diff --git a/drivers/media/platform/davinci/vpbe_display.c b/drivers/media/platform/davinci/vpbe_display.c
index 7b6cd4b3ccc4..9849e4405a6a 100644
--- a/drivers/media/platform/davinci/vpbe_display.c
+++ b/drivers/media/platform/davinci/vpbe_display.c
@@ -567,7 +567,7 @@ static void vpbe_disp_check_window_params(struct vpbe_display *disp_dev,
 
 }
 
-/**
+/*
  * vpbe_try_format()
  * If user application provides width and height, and have bytesperline set
  * to zero, driver calculates bytesperline and sizeimage based on hardware
@@ -932,7 +932,7 @@ static int vpbe_display_try_fmt(struct file *file, void *priv,
 
 }
 
-/**
+/*
  * vpbe_display_s_std - Set the given standard in the encoder
  *
  * Sets the standard if supported by the current encoder. Return the status.
@@ -964,7 +964,7 @@ static int vpbe_display_s_std(struct file *file, void *priv,
 	return 0;
 }
 
-/**
+/*
  * vpbe_display_g_std - Get the standard in the current encoder
  *
  * Get the standard in the current encoder. Return the status. 0 - success
@@ -987,7 +987,7 @@ static int vpbe_display_g_std(struct file *file, void *priv,
 	return -EINVAL;
 }
 
-/**
+/*
  * vpbe_display_enum_output - enumerate outputs
  *
  * Enumerates the outputs available at the vpbe display
@@ -1016,7 +1016,7 @@ static int vpbe_display_enum_output(struct file *file, void *priv,
 	return 0;
 }
 
-/**
+/*
  * vpbe_display_s_output - Set output to
  * the output specified by the index
  */
@@ -1045,7 +1045,7 @@ static int vpbe_display_s_output(struct file *file, void *priv,
 	return 0;
 }
 
-/**
+/*
  * vpbe_display_g_output - Get output from subdevice
  * for a given by the index
  */
@@ -1062,7 +1062,7 @@ static int vpbe_display_g_output(struct file *file, void *priv,
 	return 0;
 }
 
-/**
+/*
  * vpbe_display_enum_dv_timings - Enumerate the dv timings
  *
  * enum the timings in the current encoder. Return the status. 0 - success
@@ -1092,7 +1092,7 @@ vpbe_display_enum_dv_timings(struct file *file, void *priv,
 	return 0;
 }
 
-/**
+/*
  * vpbe_display_s_dv_timings - Set the dv timings
  *
  * Set the timings in the current encoder. Return the status. 0 - success
@@ -1125,7 +1125,7 @@ vpbe_display_s_dv_timings(struct file *file, void *priv,
 	return 0;
 }
 
-/**
+/*
  * vpbe_display_g_dv_timings - Set the dv timings
  *
  * Get the timings in the current encoder. Return the status. 0 - success
diff --git a/drivers/media/platform/davinci/vpbe_osd.c b/drivers/media/platform/davinci/vpbe_osd.c
index 10f2bf11edf3..99a4ec183ba9 100644
--- a/drivers/media/platform/davinci/vpbe_osd.c
+++ b/drivers/media/platform/davinci/vpbe_osd.c
@@ -124,10 +124,10 @@ static inline u32 osd_modify(struct osd_state *sd, u32 mask, u32 val,
 
 /**
  * _osd_dm6446_vid0_pingpong() - field inversion fix for DM6446
- * @sd - ptr to struct osd_state
- * @field_inversion - inversion flag
- * @fb_base_phys - frame buffer address
- * @lconfig - ptr to layer config
+ * @sd: ptr to struct osd_state
+ * @field_inversion: inversion flag
+ * @fb_base_phys: frame buffer address
+ * @lconfig: ptr to layer config
  *
  * This routine implements a workaround for the field signal inversion silicon
  * erratum described in Advisory 1.3.8 for the DM6446.  The fb_base_phys and
@@ -784,9 +784,9 @@ static void osd_get_layer_config(struct osd_state *sd, enum osd_layer layer,
 
 /**
  * try_layer_config() - Try a specific configuration for the layer
- * @sd  - ptr to struct osd_state
- * @layer - layer to configure
- * @lconfig - layer configuration to try
+ * @sd: ptr to struct osd_state
+ * @layer: layer to configure
+ * @lconfig: layer configuration to try
  *
  * If the requested lconfig is completely rejected and the value of lconfig on
  * exit is the current lconfig, then try_layer_config() returns 1.  Otherwise,
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (13 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 14/19] media: davinci: get rid of lots of kernel-doc warnings Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06  8:41   ` Tomi Valkeinen
                     ` (3 more replies)
  2018-04-05 20:29 ` [PATCH v2 16/19] media: omap: " Mauro Carvalho Chehab
                   ` (3 subsequent siblings)
  18 siblings, 4 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Tomi Valkeinen, Bartlomiej Zolnierkiewicz,
	linux-omap, linux-fbdev, dri-devel

This driver builds cleanly with COMPILE_TEST, and it is
needed in order to allow building drivers/media omap2
driver.

So, change the logic there to allow building it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/video/fbdev/omap2/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/video/fbdev/omap2/Kconfig b/drivers/video/fbdev/omap2/Kconfig
index 0921c4de8407..82008699d253 100644
--- a/drivers/video/fbdev/omap2/Kconfig
+++ b/drivers/video/fbdev/omap2/Kconfig
@@ -1,4 +1,4 @@
-if ARCH_OMAP2PLUS
+if ARCH_OMAP2PLUS || COMPILE_TEST
 
 source "drivers/video/fbdev/omap2/omapfb/Kconfig"
 
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 16/19] media: omap: allow building it with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (14 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06 12:11   ` kbuild test robot
  2018-04-05 20:29 ` [PATCH v2 17/19] media: omap4iss: make it build " Mauro Carvalho Chehab
                   ` (2 subsequent siblings)
  18 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List, Mauro Carvalho Chehab

Now that we have stubs for omap FB driver, let it build with
COMPILE_TEST.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/omap/Kconfig | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/media/platform/omap/Kconfig b/drivers/media/platform/omap/Kconfig
index e8e2db181a7a..27343376f557 100644
--- a/drivers/media/platform/omap/Kconfig
+++ b/drivers/media/platform/omap/Kconfig
@@ -1,15 +1,15 @@
 config VIDEO_OMAP2_VOUT_VRFB
 	bool
+	default y
+	depends on VIDEO_OMAP2_VOUT && (OMAP2_VRFB || COMPILE_TEST)
 
 config VIDEO_OMAP2_VOUT
 	tristate "OMAP2/OMAP3 V4L2-Display driver"
-	depends on MMU
-	depends on ARCH_OMAP2 || ARCH_OMAP3
-	depends on FB_OMAP2
+	depends on MMU && FB_OMAP2
+	depends on ARCH_OMAP2 || ARCH_OMAP3 || COMPILE_TEST
 	select VIDEOBUF_GEN
 	select VIDEOBUF_DMA_CONTIG
 	select OMAP2_VRFB if ARCH_OMAP2 || ARCH_OMAP3
-	select VIDEO_OMAP2_VOUT_VRFB if VIDEO_OMAP2_VOUT && OMAP2_VRFB
 	select FRAME_VECTOR
 	default n
 	---help---
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 17/19] media: omap4iss: make it build with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (15 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 16/19] media: omap: " Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-05 20:59   ` Laurent Pinchart
  2018-04-05 20:29 ` [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time Mauro Carvalho Chehab
  2018-04-05 20:29 ` [PATCH v2 19/19] media: staging: davinci_vpfe: allow building with COMPILE_TEST Mauro Carvalho Chehab
  18 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Laurent Pinchart, Greg Kroah-Hartman,
	devel

This driver compile as-is with COMPILE_TEST.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/staging/media/omap4iss/Kconfig | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/media/omap4iss/Kconfig b/drivers/staging/media/omap4iss/Kconfig
index 46183464ee79..192ba0829128 100644
--- a/drivers/staging/media/omap4iss/Kconfig
+++ b/drivers/staging/media/omap4iss/Kconfig
@@ -1,6 +1,7 @@
 config VIDEO_OMAP4
 	tristate "OMAP 4 Camera support"
-	depends on VIDEO_V4L2 && VIDEO_V4L2_SUBDEV_API && I2C && ARCH_OMAP4
+	depends on VIDEO_V4L2 && VIDEO_V4L2_SUBDEV_API && I2C
+	depends on ARCH_OMAP4 || COMPILE_TEST
 	depends on HAS_DMA
 	select MFD_SYSCON
 	select VIDEOBUF2_DMA_CONTIG
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (16 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 17/19] media: omap4iss: make it build " Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06 16:21   ` kbuild test robot
  2018-04-05 20:29 ` [PATCH v2 19/19] media: staging: davinci_vpfe: allow building with COMPILE_TEST Mauro Carvalho Chehab
  18 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Hans Verkuil, Douglas Fischer

Currently, either USB or I2C is built. Change it to allow
having both enabled at the same time.

The main reason is that COMPILE_TEST all[yes/mod]builds will
now contain all drivers under drivers/media.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/radio/Kconfig                      |  4 --
 drivers/media/radio/si470x/Kconfig               | 16 ++++++-
 drivers/media/radio/si470x/Makefile              |  8 ++--
 drivers/media/radio/si470x/radio-si470x-common.c | 61 +++++++++++++++++-------
 drivers/media/radio/si470x/radio-si470x-i2c.c    | 18 ++++---
 drivers/media/radio/si470x/radio-si470x-usb.c    | 18 ++++---
 drivers/media/radio/si470x/radio-si470x.h        | 15 +++---
 7 files changed, 95 insertions(+), 45 deletions(-)

diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig
index 192f36f2f4aa..2ed539f9eb87 100644
--- a/drivers/media/radio/Kconfig
+++ b/drivers/media/radio/Kconfig
@@ -15,10 +15,6 @@ if RADIO_ADAPTERS && VIDEO_V4L2
 config RADIO_TEA575X
 	tristate
 
-config RADIO_SI470X
-	bool "Silicon Labs Si470x FM Radio Receiver support"
-	depends on VIDEO_V4L2
-
 source "drivers/media/radio/si470x/Kconfig"
 
 config RADIO_SI4713
diff --git a/drivers/media/radio/si470x/Kconfig b/drivers/media/radio/si470x/Kconfig
index a466654ee5c9..a21172e413a9 100644
--- a/drivers/media/radio/si470x/Kconfig
+++ b/drivers/media/radio/si470x/Kconfig
@@ -1,3 +1,17 @@
+config RADIO_SI470X
+        tristate "Silicon Labs Si470x FM Radio Receiver support"
+        depends on VIDEO_V4L2
+	---help---
+	  This is a driver for devices with the Silicon Labs SI470x
+	  chip (either via USB or I2C buses).
+
+	  Say Y here if you want to connect this type of radio to your
+	  computer's USB port or if it is used by some other driver
+	  via I2C bus.
+
+	  To compile this driver as a module, choose M here: the
+	  module will be called radio-si470x-common.
+
 config USB_SI470X
 	tristate "Silicon Labs Si470x FM Radio Receiver support with USB"
 	depends on USB && RADIO_SI470X
@@ -25,7 +39,7 @@ config USB_SI470X
 
 config I2C_SI470X
 	tristate "Silicon Labs Si470x FM Radio Receiver support with I2C"
-	depends on I2C && RADIO_SI470X && !USB_SI470X
+	depends on I2C && RADIO_SI470X
 	---help---
 	  This is a driver for I2C devices with the Silicon Labs SI470x
 	  chip.
diff --git a/drivers/media/radio/si470x/Makefile b/drivers/media/radio/si470x/Makefile
index 06964816cfd6..563500823e04 100644
--- a/drivers/media/radio/si470x/Makefile
+++ b/drivers/media/radio/si470x/Makefile
@@ -2,8 +2,6 @@
 # Makefile for radios with Silicon Labs Si470x FM Radio Receivers
 #
 
-radio-usb-si470x-objs	:= radio-si470x-usb.o radio-si470x-common.o
-radio-i2c-si470x-objs	:= radio-si470x-i2c.o radio-si470x-common.o
-
-obj-$(CONFIG_USB_SI470X) += radio-usb-si470x.o
-obj-$(CONFIG_I2C_SI470X) += radio-i2c-si470x.o
+obj-$(CONFIG_RADIO_SI470X) := radio-si470x-common.o
+obj-$(CONFIG_USB_SI470X) += radio-si470x-usb.o
+obj-$(CONFIG_I2C_SI470X) += radio-si470x-i2c.o
diff --git a/drivers/media/radio/si470x/radio-si470x-common.c b/drivers/media/radio/si470x/radio-si470x-common.c
index b94d66e53d4e..23bc50260b85 100644
--- a/drivers/media/radio/si470x/radio-si470x-common.c
+++ b/drivers/media/radio/si470x/radio-si470x-common.c
@@ -195,7 +195,7 @@ static int si470x_set_band(struct si470x_device *radio, int band)
 	radio->band = band;
 	radio->registers[SYSCONFIG2] &= ~SYSCONFIG2_BAND;
 	radio->registers[SYSCONFIG2] |= radio->band << 6;
-	return si470x_set_register(radio, SYSCONFIG2);
+	return radio->set_register(radio, SYSCONFIG2);
 }
 
 /*
@@ -207,7 +207,7 @@ static int si470x_set_chan(struct si470x_device *radio, unsigned short chan)
 	unsigned long time_left;
 	bool timed_out = false;
 
-	retval = si470x_get_register(radio, POWERCFG);
+	retval = radio->get_register(radio, POWERCFG);
 	if (retval)
 		return retval;
 
@@ -219,7 +219,7 @@ static int si470x_set_chan(struct si470x_device *radio, unsigned short chan)
 	/* start tuning */
 	radio->registers[CHANNEL] &= ~CHANNEL_CHAN;
 	radio->registers[CHANNEL] |= CHANNEL_TUNE | chan;
-	retval = si470x_set_register(radio, CHANNEL);
+	retval = radio->set_register(radio, CHANNEL);
 	if (retval < 0)
 		goto done;
 
@@ -238,7 +238,7 @@ static int si470x_set_chan(struct si470x_device *radio, unsigned short chan)
 
 	/* stop tuning */
 	radio->registers[CHANNEL] &= ~CHANNEL_TUNE;
-	retval = si470x_set_register(radio, CHANNEL);
+	retval = radio->set_register(radio, CHANNEL);
 
 done:
 	return retval;
@@ -272,7 +272,7 @@ static int si470x_get_freq(struct si470x_device *radio, unsigned int *freq)
 	int chan, retval;
 
 	/* read channel */
-	retval = si470x_get_register(radio, READCHAN);
+	retval = radio->get_register(radio, READCHAN);
 	chan = radio->registers[READCHAN] & READCHAN_READCHAN;
 
 	/* Frequency (MHz) = Spacing (kHz) x Channel + Bottom of Band (MHz) */
@@ -343,7 +343,7 @@ static int si470x_set_seek(struct si470x_device *radio,
 		radio->registers[POWERCFG] |= POWERCFG_SEEKUP;
 	else
 		radio->registers[POWERCFG] &= ~POWERCFG_SEEKUP;
-	retval = si470x_set_register(radio, POWERCFG);
+	retval = radio->set_register(radio, POWERCFG);
 	if (retval < 0)
 		return retval;
 
@@ -362,7 +362,7 @@ static int si470x_set_seek(struct si470x_device *radio,
 
 	/* stop seeking */
 	radio->registers[POWERCFG] &= ~POWERCFG_SEEK;
-	retval = si470x_set_register(radio, POWERCFG);
+	retval = radio->set_register(radio, POWERCFG);
 
 	/* try again, if timed out */
 	if (retval == 0 && timed_out)
@@ -381,7 +381,7 @@ int si470x_start(struct si470x_device *radio)
 	/* powercfg */
 	radio->registers[POWERCFG] =
 		POWERCFG_DMUTE | POWERCFG_ENABLE | POWERCFG_RDSM;
-	retval = si470x_set_register(radio, POWERCFG);
+	retval = radio->set_register(radio, POWERCFG);
 	if (retval < 0)
 		goto done;
 
@@ -392,7 +392,7 @@ int si470x_start(struct si470x_device *radio)
 	radio->registers[SYSCONFIG1] |= SYSCONFIG1_GPIO2_INT;
 	if (de)
 		radio->registers[SYSCONFIG1] |= SYSCONFIG1_DE;
-	retval = si470x_set_register(radio, SYSCONFIG1);
+	retval = radio->set_register(radio, SYSCONFIG1);
 	if (retval < 0)
 		goto done;
 
@@ -402,7 +402,7 @@ int si470x_start(struct si470x_device *radio)
 		((radio->band << 6) & SYSCONFIG2_BAND) |/* BAND */
 		((space << 4) & SYSCONFIG2_SPACE) |	/* SPACE */
 		15;					/* VOLUME (max) */
-	retval = si470x_set_register(radio, SYSCONFIG2);
+	retval = radio->set_register(radio, SYSCONFIG2);
 	if (retval < 0)
 		goto done;
 
@@ -424,7 +424,7 @@ int si470x_stop(struct si470x_device *radio)
 
 	/* sysconfig 1 */
 	radio->registers[SYSCONFIG1] &= ~SYSCONFIG1_RDS;
-	retval = si470x_set_register(radio, SYSCONFIG1);
+	retval = radio->set_register(radio, SYSCONFIG1);
 	if (retval < 0)
 		goto done;
 
@@ -432,7 +432,7 @@ int si470x_stop(struct si470x_device *radio)
 	radio->registers[POWERCFG] &= ~POWERCFG_DMUTE;
 	/* POWERCFG_ENABLE has to automatically go low */
 	radio->registers[POWERCFG] |= POWERCFG_ENABLE |	POWERCFG_DISABLE;
-	retval = si470x_set_register(radio, POWERCFG);
+	retval = radio->set_register(radio, POWERCFG);
 
 done:
 	return retval;
@@ -448,7 +448,7 @@ static int si470x_rds_on(struct si470x_device *radio)
 
 	/* sysconfig 1 */
 	radio->registers[SYSCONFIG1] |= SYSCONFIG1_RDS;
-	retval = si470x_set_register(radio, SYSCONFIG1);
+	retval = radio->set_register(radio, SYSCONFIG1);
 	if (retval < 0)
 		radio->registers[SYSCONFIG1] &= ~SYSCONFIG1_RDS;
 
@@ -542,6 +542,25 @@ static __poll_t si470x_fops_poll(struct file *file,
 }
 
 
+static int si470x_fops_open(struct file *file)
+{
+	struct si470x_device *radio = video_drvdata(file);
+
+	return radio->fops_open(file);
+}
+
+
+/*
+ * si470x_fops_release - file release
+ */
+static int si470x_fops_release(struct file *file)
+{
+	struct si470x_device *radio = video_drvdata(file);
+
+	return radio->fops_release(file);
+}
+
+
 /*
  * si470x_fops - file operations interface
  */
@@ -570,13 +589,13 @@ static int si470x_s_ctrl(struct v4l2_ctrl *ctrl)
 	case V4L2_CID_AUDIO_VOLUME:
 		radio->registers[SYSCONFIG2] &= ~SYSCONFIG2_VOLUME;
 		radio->registers[SYSCONFIG2] |= ctrl->val;
-		return si470x_set_register(radio, SYSCONFIG2);
+		return radio->set_register(radio, SYSCONFIG2);
 	case V4L2_CID_AUDIO_MUTE:
 		if (ctrl->val)
 			radio->registers[POWERCFG] &= ~POWERCFG_DMUTE;
 		else
 			radio->registers[POWERCFG] |= POWERCFG_DMUTE;
-		return si470x_set_register(radio, POWERCFG);
+		return radio->set_register(radio, POWERCFG);
 	default:
 		return -EINVAL;
 	}
@@ -596,7 +615,7 @@ static int si470x_vidioc_g_tuner(struct file *file, void *priv,
 		return -EINVAL;
 
 	if (!radio->status_rssi_auto_update) {
-		retval = si470x_get_register(radio, STATUSRSSI);
+		retval = radio->get_register(radio, STATUSRSSI);
 		if (retval < 0)
 			return retval;
 	}
@@ -665,7 +684,7 @@ static int si470x_vidioc_s_tuner(struct file *file, void *priv,
 		break;
 	}
 
-	return si470x_set_register(radio, POWERCFG);
+	return radio->set_register(radio, POWERCFG);
 }
 
 
@@ -743,6 +762,14 @@ const struct v4l2_ctrl_ops si470x_ctrl_ops = {
 	.s_ctrl = si470x_s_ctrl,
 };
 
+static int si470x_vidioc_querycap(struct file *file, void *priv,
+		struct v4l2_capability *capability)
+{
+	struct si470x_device *radio = video_drvdata(file);
+
+	return radio->vidioc_querycap(file, priv, capability);
+};
+
 /*
  * si470x_ioctl_ops - video device ioctl operations
  */
diff --git a/drivers/media/radio/si470x/radio-si470x-i2c.c b/drivers/media/radio/si470x/radio-si470x-i2c.c
index 41709b24b28f..1b3720b1e737 100644
--- a/drivers/media/radio/si470x/radio-si470x-i2c.c
+++ b/drivers/media/radio/si470x/radio-si470x-i2c.c
@@ -89,7 +89,7 @@ MODULE_PARM_DESC(max_rds_errors, "RDS maximum block errors: *1*");
 /*
  * si470x_get_register - read register
  */
-int si470x_get_register(struct si470x_device *radio, int regnr)
+static int si470x_get_register(struct si470x_device *radio, int regnr)
 {
 	u16 buf[READ_REG_NUM];
 	struct i2c_msg msgs[1] = {
@@ -113,7 +113,7 @@ int si470x_get_register(struct si470x_device *radio, int regnr)
 /*
  * si470x_set_register - write register
  */
-int si470x_set_register(struct si470x_device *radio, int regnr)
+static int si470x_set_register(struct si470x_device *radio, int regnr)
 {
 	int i;
 	u16 buf[WRITE_REG_NUM];
@@ -174,7 +174,7 @@ static int si470x_get_all_registers(struct si470x_device *radio)
 /*
  * si470x_fops_open - file open
  */
-int si470x_fops_open(struct file *file)
+static int si470x_fops_open(struct file *file)
 {
 	struct si470x_device *radio = video_drvdata(file);
 	int retval = v4l2_fh_open(file);
@@ -206,7 +206,7 @@ int si470x_fops_open(struct file *file)
 /*
  * si470x_fops_release - file release
  */
-int si470x_fops_release(struct file *file)
+static int si470x_fops_release(struct file *file)
 {
 	struct si470x_device *radio = video_drvdata(file);
 
@@ -226,8 +226,8 @@ int si470x_fops_release(struct file *file)
 /*
  * si470x_vidioc_querycap - query device capabilities
  */
-int si470x_vidioc_querycap(struct file *file, void *priv,
-		struct v4l2_capability *capability)
+static int si470x_vidioc_querycap(struct file *file, void *priv,
+				  struct v4l2_capability *capability)
 {
 	strlcpy(capability->driver, DRIVER_NAME, sizeof(capability->driver));
 	strlcpy(capability->card, DRIVER_CARD, sizeof(capability->card));
@@ -361,6 +361,12 @@ static int si470x_i2c_probe(struct i2c_client *client,
 	mutex_init(&radio->lock);
 	init_completion(&radio->completion);
 
+	radio->get_register = si470x_get_register;
+	radio->set_register = si470x_set_register;
+	radio->fops_open = si470x_fops_open;
+	radio->fops_release = si470x_fops_release;
+	radio->vidioc_querycap = si470x_vidioc_querycap;
+
 	retval = v4l2_device_register(&client->dev, &radio->v4l2_dev);
 	if (retval < 0) {
 		dev_err(&client->dev, "couldn't register v4l2_device\n");
diff --git a/drivers/media/radio/si470x/radio-si470x-usb.c b/drivers/media/radio/si470x/radio-si470x-usb.c
index 2277e850bb5e..313a95f195a2 100644
--- a/drivers/media/radio/si470x/radio-si470x-usb.c
+++ b/drivers/media/radio/si470x/radio-si470x-usb.c
@@ -250,7 +250,7 @@ static int si470x_set_report(struct si470x_device *radio, void *buf, int size)
 /*
  * si470x_get_register - read register
  */
-int si470x_get_register(struct si470x_device *radio, int regnr)
+static int si470x_get_register(struct si470x_device *radio, int regnr)
 {
 	int retval;
 
@@ -268,7 +268,7 @@ int si470x_get_register(struct si470x_device *radio, int regnr)
 /*
  * si470x_set_register - write register
  */
-int si470x_set_register(struct si470x_device *radio, int regnr)
+static int si470x_set_register(struct si470x_device *radio, int regnr)
 {
 	int retval;
 
@@ -482,12 +482,12 @@ static void si470x_int_in_callback(struct urb *urb)
 }
 
 
-int si470x_fops_open(struct file *file)
+static int si470x_fops_open(struct file *file)
 {
 	return v4l2_fh_open(file);
 }
 
-int si470x_fops_release(struct file *file)
+static int si470x_fops_release(struct file *file)
 {
 	return v4l2_fh_release(file);
 }
@@ -514,8 +514,8 @@ static void si470x_usb_release(struct v4l2_device *v4l2_dev)
 /*
  * si470x_vidioc_querycap - query device capabilities
  */
-int si470x_vidioc_querycap(struct file *file, void *priv,
-		struct v4l2_capability *capability)
+static int si470x_vidioc_querycap(struct file *file, void *priv,
+				  struct v4l2_capability *capability)
 {
 	struct si470x_device *radio = video_drvdata(file);
 
@@ -598,6 +598,12 @@ static int si470x_usb_driver_probe(struct usb_interface *intf,
 	mutex_init(&radio->lock);
 	init_completion(&radio->completion);
 
+	radio->get_register = si470x_get_register;
+	radio->set_register = si470x_set_register;
+	radio->fops_open = si470x_fops_open;
+	radio->fops_release = si470x_fops_release;
+	radio->vidioc_querycap = si470x_vidioc_querycap;
+
 	iface_desc = intf->cur_altsetting;
 
 	/* Set up interrupt endpoint information. */
diff --git a/drivers/media/radio/si470x/radio-si470x.h b/drivers/media/radio/si470x/radio-si470x.h
index 0202f8eb90c4..35fa0f3bbdd2 100644
--- a/drivers/media/radio/si470x/radio-si470x.h
+++ b/drivers/media/radio/si470x/radio-si470x.h
@@ -161,6 +161,15 @@ struct si470x_device {
 	struct completion completion;
 	bool status_rssi_auto_update;	/* Does RSSI get updated automatic? */
 
+	/* si470x ops */
+
+	int (*get_register)(struct si470x_device *radio, int regnr);
+	int (*set_register)(struct si470x_device *radio, int regnr);
+	int (*fops_open)(struct file *file);
+	int (*fops_release)(struct file *file);
+	int (*vidioc_querycap)(struct file *file, void *priv,
+			       struct v4l2_capability *capability);
+
 #if IS_ENABLED(CONFIG_USB_SI470X)
 	/* reference to USB and video device */
 	struct usb_device *usbdev;
@@ -213,13 +222,7 @@ struct si470x_device {
  **************************************************************************/
 extern const struct video_device si470x_viddev_template;
 extern const struct v4l2_ctrl_ops si470x_ctrl_ops;
-int si470x_get_register(struct si470x_device *radio, int regnr);
-int si470x_set_register(struct si470x_device *radio, int regnr);
 int si470x_disconnect_check(struct si470x_device *radio);
 int si470x_set_freq(struct si470x_device *radio, unsigned int freq);
 int si470x_start(struct si470x_device *radio);
 int si470x_stop(struct si470x_device *radio);
-int si470x_fops_open(struct file *file);
-int si470x_fops_release(struct file *file);
-int si470x_vidioc_querycap(struct file *file, void *priv,
-		struct v4l2_capability *capability);
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v2 19/19] media: staging: davinci_vpfe: allow building with COMPILE_TEST
  2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
                   ` (17 preceding siblings ...)
  2018-04-05 20:29 ` [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time Mauro Carvalho Chehab
@ 2018-04-05 20:29 ` Mauro Carvalho Chehab
  2018-04-06 22:25   ` kbuild test robot
  18 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-05 20:29 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Greg Kroah-Hartman, devel

This is a little bit hashish, but this driver is at staging,
so it won't become worse.

With this small change at Makefile, we can now build it with
COMPILE_TEST.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/staging/media/davinci_vpfe/Kconfig  | 3 ++-
 drivers/staging/media/davinci_vpfe/Makefile | 5 +++++
 drivers/staging/media/davinci_vpfe/TODO     | 1 +
 3 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/media/davinci_vpfe/Kconfig b/drivers/staging/media/davinci_vpfe/Kconfig
index f40a06954a92..bcba9a64c514 100644
--- a/drivers/staging/media/davinci_vpfe/Kconfig
+++ b/drivers/staging/media/davinci_vpfe/Kconfig
@@ -1,6 +1,7 @@
 config VIDEO_DM365_VPFE
 	tristate "DM365 VPFE Media Controller Capture Driver"
-	depends on VIDEO_V4L2 && ARCH_DAVINCI_DM365 && !VIDEO_DM365_ISIF
+	depends on VIDEO_V4L2
+	depends on (ARCH_DAVINCI_DM365 && !VIDEO_DM365_ISIF) || COMPILE_TEST
 	depends on HAS_DMA
 	depends on VIDEO_V4L2_SUBDEV_API
 	depends on VIDEO_DAVINCI_VPBE_DISPLAY
diff --git a/drivers/staging/media/davinci_vpfe/Makefile b/drivers/staging/media/davinci_vpfe/Makefile
index 3019c9ecd548..9c57042c877d 100644
--- a/drivers/staging/media/davinci_vpfe/Makefile
+++ b/drivers/staging/media/davinci_vpfe/Makefile
@@ -3,3 +3,8 @@ obj-$(CONFIG_VIDEO_DM365_VPFE) += davinci-vfpe.o
 davinci-vfpe-objs := \
 	dm365_isif.o dm365_ipipe_hw.o dm365_ipipe.o \
 	dm365_resizer.o dm365_ipipeif.o vpfe_mc_capture.o vpfe_video.o
+
+# Allow building it with COMPILE_TEST on other archs
+ifndef CONFIG_ARCH_DAVINCI
+ccflags-y += -Iarch/arm/mach-davinci/include/
+endif
diff --git a/drivers/staging/media/davinci_vpfe/TODO b/drivers/staging/media/davinci_vpfe/TODO
index 3e5477e8cfa5..cc8bd9306f2a 100644
--- a/drivers/staging/media/davinci_vpfe/TODO
+++ b/drivers/staging/media/davinci_vpfe/TODO
@@ -20,6 +20,7 @@ TODO (general):
 - While replacing the older driver in media folder, provide a compatibility
   layer and compatibility tests that warrants (using the libv4l's LD_PRELOAD
   approach) there is no regression for the users using the older driver.
+- make it independent of arch-specific APIs (mach/mux.h).
 
 Building of uImage and Applications:
 ==================================
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 17/19] media: omap4iss: make it build with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 17/19] media: omap4iss: make it build " Mauro Carvalho Chehab
@ 2018-04-05 20:59   ` Laurent Pinchart
  0 siblings, 0 replies; 40+ messages in thread
From: Laurent Pinchart @ 2018-04-05 20:59 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab,
	Greg Kroah-Hartman, devel

Hi Mauro,

Thank you for the patch.

On Thursday, 5 April 2018 23:29:44 EEST Mauro Carvalho Chehab wrote:
> This driver compile as-is with COMPILE_TEST.
> 
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

I don't have patches pending for the omap4iss driver, could you merge this 
patch as part of the whole series ?

> ---
>  drivers/staging/media/omap4iss/Kconfig | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/media/omap4iss/Kconfig
> b/drivers/staging/media/omap4iss/Kconfig index 46183464ee79..192ba0829128
> 100644
> --- a/drivers/staging/media/omap4iss/Kconfig
> +++ b/drivers/staging/media/omap4iss/Kconfig
> @@ -1,6 +1,7 @@
>  config VIDEO_OMAP4
>  	tristate "OMAP 4 Camera support"
> -	depends on VIDEO_V4L2 && VIDEO_V4L2_SUBDEV_API && I2C && ARCH_OMAP4
> +	depends on VIDEO_V4L2 && VIDEO_V4L2_SUBDEV_API && I2C
> +	depends on ARCH_OMAP4 || COMPILE_TEST
>  	depends on HAS_DMA
>  	select MFD_SYSCON
>  	select VIDEOBUF2_DMA_CONTIG


-- 
Regards,

Laurent Pinchart

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST Mauro Carvalho Chehab
@ 2018-04-06  8:41   ` Tomi Valkeinen
  2018-04-06 11:46   ` kbuild test robot
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 40+ messages in thread
From: Tomi Valkeinen @ 2018-04-06  8:41 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab,
	Bartlomiej Zolnierkiewicz, linux-omap, linux-fbdev, dri-devel

On 05/04/18 23:29, Mauro Carvalho Chehab wrote:
> This driver builds cleanly with COMPILE_TEST, and it is
> needed in order to allow building drivers/media omap2
> driver.
> 
> So, change the logic there to allow building it.
> 
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
> ---
>  drivers/video/fbdev/omap2/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/video/fbdev/omap2/Kconfig b/drivers/video/fbdev/omap2/Kconfig
> index 0921c4de8407..82008699d253 100644
> --- a/drivers/video/fbdev/omap2/Kconfig
> +++ b/drivers/video/fbdev/omap2/Kconfig
> @@ -1,4 +1,4 @@
> -if ARCH_OMAP2PLUS
> +if ARCH_OMAP2PLUS || COMPILE_TEST
>  
>  source "drivers/video/fbdev/omap2/omapfb/Kconfig"
>  
> 

Acked-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

 Tomi

-- 
Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki.
Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 05/19] media: fsl-viu: allow building it with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 05/19] media: fsl-viu: allow building it with COMPILE_TEST Mauro Carvalho Chehab
@ 2018-04-06 10:43   ` kbuild test robot
  2018-04-06 14:03   ` kbuild test robot
  1 sibling, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 10:43 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Hans Verkuil, Arnd Bergmann,
	Stanimir Varbanov, Benjamin Gaignard, Philipp Zabel,
	Ramesh Shanmugasundaram, Al Viro, Bhumika Goyal, Geliang Tang,
	Kees Cook

[-- Attachment #1: Type: text/plain, Size: 1863 bytes --]

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
config: sparc64-allyesconfig (attached as .config)
compiler: sparc64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        make.cross ARCH=sparc64 

All warnings (new ones prefixed by >>):

>> drivers/media/platform/fsl-viu.c:41:0: warning: "NO_IRQ" redefined
    #define NO_IRQ   0
    
   In file included from arch/sparc/include/asm/irq.h:5:0,
                    from include/linux/interrupt.h:19,
                    from drivers/media/platform/fsl-viu.c:22:
   arch/sparc/include/asm/irq_64.h:98:0: note: this is the location of the previous definition
    #define NO_IRQ  0xffffffff
    
   drivers/media/platform/fsl-viu.c: In function 'viu_setup_preview':
   drivers/media/platform/fsl-viu.c:760:28: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
     reg_val.field_base_addr = (u32)dev->ovbuf.base;
                               ^

vim +/NO_IRQ +41 drivers/media/platform/fsl-viu.c

    38	
    39	/* Allow building this driver with COMPILE_TEST */
    40	#ifndef CONFIG_PPC_MPC512x
  > 41	#define NO_IRQ   0
    42	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 52945 bytes --]

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST Mauro Carvalho Chehab
  2018-04-06  8:41   ` Tomi Valkeinen
@ 2018-04-06 11:46   ` kbuild test robot
  2018-04-06 19:29   ` kbuild test robot
  2018-04-20 15:13   ` Bartlomiej Zolnierkiewicz
  3 siblings, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 11:46 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Tomi Valkeinen, Bartlomiej Zolnierkiewicz,
	linux-omap, linux-fbdev, dri-devel

[-- Attachment #1: Type: text/plain, Size: 2503 bytes --]

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
config: mips-allmodconfig (attached as .config)
compiler: mips-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        make.cross ARCH=mips 

All warnings (new ones prefixed by >>):

   drivers/video/fbdev/omap2/omapfb/dss/dispc.c: In function 'pixinc':
>> drivers/video/fbdev/omap2/omapfb/dss/dispc.c:1859:2: warning: this 'else' clause does not guard... [-Wmisleading-indentation]
     else
     ^~~~
   drivers/video/fbdev/omap2/omapfb/dss/dispc.c:1861:3: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'else'
      return 0;
      ^~~~~~

vim +/else +1859 drivers/video/fbdev/omap2/omapfb/dss/dispc.c

f76ee892 Tomi Valkeinen 2015-12-09  1850  
f76ee892 Tomi Valkeinen 2015-12-09  1851  static s32 pixinc(int pixels, u8 ps)
f76ee892 Tomi Valkeinen 2015-12-09  1852  {
f76ee892 Tomi Valkeinen 2015-12-09  1853  	if (pixels == 1)
f76ee892 Tomi Valkeinen 2015-12-09  1854  		return 1;
f76ee892 Tomi Valkeinen 2015-12-09  1855  	else if (pixels > 1)
f76ee892 Tomi Valkeinen 2015-12-09  1856  		return 1 + (pixels - 1) * ps;
f76ee892 Tomi Valkeinen 2015-12-09  1857  	else if (pixels < 0)
f76ee892 Tomi Valkeinen 2015-12-09  1858  		return 1 - (-pixels + 1) * ps;
f76ee892 Tomi Valkeinen 2015-12-09 @1859  	else
f76ee892 Tomi Valkeinen 2015-12-09  1860  		BUG();
f76ee892 Tomi Valkeinen 2015-12-09  1861  		return 0;
f76ee892 Tomi Valkeinen 2015-12-09  1862  }
f76ee892 Tomi Valkeinen 2015-12-09  1863  

:::::: The code at line 1859 was first introduced by commit
:::::: f76ee892a99e68b55402b8d4b8aeffcae2aff34d omapfb: copy omapdss & displays for omapfb

:::::: TO: Tomi Valkeinen <tomi.valkeinen@ti.com>
:::::: CC: Tomi Valkeinen <tomi.valkeinen@ti.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 55128 bytes --]

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 16/19] media: omap: allow building it with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 16/19] media: omap: " Mauro Carvalho Chehab
@ 2018-04-06 12:11   ` kbuild test robot
  0 siblings, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 12:11 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab

[-- Attachment #1: Type: text/plain, Size: 23860 bytes --]

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
config: sparc64-allyesconfig (attached as .config)
compiler: sparc64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        make.cross ARCH=sparc64 

All warnings (new ones prefixed by >>):

   In file included from arch/sparc/include/asm/page.h:8:0,
                    from arch/sparc/include/asm/thread_info_64.h:27,
                    from arch/sparc/include/asm/thread_info.h:5,
                    from include/linux/thread_info.h:38,
                    from include/asm-generic/preempt.h:5,
                    from ./arch/sparc/include/generated/asm/preempt.h:1,
                    from include/linux/preempt.h:81,
                    from include/linux/spinlock.h:51,
                    from include/linux/seqlock.h:36,
                    from include/linux/time.h:6,
                    from include/linux/stat.h:19,
                    from include/linux/module.h:10,
                    from drivers/media/platform/omap/omap_vout.c:33:
   drivers/media/platform/omap/omap_vout.c: In function 'omap_vout_get_userptr':
   drivers/media/platform/omap/omap_vout.c:209:25: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
      *physp = virt_to_phys((void *)virtp);
                            ^
   arch/sparc/include/asm/page_64.h:147:36: note: in definition of macro '__pa'
    #define __pa(x)   ((unsigned long)(x) - PAGE_OFFSET)
                                       ^
>> drivers/media/platform/omap/omap_vout.c:209:12: note: in expansion of macro 'virt_to_phys'
      *physp = virt_to_phys((void *)virtp);
               ^~~~~~~~~~~~

vim +/virt_to_phys +209 drivers/media/platform/omap/omap_vout.c

5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  @33  #include <linux/module.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   34  #include <linux/vmalloc.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   35  #include <linux/sched.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   36  #include <linux/types.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   37  #include <linux/platform_device.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   38  #include <linux/irq.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   39  #include <linux/videodev2.h>
72915e85 drivers/media/video/omap/omap_vout.c    Amber Jain       2011-07-07   40  #include <linux/dma-mapping.h>
d1ee8878 drivers/media/video/omap/omap_vout.c    Gary Thomas      2011-12-01   41  #include <linux/slab.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   42  
dd880dd4 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-05-27   43  #include <media/videobuf-dma-contig.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   44  #include <media/v4l2-device.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   45  #include <media/v4l2-ioctl.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   46  
6a1c9f6d drivers/media/platform/omap/omap_vout.c Tomi Valkeinen   2012-10-08   47  #include <video/omapvrfb.h>
781a1622 drivers/media/platform/omap/omap_vout.c Peter Ujfalusi   2016-05-27   48  #include <video/omapfb_dss.h>
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   49  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   50  #include "omap_voutlib.h"
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   51  #include "omap_voutdef.h"
445e258f drivers/media/video/omap/omap_vout.c    Archit Taneja    2011-06-14   52  #include "omap_vout_vrfb.h"
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   53  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   54  MODULE_AUTHOR("Texas Instruments");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   55  MODULE_DESCRIPTION("OMAP Video for Linux Video out driver");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   56  MODULE_LICENSE("GPL");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   57  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   58  /* Driver Configuration macros */
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   59  #define VOUT_NAME		"omap_vout"
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   60  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   61  enum omap_vout_channels {
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   62  	OMAP_VIDEO1,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   63  	OMAP_VIDEO2,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   64  };
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   65  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   66  static struct videobuf_queue_ops video_vbq_ops;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   67  /* Variables configurable through module params*/
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   68  static u32 video1_numbuffers = 3;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   69  static u32 video2_numbuffers = 3;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   70  static u32 video1_bufsize = OMAP_VOUT_MAX_BUF_SIZE;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   71  static u32 video2_bufsize = OMAP_VOUT_MAX_BUF_SIZE;
90ab5ee9 drivers/media/video/omap/omap_vout.c    Rusty Russell    2012-01-13   72  static bool vid1_static_vrfb_alloc;
90ab5ee9 drivers/media/video/omap/omap_vout.c    Rusty Russell    2012-01-13   73  static bool vid2_static_vrfb_alloc;
90ab5ee9 drivers/media/video/omap/omap_vout.c    Rusty Russell    2012-01-13   74  static bool debug;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   75  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   76  /* Module parameters */
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   77  module_param(video1_numbuffers, uint, S_IRUGO);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   78  MODULE_PARM_DESC(video1_numbuffers,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   79  	"Number of buffers to be allocated at init time for Video1 device.");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   80  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   81  module_param(video2_numbuffers, uint, S_IRUGO);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   82  MODULE_PARM_DESC(video2_numbuffers,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   83  	"Number of buffers to be allocated at init time for Video2 device.");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   84  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   85  module_param(video1_bufsize, uint, S_IRUGO);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   86  MODULE_PARM_DESC(video1_bufsize,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   87  	"Size of the buffer to be allocated for video1 device");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   88  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   89  module_param(video2_bufsize, uint, S_IRUGO);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   90  MODULE_PARM_DESC(video2_bufsize,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   91  	"Size of the buffer to be allocated for video2 device");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   92  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   93  module_param(vid1_static_vrfb_alloc, bool, S_IRUGO);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   94  MODULE_PARM_DESC(vid1_static_vrfb_alloc,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   95  	"Static allocation of the VRFB buffer for video1 device");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   96  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   97  module_param(vid2_static_vrfb_alloc, bool, S_IRUGO);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   98  MODULE_PARM_DESC(vid2_static_vrfb_alloc,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11   99  	"Static allocation of the VRFB buffer for video2 device");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  100  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  101  module_param(debug, bool, S_IRUGO);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  102  MODULE_PARM_DESC(debug, "Debug level (0-1)");
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  103  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  104  /* list of image formats supported by OMAP2 video pipelines */
0d334f7f drivers/media/video/omap/omap_vout.c    Jesper Juhl      2011-07-09  105  static const struct v4l2_fmtdesc omap_formats[] = {
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  106  	{
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  107  		/* Note:  V4L2 defines RGB565 as:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  108  		 *
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  109  		 *      Byte 0                    Byte 1
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  110  		 *      g2 g1 g0 r4 r3 r2 r1 r0   b4 b3 b2 b1 b0 g5 g4 g3
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  111  		 *
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  112  		 * We interpret RGB565 as:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  113  		 *
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  114  		 *      Byte 0                    Byte 1
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  115  		 *      g2 g1 g0 b4 b3 b2 b1 b0   r4 r3 r2 r1 r0 g5 g4 g3
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  116  		 */
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  117  		.description = "RGB565, le",
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  118  		.pixelformat = V4L2_PIX_FMT_RGB565,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  119  	},
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  120  	{
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  121  		/* Note:  V4L2 defines RGB32 as: RGB-8-8-8-8  we use
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  122  		 *  this for RGB24 unpack mode, the last 8 bits are ignored
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  123  		 * */
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  124  		.description = "RGB32, le",
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  125  		.pixelformat = V4L2_PIX_FMT_RGB32,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  126  	},
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  127  	{
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  128  		/* Note:  V4L2 defines RGB24 as: RGB-8-8-8  we use
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  129  		 *        this for RGB24 packed mode
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  130  		 *
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  131  		 */
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  132  		.description = "RGB24, le",
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  133  		.pixelformat = V4L2_PIX_FMT_RGB24,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  134  	},
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  135  	{
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  136  		.description = "YUYV (YUV 4:2:2), packed",
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  137  		.pixelformat = V4L2_PIX_FMT_YUYV,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  138  	},
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  139  	{
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  140  		.description = "UYVY, packed",
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  141  		.pixelformat = V4L2_PIX_FMT_UYVY,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  142  	},
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  143  };
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  144  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  145  #define NUM_OUTPUT_FORMATS (ARRAY_SIZE(omap_formats))
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  146  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  147  /*
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  148   * Try format
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  149   */
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  150  static int omap_vout_try_format(struct v4l2_pix_format *pix)
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  151  {
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  152  	int ifmt, bpp = 0;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  153  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  154  	pix->height = clamp(pix->height, (u32)VID_MIN_HEIGHT,
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  155  						(u32)VID_MAX_HEIGHT);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  156  	pix->width = clamp(pix->width, (u32)VID_MIN_WIDTH, (u32)VID_MAX_WIDTH);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  157  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  158  	for (ifmt = 0; ifmt < NUM_OUTPUT_FORMATS; ifmt++) {
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  159  		if (pix->pixelformat == omap_formats[ifmt].pixelformat)
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  160  			break;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  161  	}
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  162  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  163  	if (ifmt == NUM_OUTPUT_FORMATS)
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  164  		ifmt = 0;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  165  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  166  	pix->pixelformat = omap_formats[ifmt].pixelformat;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  167  	pix->field = V4L2_FIELD_ANY;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  168  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  169  	switch (pix->pixelformat) {
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  170  	case V4L2_PIX_FMT_YUYV:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  171  	case V4L2_PIX_FMT_UYVY:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  172  	default:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  173  		pix->colorspace = V4L2_COLORSPACE_JPEG;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  174  		bpp = YUYV_BPP;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  175  		break;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  176  	case V4L2_PIX_FMT_RGB565:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  177  	case V4L2_PIX_FMT_RGB565X:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  178  		pix->colorspace = V4L2_COLORSPACE_SRGB;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  179  		bpp = RGB565_BPP;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  180  		break;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  181  	case V4L2_PIX_FMT_RGB24:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  182  		pix->colorspace = V4L2_COLORSPACE_SRGB;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  183  		bpp = RGB24_BPP;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  184  		break;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  185  	case V4L2_PIX_FMT_RGB32:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  186  	case V4L2_PIX_FMT_BGR32:
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  187  		pix->colorspace = V4L2_COLORSPACE_SRGB;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  188  		bpp = RGB32_BPP;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  189  		break;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  190  	}
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  191  	pix->bytesperline = pix->width * bpp;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  192  	pix->sizeimage = pix->bytesperline * pix->height;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  193  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  194  	return bpp;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  195  }
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  196  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  197  /*
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  198   * omap_vout_get_userptr: Convert user space virtual address to physical
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  199   * address.
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  200   */
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  201  static int omap_vout_get_userptr(struct videobuf_buffer *vb, u32 virtp,
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  202  				 u32 *physp)
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  203  {
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  204  	struct frame_vector *vec;
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  205  	int ret;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  206  
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  207  	/* For kernel direct-mapped memory, take the easy way */
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  208  	if (virtp >= PAGE_OFFSET) {
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13 @209  		*physp = virt_to_phys((void *)virtp);
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  210  		return 0;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  211  	}
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  212  
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  213  	vec = frame_vector_create(1);
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  214  	if (!vec)
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  215  		return -ENOMEM;
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  216  
7f23b350 drivers/media/platform/omap/omap_vout.c Lorenzo Stoakes  2016-10-13  217  	ret = get_vaddr_frames(virtp, 1, FOLL_WRITE, vec);
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  218  	if (ret != 1) {
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  219  		frame_vector_destroy(vec);
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  220  		return -EINVAL;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  221  	}
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  222  	*physp = __pfn_to_phys(frame_vector_pfns(vec)[0]);
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  223  	vb->priv = vec;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  224  
8a677b6e drivers/media/platform/omap/omap_vout.c Jan Kara         2015-07-13  225  	return 0;
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  226  }
5c7ab634 drivers/media/video/omap/omap_vout.c    Vaibhav Hiremath 2010-04-11  227  

:::::: The code at line 209 was first introduced by commit
:::::: 8a677b6eddfc3127ea36a710838ecd20502b1cb9 [media] media: omap_vout: Convert omap_vout_uservirt_to_phys() to use get_vaddr_pfns()

:::::: TO: Jan Kara <jack@suse.cz>
:::::: CC: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 53233 bytes --]

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 02/19] media: omap3isp: allow it to build with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 02/19] media: omap3isp: allow it to build " Mauro Carvalho Chehab
@ 2018-04-06 12:56   ` kbuild test robot
  2018-04-07 13:31   ` Laurent Pinchart
  1 sibling, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 12:56 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Laurent Pinchart, Hans Verkuil,
	Arnd Bergmann, Stanimir Varbanov, Benjamin Gaignard,
	Philipp Zabel, Ramesh Shanmugasundaram

[-- Attachment #1: Type: text/plain, Size: 13408 bytes --]

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
config: x86_64-allmodconfig (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All warnings (new ones prefixed by >>):

   drivers/media//platform/omap3isp/ispccdc.c: In function 'ccdc_config':
>> drivers/media//platform/omap3isp/ispccdc.c:738:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
            (__force void __user *)fpc.fpcaddr,
            ^

sparse warnings: (new ones prefixed by >>)

>> drivers/media/platform/omap3isp/isppreview.c:893:45: sparse: incorrect type in initializer (different address spaces) @@    expected void [noderef] <asn:1>*from @@    got void [noderef] <asn:1>*from @@
   drivers/media/platform/omap3isp/isppreview.c:893:45:    expected void [noderef] <asn:1>*from
   drivers/media/platform/omap3isp/isppreview.c:893:45:    got void *[noderef] <asn:1><noident>
>> drivers/media/platform/omap3isp/isppreview.c:893:47: sparse: dereference of noderef expression

vim +738 drivers/media//platform/omap3isp/ispccdc.c

de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  656  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  657  /*
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  658   * ccdc_config - Set CCDC configuration from userspace
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  659   * @ccdc: Pointer to ISP CCDC device.
872aba51 drivers/media/platform/omap3isp/ispccdc.c Lad, Prabhakar   2014-02-21  660   * @ccdc_struct: Structure containing CCDC configuration sent from userspace.
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  661   *
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  662   * Returns 0 if successful, -EINVAL if the pointer to the configuration
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  663   * structure is null, or the copy_from_user function fails to copy user space
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  664   * memory to kernel space memory.
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  665   */
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  666  static int ccdc_config(struct isp_ccdc_device *ccdc,
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  667  		       struct omap3isp_ccdc_update_config *ccdc_struct)
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  668  {
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  669  	struct isp_device *isp = to_isp_device(ccdc);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  670  	unsigned long flags;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  671  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  672  	spin_lock_irqsave(&ccdc->lock, flags);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  673  	ccdc->shadow_update = 1;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  674  	spin_unlock_irqrestore(&ccdc->lock, flags);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  675  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  676  	if (OMAP3ISP_CCDC_ALAW & ccdc_struct->update) {
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  677  		ccdc->alaw = !!(OMAP3ISP_CCDC_ALAW & ccdc_struct->flag);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  678  		ccdc->update |= OMAP3ISP_CCDC_ALAW;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  679  	}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  680  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  681  	if (OMAP3ISP_CCDC_LPF & ccdc_struct->update) {
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  682  		ccdc->lpf = !!(OMAP3ISP_CCDC_LPF & ccdc_struct->flag);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  683  		ccdc->update |= OMAP3ISP_CCDC_LPF;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  684  	}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  685  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  686  	if (OMAP3ISP_CCDC_BLCLAMP & ccdc_struct->update) {
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  687  		if (copy_from_user(&ccdc->clamp, ccdc_struct->bclamp,
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  688  				   sizeof(ccdc->clamp))) {
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  689  			ccdc->shadow_update = 0;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  690  			return -EFAULT;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  691  		}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  692  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  693  		ccdc->obclamp = !!(OMAP3ISP_CCDC_BLCLAMP & ccdc_struct->flag);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  694  		ccdc->update |= OMAP3ISP_CCDC_BLCLAMP;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  695  	}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  696  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  697  	if (OMAP3ISP_CCDC_BCOMP & ccdc_struct->update) {
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  698  		if (copy_from_user(&ccdc->blcomp, ccdc_struct->blcomp,
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  699  				   sizeof(ccdc->blcomp))) {
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  700  			ccdc->shadow_update = 0;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  701  			return -EFAULT;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  702  		}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  703  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  704  		ccdc->update |= OMAP3ISP_CCDC_BCOMP;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  705  	}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  706  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  707  	ccdc->shadow_update = 0;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  708  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  709  	if (OMAP3ISP_CCDC_FPC & ccdc_struct->update) {
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  710  		struct omap3isp_ccdc_fpc fpc;
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  711  		struct ispccdc_fpc fpc_old = { .addr = NULL, };
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  712  		struct ispccdc_fpc fpc_new;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  713  		u32 size;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  714  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  715  		if (ccdc->state != ISP_PIPELINE_STREAM_STOPPED)
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  716  			return -EBUSY;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  717  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  718  		ccdc->fpc_en = !!(OMAP3ISP_CCDC_FPC & ccdc_struct->flag);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  719  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  720  		if (ccdc->fpc_en) {
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  721  			if (copy_from_user(&fpc, ccdc_struct->fpc, sizeof(fpc)))
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  722  				return -EFAULT;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  723  
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  724  			size = fpc.fpnum * 4;
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  725  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  726  			/*
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  727  			 * The table address must be 64-bytes aligned, which is
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  728  			 * guaranteed by dma_alloc_coherent().
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  729  			 */
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  730  			fpc_new.fpnum = fpc.fpnum;
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  731  			fpc_new.addr = dma_alloc_coherent(isp->dev, size,
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  732  							  &fpc_new.dma,
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  733  							  GFP_KERNEL);
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  734  			if (fpc_new.addr == NULL)
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  735  				return -ENOMEM;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  736  
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  737  			if (copy_from_user(fpc_new.addr,
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02 @738  					   (__force void __user *)fpc.fpcaddr,
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  739  					   size)) {
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  740  				dma_free_coherent(isp->dev, size, fpc_new.addr,
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  741  						  fpc_new.dma);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  742  				return -EFAULT;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  743  			}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  744  
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  745  			fpc_old = ccdc->fpc;
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  746  			ccdc->fpc = fpc_new;
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  747  		}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  748  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  749  		ccdc_configure_fpc(ccdc);
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  750  
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  751  		if (fpc_old.addr != NULL)
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  752  			dma_free_coherent(isp->dev, fpc_old.fpnum * 4,
c60e153d drivers/media/platform/omap3isp/ispccdc.c Laurent Pinchart 2014-01-02  753  					  fpc_old.addr, fpc_old.dma);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  754  	}
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  755  
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  756  	return ccdc_lsc_config(ccdc, ccdc_struct);
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  757  }
de1135d4 drivers/media/video/omap3isp/ispccdc.c    Laurent Pinchart 2011-02-12  758  

:::::: The code at line 738 was first introduced by commit
:::::: c60e153d3407b5a94b72ebfcf274fae98979eed9 [media] omap3isp: ccdc: Use the DMA API for FPC

:::::: TO: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
:::::: CC: Mauro Carvalho Chehab <m.chehab@samsung.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 62631 bytes --]

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 05/19] media: fsl-viu: allow building it with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 05/19] media: fsl-viu: allow building it with COMPILE_TEST Mauro Carvalho Chehab
  2018-04-06 10:43   ` kbuild test robot
@ 2018-04-06 14:03   ` kbuild test robot
  1 sibling, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 14:03 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Hans Verkuil, Arnd Bergmann,
	Stanimir Varbanov, Benjamin Gaignard, Philipp Zabel,
	Ramesh Shanmugasundaram, Al Viro, Bhumika Goyal, Geliang Tang,
	Kees Cook

[-- Attachment #1: Type: text/plain, Size: 37612 bytes --]

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
config: x86_64-allmodconfig (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All warnings (new ones prefixed by >>):

   drivers/media/platform/fsl-viu.c:1081:25: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1081:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1081:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1082:25: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1082:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1082:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1083:25: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1083:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1083:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1095:17: sparse: incorrect type in argument 1 (different address spaces)
   drivers/media/platform/fsl-viu.c:1095:17:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1095:17:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:446:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:446:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:446:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:447:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:447:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:447:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:448:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:448:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:448:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:446:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:446:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:446:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:447:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:447:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:447:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:448:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:448:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:448:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1000:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1000:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1000:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1001:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1001:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1001:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1002:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1002:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1002:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1003:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1003:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1003:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1004:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1004:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1004:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1005:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1005:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1005:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1006:9: sparse: incorrect type in argument 1 (different address spaces)
   drivers/media/platform/fsl-viu.c:1006:9:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1006:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1006:9: sparse: incorrect type in argument 1 (different address spaces)
   drivers/media/platform/fsl-viu.c:1006:9:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1006:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1231:22: sparse: incorrect type in argument 1 (different address spaces)
   drivers/media/platform/fsl-viu.c:1231:22:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1231:22:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1232:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1232:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1232:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1237:22: sparse: incorrect type in argument 1 (different address spaces)
   drivers/media/platform/fsl-viu.c:1237:22:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1237:22:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1238:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1238:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1238:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1318:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1318:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1318:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1319:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1319:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1319:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1320:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1320:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1320:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1321:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1321:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1321:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1322:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1322:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1322:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1323:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1323:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1323:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1324:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1324:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1324:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1325:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1325:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1325:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1326:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1326:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1326:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1327:9: sparse: incorrect type in argument 2 (different address spaces)
   drivers/media/platform/fsl-viu.c:1327:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1327:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1447:21: sparse: incorrect type in assignment (different address spaces)
   drivers/media/platform/fsl-viu.c:1447:21:    expected struct viu_reg *vr
   drivers/media/platform/fsl-viu.c:1447:21:    got struct viu_reg [noderef] <asn:2>*[assigned] viu_regs
   drivers/media/platform/fsl-viu.c: In function 'viu_setup_preview':
>> drivers/media/platform/fsl-viu.c:760:28: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
     reg_val.field_base_addr = (u32)dev->ovbuf.base;
                               ^

sparse warnings: (new ones prefixed by >>)

>> drivers/media/platform/fsl-viu.c:1119:18: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1119:18:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1119:18:    got unsigned int *<noident>
>> drivers/media/platform/fsl-viu.c:1128:17: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1128:17:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1128:17:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1158:18: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1158:18:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1158:18:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1159:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1159:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1159:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:260:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:260:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:260:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:261:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:261:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:261:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:270:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:270:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:270:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:273:22: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:273:22:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:273:22:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:275:17: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:275:17:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:275:17:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:279:38: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:279:38:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:279:38:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:286:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:286:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:286:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:287:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:287:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:287:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:290:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:290:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:290:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:446:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:446:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:446:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:447:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:447:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:447:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:448:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:448:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:448:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:718:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:718:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:718:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:719:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:719:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:719:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:720:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:720:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:720:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1025:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1025:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1025:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1026:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1026:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1026:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1027:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1027:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1027:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1032:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1032:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1032:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:446:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:446:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:446:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:447:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:447:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:447:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:448:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:448:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:448:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:446:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:446:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:446:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:447:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:447:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:447:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:448:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:448:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:448:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1081:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1081:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1081:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1082:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1082:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1082:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1083:25: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1083:25:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1083:25:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1095:17: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1095:17:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1095:17:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:446:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:446:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:446:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:447:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:447:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:447:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:448:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:448:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:448:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:446:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:446:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:446:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:447:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:447:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:447:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:448:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:448:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:448:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1000:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1000:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1000:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1001:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1001:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1001:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1002:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1002:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1002:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1003:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1003:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1003:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1004:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1004:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1004:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1005:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1005:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1005:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1006:9: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1006:9:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1006:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1006:9: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1006:9:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1006:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1231:22: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1231:22:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1231:22:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1232:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1232:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1232:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1237:22: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1237:22:    expected void const volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1237:22:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1238:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1238:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1238:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1318:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1318:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1318:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1319:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1319:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1319:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1320:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1320:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1320:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1321:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1321:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1321:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1322:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1322:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1322:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1323:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1323:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1323:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1324:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1324:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1324:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1325:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1325:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1325:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1326:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1326:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1326:9:    got unsigned int *<noident>
   drivers/media/platform/fsl-viu.c:1327:9: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got eref] <asn:2>*addr @@
   drivers/media/platform/fsl-viu.c:1327:9:    expected void volatile [noderef] <asn:2>*addr
   drivers/media/platform/fsl-viu.c:1327:9:    got unsigned int *<noident>
>> drivers/media/platform/fsl-viu.c:1447:21: sparse: incorrect type in assignment (different address spaces) @@    expected struct viu_reg *vr @@    got struct viu_reg [noderef] <asstruct viu_reg *vr @@
   drivers/media/platform/fsl-viu.c:1447:21:    expected struct viu_reg *vr
   drivers/media/platform/fsl-viu.c:1447:21:    got struct viu_reg [noderef] <asn:2>*[assigned] viu_regs
   drivers/media/platform/fsl-viu.c: In function 'viu_setup_preview':
   drivers/media/platform/fsl-viu.c:760:28: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
     reg_val.field_base_addr = (u32)dev->ovbuf.base;
                               ^

vim +760 drivers/media/platform/fsl-viu.c

95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  722  
791ae699 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2011-05-04  723  static int viu_setup_preview(struct viu_dev *dev, struct viu_fh *fh)
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  724  {
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  725  	int bpp;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  726  
0a6b9b04 drivers/media/platform/fsl-viu.c Hans Verkuil       2015-07-20  727  	dprintk(1, "%s %dx%d\n", __func__,
0a6b9b04 drivers/media/platform/fsl-viu.c Hans Verkuil       2015-07-20  728  		fh->win.w.width, fh->win.w.height);
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  729  
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  730  	reg_val.status_cfg = 0;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  731  
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  732  	/* setup window */
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  733  	reg_val.picture_count = (fh->win.w.height / 2) << 16 |
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  734  				fh->win.w.width;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  735  
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  736  	/* setup color depth and dma increment */
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  737  	bpp = dev->ovfmt->depth / 8;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  738  	switch (bpp) {
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  739  	case 2:
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  740  		reg_val.status_cfg &= ~MODE_32BIT;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  741  		reg_val.dma_inc = fh->win.w.width * 2;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  742  		break;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  743  	case 4:
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  744  		reg_val.status_cfg |= MODE_32BIT;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  745  		reg_val.dma_inc = fh->win.w.width * 4;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  746  		break;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  747  	default:
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  748  		dprintk(0, "device doesn't support color depth(%d)\n",
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  749  			bpp * 8);
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  750  		return -EINVAL;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  751  	}
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  752  
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  753  	dev->ovfield = fh->win.field;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  754  	if (!V4L2_FIELD_HAS_BOTH(dev->ovfield))
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  755  		reg_val.dma_inc = 0;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  756  
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  757  	reg_val.status_cfg |= DMA_ACT | INT_DMA_END_EN | INT_FIELD_EN;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  758  
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  759  	/* setup the base address of the overlay buffer */
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02 @760  	reg_val.field_base_addr = (u32)dev->ovbuf.base;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  761  
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  762  	return 0;
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  763  }
95c5d605 drivers/media/video/fsl-viu.c    Anatolij Gustschin 2010-07-02  764  

:::::: The code at line 760 was first introduced by commit
:::::: 95c5d605ca6fd6ab5ab0f6d097ff97d5aa2f9235 V4L/DVB: v4l: Add MPC5121e VIU video capture driver

:::::: TO: Anatolij Gustschin <agust@denx.de>
:::::: CC: Mauro Carvalho Chehab <mchehab@redhat.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 62633 bytes --]

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 09/19] media: marvel-ccic: re-enable mmp-driver build
  2018-04-05 20:29 ` [PATCH v2 09/19] media: marvel-ccic: re-enable mmp-driver build Mauro Carvalho Chehab
@ 2018-04-06 14:52   ` kbuild test robot
  0 siblings, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 14:52 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Jonathan Corbet

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
reproduce:
        # apt-get install sparse
        make ARCH=x86_64 allmodconfig
        make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

>> drivers/media/platform/marvell-ccic/mmp-driver.c:135:41: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:135:41:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:135:41:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:136:44: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:136:44:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:136:44:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:174:38: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:174:38:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:174:38:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:175:38: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:175:38:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:175:38:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:195:48: sparse: incorrect type in argument 1 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:195:48:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:195:48:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:196:55: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:196:55:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:196:55:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:197:54: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:197:54:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:197:54:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:202:48: sparse: incorrect type in argument 1 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:202:48:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:202:48:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:203:55: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:203:55:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:203:55:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:204:54: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:2>*<noident> @@    got sn:2>*<noident> @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:204:54:    expected void [noderef] <asn:2>*<noident>
   drivers/media/platform/marvell-ccic/mmp-driver.c:204:54:    got void *
   drivers/media/platform/marvell-ccic/mmp-driver.c:186:6: sparse: symbol 'mcam_ctlr_reset' was not declared. Should it be static?
   drivers/media/platform/marvell-ccic/mmp-driver.c:217:6: sparse: symbol 'mmpcam_calc_dphy' was not declared. Should it be static?
>> drivers/media/platform/marvell-ccic/mmp-driver.c:389:25: sparse: incorrect type in assignment (different address spaces) @@    expected void *power_regs @@    got void [noderef] <avoid *power_regs @@
   drivers/media/platform/marvell-ccic/mmp-driver.c:389:25:    expected void *power_regs
   drivers/media/platform/marvell-ccic/mmp-driver.c:389:25:    got void [noderef] <asn:2>*

vim +135 drivers/media/platform/marvell-ccic/mmp-driver.c

0e394f44f drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  129  
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  130  /*
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  131   * Power control.
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  132   */
4a0abfaa9 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2012-03-16  133  static void mmpcam_power_up_ctlr(struct mmp_camera *cam)
4a0abfaa9 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2012-03-16  134  {
4a0abfaa9 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2012-03-16 @135  	iowrite32(0x3f, cam->power_regs + REG_CCIC_DCGCR);
4a0abfaa9 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2012-03-16  136  	iowrite32(0x3805b, cam->power_regs + REG_CCIC_CRCR);
4a0abfaa9 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2012-03-16  137  	mdelay(1);
4a0abfaa9 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2012-03-16  138  }
4a0abfaa9 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2012-03-16  139  
05fed8162 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  140  static int mmpcam_power_up(struct mcam_camera *mcam)
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  141  {
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  142  	struct mmp_camera *cam = mcam_to_cam(mcam);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  143  	struct mmp_camera_platform_data *pdata;
05fed8162 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  144  
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  145  /*
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  146   * Turn on power and clocks to the controller.
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  147   */
4a0abfaa9 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2012-03-16  148  	mmpcam_power_up_ctlr(cam);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  149  /*
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  150   * Provide power to the sensor.
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  151   */
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  152  	mcam_reg_write(mcam, REG_CLKCTRL, 0x60000002);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  153  	pdata = cam->pdev->dev.platform_data;
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  154  	gpio_set_value(pdata->sensor_power_gpio, 1);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  155  	mdelay(5);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  156  	mcam_reg_clear_bit(mcam, REG_CTRL1, 0x10000000);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  157  	gpio_set_value(pdata->sensor_reset_gpio, 0); /* reset is active low */
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  158  	mdelay(5);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  159  	gpio_set_value(pdata->sensor_reset_gpio, 1); /* reset is active low */
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  160  	mdelay(5);
0e394f44f drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  161  
0e394f44f drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  162  	mcam_clk_enable(mcam);
0e394f44f drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  163  
05fed8162 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  164  	return 0;
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  165  }
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  166  
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  167  static void mmpcam_power_down(struct mcam_camera *mcam)
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  168  {
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  169  	struct mmp_camera *cam = mcam_to_cam(mcam);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  170  	struct mmp_camera_platform_data *pdata;
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  171  /*
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  172   * Turn off clocks and set reset lines
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  173   */
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  174  	iowrite32(0, cam->power_regs + REG_CCIC_DCGCR);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  175  	iowrite32(0, cam->power_regs + REG_CCIC_CRCR);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  176  /*
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  177   * Shut down the sensor.
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  178   */
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  179  	pdata = cam->pdev->dev.platform_data;
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  180  	gpio_set_value(pdata->sensor_power_gpio, 0);
67a8dbbc4 drivers/media/video/marvell-ccic/mmp-driver.c    Jonathan Corbet 2011-06-11  181  	gpio_set_value(pdata->sensor_reset_gpio, 0);
05fed8162 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  182  
0e394f44f drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  183  	mcam_clk_disable(mcam);
05fed8162 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  184  }
05fed8162 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  185  
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  186  void mcam_ctlr_reset(struct mcam_camera *mcam)
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  187  {
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  188  	unsigned long val;
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  189  	struct mmp_camera *cam = mcam_to_cam(mcam);
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  190  
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  191  	if (mcam->ccic_id) {
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  192  		/*
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  193  		 * Using CCIC2
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  194  		 */
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  195  		val = ioread32(cam->power_regs + REG_CCIC2_CRCR);
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  196  		iowrite32(val & ~0x2, cam->power_regs + REG_CCIC2_CRCR);
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  197  		iowrite32(val | 0x2, cam->power_regs + REG_CCIC2_CRCR);
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  198  	} else {
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  199  		/*
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  200  		 * Using CCIC1
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  201  		 */
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03 @202  		val = ioread32(cam->power_regs + REG_CCIC_CRCR);
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  203  		iowrite32(val & ~0x2, cam->power_regs + REG_CCIC_CRCR);
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  204  		iowrite32(val | 0x2, cam->power_regs + REG_CCIC_CRCR);
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  205  	}
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  206  }
7c269f454 drivers/media/platform/marvell-ccic/mmp-driver.c Libin Yang      2013-07-03  207  

:::::: The code at line 135 was first introduced by commit
:::::: 4a0abfaa9662365303df2accf16383a2edb49a7b [media] mmp-camera: Don't power up the sensor on resume

:::::: TO: Jonathan Corbet <corbet@lwn.net>
:::::: CC: Mauro Carvalho Chehab <mchehab@redhat.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 11/19] media: davinci: allow building isif code
  2018-04-05 20:29 ` [PATCH v2 11/19] media: davinci: allow building isif code Mauro Carvalho Chehab
@ 2018-04-06 16:17   ` kbuild test robot
  0 siblings, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 16:17 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Lad, Prabhakar

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
reproduce:
        # apt-get install sparse
        make ARCH=x86_64 allmodconfig
        make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

>> drivers/media/platform/davinci/isif.c:1066:22: sparse: incorrect type in assignment (different address spaces) @@    expected void *[noderef] <asn:2>addr @@    got void *[noderef] <asn:2>addr @@
   drivers/media/platform/davinci/isif.c:1066:22:    expected void *[noderef] <asn:2>addr
   drivers/media/platform/davinci/isif.c:1066:22:    got void [noderef] <asn:2>*
>> drivers/media/platform/davinci/isif.c:1074:44: sparse: incorrect type in assignment (different address spaces) @@    expected void [noderef] <asn:2>*static [toplevel] [assigned] base_addr @@    got  [toplevel] [assigned] base_addr @@
   drivers/media/platform/davinci/isif.c:1074:44:    expected void [noderef] <asn:2>*static [toplevel] [assigned] base_addr
   drivers/media/platform/davinci/isif.c:1074:44:    got void *[noderef] <asn:2>addr
>> drivers/media/platform/davinci/isif.c:1078:51: sparse: incorrect type in assignment (different address spaces) @@    expected void [noderef] <asn:2>*static [toplevel] [assigned] linear_tbl0_addr @@    got  [toplevel] [assigned] linear_tbl0_addr @@
   drivers/media/platform/davinci/isif.c:1078:51:    expected void [noderef] <asn:2>*static [toplevel] [assigned] linear_tbl0_addr
   drivers/media/platform/davinci/isif.c:1078:51:    got void *[noderef] <asn:2>addr
>> drivers/media/platform/davinci/isif.c:1082:51: sparse: incorrect type in assignment (different address spaces) @@    expected void [noderef] <asn:2>*static [toplevel] [assigned] linear_tbl1_addr @@    got  [toplevel] [assigned] linear_tbl1_addr @@
   drivers/media/platform/davinci/isif.c:1082:51:    expected void [noderef] <asn:2>*static [toplevel] [assigned] linear_tbl1_addr
   drivers/media/platform/davinci/isif.c:1082:51:    got void *[noderef] <asn:2>addr
>> drivers/media/platform/davinci/isif.c:1067:22: sparse: dereference of noderef expression

vim +1066 drivers/media/platform/davinci/isif.c

63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1025  
4c62e976 drivers/media/platform/davinci/isif.c Greg Kroah-Hartman 2012-12-21  1026  static int isif_probe(struct platform_device *pdev)
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1027  {
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1028  	void (*setup_pinmux)(void);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1029  	struct resource	*res;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1030  	void *__iomem addr;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1031  	int status = 0, i;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1032  
9a3e89b1 drivers/media/platform/davinci/isif.c Lad, Prabhakar     2013-03-22  1033  	/* Platform data holds setup_pinmux function ptr */
9a3e89b1 drivers/media/platform/davinci/isif.c Lad, Prabhakar     2013-03-22  1034  	if (!pdev->dev.platform_data)
9a3e89b1 drivers/media/platform/davinci/isif.c Lad, Prabhakar     2013-03-22  1035  		return -ENODEV;
9a3e89b1 drivers/media/platform/davinci/isif.c Lad, Prabhakar     2013-03-22  1036  
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1037  	/*
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1038  	 * first try to register with vpfe. If not correct platform, then we
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1039  	 * don't have to iomap
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1040  	 */
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1041  	status = vpfe_register_ccdc_device(&isif_hw_dev);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1042  	if (status < 0)
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1043  		return status;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1044  
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1045  	setup_pinmux = pdev->dev.platform_data;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1046  	/*
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1047  	 * setup Mux configuration for ccdc which may be different for
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1048  	 * different SoCs using this CCDC
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1049  	 */
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1050  	setup_pinmux();
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1051  
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1052  	i = 0;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1053  	/* Get the ISIF base address, linearization table0 and table1 addr. */
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1054  	while (i < 3) {
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1055  		res = platform_get_resource(pdev, IORESOURCE_MEM, i);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1056  		if (!res) {
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1057  			status = -ENODEV;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1058  			goto fail_nobase_res;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1059  		}
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1060  		res = request_mem_region(res->start, resource_size(res),
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1061  					 res->name);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1062  		if (!res) {
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1063  			status = -EBUSY;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1064  			goto fail_nobase_res;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1065  		}
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21 @1066  		addr = ioremap_nocache(res->start, resource_size(res));
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21 @1067  		if (!addr) {
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1068  			status = -ENOMEM;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1069  			goto fail_base_iomap;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1070  		}
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1071  		switch (i) {
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1072  		case 0:
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1073  			/* ISIF base address */
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21 @1074  			isif_cfg.base_addr = addr;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1075  			break;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1076  		case 1:
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1077  			/* ISIF linear tbl0 address */
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21 @1078  			isif_cfg.linear_tbl0_addr = addr;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1079  			break;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1080  		default:
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1081  			/* ISIF linear tbl0 address */
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21 @1082  			isif_cfg.linear_tbl1_addr = addr;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1083  			break;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1084  		}
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1085  		i++;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1086  	}
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1087  	isif_cfg.dev = &pdev->dev;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1088  
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1089  	printk(KERN_NOTICE "%s is registered with vpfe.\n",
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1090  		isif_hw_dev.name);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1091  	return 0;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1092  fail_base_iomap:
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1093  	release_mem_region(res->start, resource_size(res));
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1094  	i--;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1095  fail_nobase_res:
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1096  	if (isif_cfg.base_addr)
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1097  		iounmap(isif_cfg.base_addr);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1098  	if (isif_cfg.linear_tbl0_addr)
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1099  		iounmap(isif_cfg.linear_tbl0_addr);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1100  
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1101  	while (i >= 0) {
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1102  		res = platform_get_resource(pdev, IORESOURCE_MEM, i);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1103  		release_mem_region(res->start, resource_size(res));
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1104  		i--;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1105  	}
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1106  	vpfe_unregister_ccdc_device(&isif_hw_dev);
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1107  	return status;
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1108  }
63e3ab14 drivers/media/video/davinci/isif.c    Murali Karicheri   2010-02-21  1109  

:::::: The code at line 1066 was first introduced by commit
:::::: 63e3ab142fa3f46c290891655681c6a6304bd2b3 V4L/DVB: V4L - vpfe capture - source for ISIF driver on DM365

:::::: TO: Murali Karicheri <mkaricheri@gmail.com>
:::::: CC: Mauro Carvalho Chehab <mchehab@redhat.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time
  2018-04-05 20:29 ` [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time Mauro Carvalho Chehab
@ 2018-04-06 16:21   ` kbuild test robot
  2018-04-06 16:46     ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 16:21 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Hans Verkuil, Douglas Fischer

[-- Attachment #1: Type: text/plain, Size: 1861 bytes --]

Hi Mauro,

I love your patch! Yet something to improve:

[auto build test ERROR on linuxtv-media/master]
[also build test ERROR on next-20180406]
[cannot apply to v4.16]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
config: x86_64-federa-25 (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All errors (new ones prefixed by >>):

   WARNING: modpost: missing MODULE_LICENSE() in drivers/media/radio/si470x/radio-si470x-common.o
   see include/linux/module.h for more information
>> ERROR: "si470x_set_freq" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
>> ERROR: "si470x_viddev_template" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
>> ERROR: "si470x_ctrl_ops" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
>> ERROR: "si470x_stop" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
>> ERROR: "si470x_start" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
>> ERROR: "si470x_set_freq" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!
>> ERROR: "si470x_viddev_template" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!
>> ERROR: "si470x_ctrl_ops" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!
>> ERROR: "si470x_start" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!
>> ERROR: "si470x_stop" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 47441 bytes --]

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time
  2018-04-06 16:21   ` kbuild test robot
@ 2018-04-06 16:46     ` Mauro Carvalho Chehab
  2018-04-18 17:07       ` Daniel Scheller
  0 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-06 16:46 UTC (permalink / raw)
  To: kbuild test robot
  Cc: kbuild-all, Linux Media Mailing List, Mauro Carvalho Chehab,
	Hans Verkuil, Douglas Fischer

Em Sat, 7 Apr 2018 00:21:07 +0800
kbuild test robot <lkp@intel.com> escreveu:

> Hi Mauro,
> 
> I love your patch! Yet something to improve:
> 
> [auto build test ERROR on linuxtv-media/master]
> [also build test ERROR on next-20180406]
> [cannot apply to v4.16]
> [if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
> 
> url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
> base:   git://linuxtv.org/media_tree.git master
> config: x86_64-federa-25 (attached as .config)
> compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
> reproduce:
>         # save the attached .config to linux build tree
>         make ARCH=x86_64 
> 
> All errors (new ones prefixed by >>):
> 
>    WARNING: modpost: missing MODULE_LICENSE() in drivers/media/radio/si470x/radio-si470x-common.o
>    see include/linux/module.h for more information
> >> ERROR: "si470x_set_freq" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
> >> ERROR: "si470x_viddev_template" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
> >> ERROR: "si470x_ctrl_ops" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
> >> ERROR: "si470x_stop" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
> >> ERROR: "si470x_start" [drivers/media/radio/si470x/radio-si470x-usb.ko] undefined!
> >> ERROR: "si470x_set_freq" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!
> >> ERROR: "si470x_viddev_template" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!
> >> ERROR: "si470x_ctrl_ops" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!
> >> ERROR: "si470x_start" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!
> >> ERROR: "si470x_stop" [drivers/media/radio/si470x/radio-si470x-i2c.ko] undefined!  
> 
> ---
> 0-DAY kernel test infrastructure                Open Source Technology Center
> https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Fixed patch enclosed.

Thanks,
Mauro

[PATCH] media: si470x: allow build both USB and I2C at the same time

Currently, either USB or I2C is built. Change it to allow
having both enabled at the same time.

The main reason is that COMPILE_TEST all[yes/mod]builds will
now contain all drivers under drivers/media.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig
index 192f36f2f4aa..2ed539f9eb87 100644
--- a/drivers/media/radio/Kconfig
+++ b/drivers/media/radio/Kconfig
@@ -15,10 +15,6 @@ if RADIO_ADAPTERS && VIDEO_V4L2
 config RADIO_TEA575X
 	tristate
 
-config RADIO_SI470X
-	bool "Silicon Labs Si470x FM Radio Receiver support"
-	depends on VIDEO_V4L2
-
 source "drivers/media/radio/si470x/Kconfig"
 
 config RADIO_SI4713
diff --git a/drivers/media/radio/si470x/Kconfig b/drivers/media/radio/si470x/Kconfig
index a466654ee5c9..a21172e413a9 100644
--- a/drivers/media/radio/si470x/Kconfig
+++ b/drivers/media/radio/si470x/Kconfig
@@ -1,3 +1,17 @@
+config RADIO_SI470X
+        tristate "Silicon Labs Si470x FM Radio Receiver support"
+        depends on VIDEO_V4L2
+	---help---
+	  This is a driver for devices with the Silicon Labs SI470x
+	  chip (either via USB or I2C buses).
+
+	  Say Y here if you want to connect this type of radio to your
+	  computer's USB port or if it is used by some other driver
+	  via I2C bus.
+
+	  To compile this driver as a module, choose M here: the
+	  module will be called radio-si470x-common.
+
 config USB_SI470X
 	tristate "Silicon Labs Si470x FM Radio Receiver support with USB"
 	depends on USB && RADIO_SI470X
@@ -25,7 +39,7 @@ config USB_SI470X
 
 config I2C_SI470X
 	tristate "Silicon Labs Si470x FM Radio Receiver support with I2C"
-	depends on I2C && RADIO_SI470X && !USB_SI470X
+	depends on I2C && RADIO_SI470X
 	---help---
 	  This is a driver for I2C devices with the Silicon Labs SI470x
 	  chip.
diff --git a/drivers/media/radio/si470x/Makefile b/drivers/media/radio/si470x/Makefile
index 06964816cfd6..563500823e04 100644
--- a/drivers/media/radio/si470x/Makefile
+++ b/drivers/media/radio/si470x/Makefile
@@ -2,8 +2,6 @@
 # Makefile for radios with Silicon Labs Si470x FM Radio Receivers
 #
 
-radio-usb-si470x-objs	:= radio-si470x-usb.o radio-si470x-common.o
-radio-i2c-si470x-objs	:= radio-si470x-i2c.o radio-si470x-common.o
-
-obj-$(CONFIG_USB_SI470X) += radio-usb-si470x.o
-obj-$(CONFIG_I2C_SI470X) += radio-i2c-si470x.o
+obj-$(CONFIG_RADIO_SI470X) := radio-si470x-common.o
+obj-$(CONFIG_USB_SI470X) += radio-si470x-usb.o
+obj-$(CONFIG_I2C_SI470X) += radio-si470x-i2c.o
diff --git a/drivers/media/radio/si470x/radio-si470x-common.c b/drivers/media/radio/si470x/radio-si470x-common.c
index b94d66e53d4e..c40e1753f34b 100644
--- a/drivers/media/radio/si470x/radio-si470x-common.c
+++ b/drivers/media/radio/si470x/radio-si470x-common.c
@@ -110,8 +110,6 @@
 /* kernel includes */
 #include "radio-si470x.h"
 
-
-
 /**************************************************************************
  * Module Parameters
  **************************************************************************/
@@ -195,7 +193,7 @@ static int si470x_set_band(struct si470x_device *radio, int band)
 	radio->band = band;
 	radio->registers[SYSCONFIG2] &= ~SYSCONFIG2_BAND;
 	radio->registers[SYSCONFIG2] |= radio->band << 6;
-	return si470x_set_register(radio, SYSCONFIG2);
+	return radio->set_register(radio, SYSCONFIG2);
 }
 
 /*
@@ -207,7 +205,7 @@ static int si470x_set_chan(struct si470x_device *radio, unsigned short chan)
 	unsigned long time_left;
 	bool timed_out = false;
 
-	retval = si470x_get_register(radio, POWERCFG);
+	retval = radio->get_register(radio, POWERCFG);
 	if (retval)
 		return retval;
 
@@ -219,7 +217,7 @@ static int si470x_set_chan(struct si470x_device *radio, unsigned short chan)
 	/* start tuning */
 	radio->registers[CHANNEL] &= ~CHANNEL_CHAN;
 	radio->registers[CHANNEL] |= CHANNEL_TUNE | chan;
-	retval = si470x_set_register(radio, CHANNEL);
+	retval = radio->set_register(radio, CHANNEL);
 	if (retval < 0)
 		goto done;
 
@@ -238,7 +236,7 @@ static int si470x_set_chan(struct si470x_device *radio, unsigned short chan)
 
 	/* stop tuning */
 	radio->registers[CHANNEL] &= ~CHANNEL_TUNE;
-	retval = si470x_set_register(radio, CHANNEL);
+	retval = radio->set_register(radio, CHANNEL);
 
 done:
 	return retval;
@@ -272,7 +270,7 @@ static int si470x_get_freq(struct si470x_device *radio, unsigned int *freq)
 	int chan, retval;
 
 	/* read channel */
-	retval = si470x_get_register(radio, READCHAN);
+	retval = radio->get_register(radio, READCHAN);
 	chan = radio->registers[READCHAN] & READCHAN_READCHAN;
 
 	/* Frequency (MHz) = Spacing (kHz) x Channel + Bottom of Band (MHz) */
@@ -296,6 +294,7 @@ int si470x_set_freq(struct si470x_device *radio, unsigned int freq)
 
 	return si470x_set_chan(radio, chan);
 }
+EXPORT_SYMBOL_GPL(si470x_set_freq);
 
 
 /*
@@ -343,7 +342,7 @@ static int si470x_set_seek(struct si470x_device *radio,
 		radio->registers[POWERCFG] |= POWERCFG_SEEKUP;
 	else
 		radio->registers[POWERCFG] &= ~POWERCFG_SEEKUP;
-	retval = si470x_set_register(radio, POWERCFG);
+	retval = radio->set_register(radio, POWERCFG);
 	if (retval < 0)
 		return retval;
 
@@ -362,7 +361,7 @@ static int si470x_set_seek(struct si470x_device *radio,
 
 	/* stop seeking */
 	radio->registers[POWERCFG] &= ~POWERCFG_SEEK;
-	retval = si470x_set_register(radio, POWERCFG);
+	retval = radio->set_register(radio, POWERCFG);
 
 	/* try again, if timed out */
 	if (retval == 0 && timed_out)
@@ -381,7 +380,7 @@ int si470x_start(struct si470x_device *radio)
 	/* powercfg */
 	radio->registers[POWERCFG] =
 		POWERCFG_DMUTE | POWERCFG_ENABLE | POWERCFG_RDSM;
-	retval = si470x_set_register(radio, POWERCFG);
+	retval = radio->set_register(radio, POWERCFG);
 	if (retval < 0)
 		goto done;
 
@@ -392,7 +391,7 @@ int si470x_start(struct si470x_device *radio)
 	radio->registers[SYSCONFIG1] |= SYSCONFIG1_GPIO2_INT;
 	if (de)
 		radio->registers[SYSCONFIG1] |= SYSCONFIG1_DE;
-	retval = si470x_set_register(radio, SYSCONFIG1);
+	retval = radio->set_register(radio, SYSCONFIG1);
 	if (retval < 0)
 		goto done;
 
@@ -402,7 +401,7 @@ int si470x_start(struct si470x_device *radio)
 		((radio->band << 6) & SYSCONFIG2_BAND) |/* BAND */
 		((space << 4) & SYSCONFIG2_SPACE) |	/* SPACE */
 		15;					/* VOLUME (max) */
-	retval = si470x_set_register(radio, SYSCONFIG2);
+	retval = radio->set_register(radio, SYSCONFIG2);
 	if (retval < 0)
 		goto done;
 
@@ -413,6 +412,7 @@ int si470x_start(struct si470x_device *radio)
 done:
 	return retval;
 }
+EXPORT_SYMBOL_GPL(si470x_start);
 
 
 /*
@@ -424,7 +424,7 @@ int si470x_stop(struct si470x_device *radio)
 
 	/* sysconfig 1 */
 	radio->registers[SYSCONFIG1] &= ~SYSCONFIG1_RDS;
-	retval = si470x_set_register(radio, SYSCONFIG1);
+	retval = radio->set_register(radio, SYSCONFIG1);
 	if (retval < 0)
 		goto done;
 
@@ -432,11 +432,12 @@ int si470x_stop(struct si470x_device *radio)
 	radio->registers[POWERCFG] &= ~POWERCFG_DMUTE;
 	/* POWERCFG_ENABLE has to automatically go low */
 	radio->registers[POWERCFG] |= POWERCFG_ENABLE |	POWERCFG_DISABLE;
-	retval = si470x_set_register(radio, POWERCFG);
+	retval = radio->set_register(radio, POWERCFG);
 
 done:
 	return retval;
 }
+EXPORT_SYMBOL_GPL(si470x_stop);
 
 
 /*
@@ -448,7 +449,7 @@ static int si470x_rds_on(struct si470x_device *radio)
 
 	/* sysconfig 1 */
 	radio->registers[SYSCONFIG1] |= SYSCONFIG1_RDS;
-	retval = si470x_set_register(radio, SYSCONFIG1);
+	retval = radio->set_register(radio, SYSCONFIG1);
 	if (retval < 0)
 		radio->registers[SYSCONFIG1] &= ~SYSCONFIG1_RDS;
 
@@ -542,6 +543,25 @@ static __poll_t si470x_fops_poll(struct file *file,
 }
 
 
+static int si470x_fops_open(struct file *file)
+{
+	struct si470x_device *radio = video_drvdata(file);
+
+	return radio->fops_open(file);
+}
+
+
+/*
+ * si470x_fops_release - file release
+ */
+static int si470x_fops_release(struct file *file)
+{
+	struct si470x_device *radio = video_drvdata(file);
+
+	return radio->fops_release(file);
+}
+
+
 /*
  * si470x_fops - file operations interface
  */
@@ -570,13 +590,13 @@ static int si470x_s_ctrl(struct v4l2_ctrl *ctrl)
 	case V4L2_CID_AUDIO_VOLUME:
 		radio->registers[SYSCONFIG2] &= ~SYSCONFIG2_VOLUME;
 		radio->registers[SYSCONFIG2] |= ctrl->val;
-		return si470x_set_register(radio, SYSCONFIG2);
+		return radio->set_register(radio, SYSCONFIG2);
 	case V4L2_CID_AUDIO_MUTE:
 		if (ctrl->val)
 			radio->registers[POWERCFG] &= ~POWERCFG_DMUTE;
 		else
 			radio->registers[POWERCFG] |= POWERCFG_DMUTE;
-		return si470x_set_register(radio, POWERCFG);
+		return radio->set_register(radio, POWERCFG);
 	default:
 		return -EINVAL;
 	}
@@ -596,7 +616,7 @@ static int si470x_vidioc_g_tuner(struct file *file, void *priv,
 		return -EINVAL;
 
 	if (!radio->status_rssi_auto_update) {
-		retval = si470x_get_register(radio, STATUSRSSI);
+		retval = radio->get_register(radio, STATUSRSSI);
 		if (retval < 0)
 			return retval;
 	}
@@ -665,7 +685,7 @@ static int si470x_vidioc_s_tuner(struct file *file, void *priv,
 		break;
 	}
 
-	return si470x_set_register(radio, POWERCFG);
+	return radio->set_register(radio, POWERCFG);
 }
 
 
@@ -742,6 +762,15 @@ static int si470x_vidioc_enum_freq_bands(struct file *file, void *priv,
 const struct v4l2_ctrl_ops si470x_ctrl_ops = {
 	.s_ctrl = si470x_s_ctrl,
 };
+EXPORT_SYMBOL_GPL(si470x_ctrl_ops);
+
+static int si470x_vidioc_querycap(struct file *file, void *priv,
+		struct v4l2_capability *capability)
+{
+	struct si470x_device *radio = video_drvdata(file);
+
+	return radio->vidioc_querycap(file, priv, capability);
+};
 
 /*
  * si470x_ioctl_ops - video device ioctl operations
@@ -768,3 +797,6 @@ const struct video_device si470x_viddev_template = {
 	.release		= video_device_release_empty,
 	.ioctl_ops		= &si470x_ioctl_ops,
 };
+EXPORT_SYMBOL_GPL(si470x_viddev_template);
+
+MODULE_LICENSE("GPL");
diff --git a/drivers/media/radio/si470x/radio-si470x-i2c.c b/drivers/media/radio/si470x/radio-si470x-i2c.c
index 41709b24b28f..1b3720b1e737 100644
--- a/drivers/media/radio/si470x/radio-si470x-i2c.c
+++ b/drivers/media/radio/si470x/radio-si470x-i2c.c
@@ -89,7 +89,7 @@ MODULE_PARM_DESC(max_rds_errors, "RDS maximum block errors: *1*");
 /*
  * si470x_get_register - read register
  */
-int si470x_get_register(struct si470x_device *radio, int regnr)
+static int si470x_get_register(struct si470x_device *radio, int regnr)
 {
 	u16 buf[READ_REG_NUM];
 	struct i2c_msg msgs[1] = {
@@ -113,7 +113,7 @@ int si470x_get_register(struct si470x_device *radio, int regnr)
 /*
  * si470x_set_register - write register
  */
-int si470x_set_register(struct si470x_device *radio, int regnr)
+static int si470x_set_register(struct si470x_device *radio, int regnr)
 {
 	int i;
 	u16 buf[WRITE_REG_NUM];
@@ -174,7 +174,7 @@ static int si470x_get_all_registers(struct si470x_device *radio)
 /*
  * si470x_fops_open - file open
  */
-int si470x_fops_open(struct file *file)
+static int si470x_fops_open(struct file *file)
 {
 	struct si470x_device *radio = video_drvdata(file);
 	int retval = v4l2_fh_open(file);
@@ -206,7 +206,7 @@ int si470x_fops_open(struct file *file)
 /*
  * si470x_fops_release - file release
  */
-int si470x_fops_release(struct file *file)
+static int si470x_fops_release(struct file *file)
 {
 	struct si470x_device *radio = video_drvdata(file);
 
@@ -226,8 +226,8 @@ int si470x_fops_release(struct file *file)
 /*
  * si470x_vidioc_querycap - query device capabilities
  */
-int si470x_vidioc_querycap(struct file *file, void *priv,
-		struct v4l2_capability *capability)
+static int si470x_vidioc_querycap(struct file *file, void *priv,
+				  struct v4l2_capability *capability)
 {
 	strlcpy(capability->driver, DRIVER_NAME, sizeof(capability->driver));
 	strlcpy(capability->card, DRIVER_CARD, sizeof(capability->card));
@@ -361,6 +361,12 @@ static int si470x_i2c_probe(struct i2c_client *client,
 	mutex_init(&radio->lock);
 	init_completion(&radio->completion);
 
+	radio->get_register = si470x_get_register;
+	radio->set_register = si470x_set_register;
+	radio->fops_open = si470x_fops_open;
+	radio->fops_release = si470x_fops_release;
+	radio->vidioc_querycap = si470x_vidioc_querycap;
+
 	retval = v4l2_device_register(&client->dev, &radio->v4l2_dev);
 	if (retval < 0) {
 		dev_err(&client->dev, "couldn't register v4l2_device\n");
diff --git a/drivers/media/radio/si470x/radio-si470x-usb.c b/drivers/media/radio/si470x/radio-si470x-usb.c
index 2277e850bb5e..313a95f195a2 100644
--- a/drivers/media/radio/si470x/radio-si470x-usb.c
+++ b/drivers/media/radio/si470x/radio-si470x-usb.c
@@ -250,7 +250,7 @@ static int si470x_set_report(struct si470x_device *radio, void *buf, int size)
 /*
  * si470x_get_register - read register
  */
-int si470x_get_register(struct si470x_device *radio, int regnr)
+static int si470x_get_register(struct si470x_device *radio, int regnr)
 {
 	int retval;
 
@@ -268,7 +268,7 @@ int si470x_get_register(struct si470x_device *radio, int regnr)
 /*
  * si470x_set_register - write register
  */
-int si470x_set_register(struct si470x_device *radio, int regnr)
+static int si470x_set_register(struct si470x_device *radio, int regnr)
 {
 	int retval;
 
@@ -482,12 +482,12 @@ static void si470x_int_in_callback(struct urb *urb)
 }
 
 
-int si470x_fops_open(struct file *file)
+static int si470x_fops_open(struct file *file)
 {
 	return v4l2_fh_open(file);
 }
 
-int si470x_fops_release(struct file *file)
+static int si470x_fops_release(struct file *file)
 {
 	return v4l2_fh_release(file);
 }
@@ -514,8 +514,8 @@ static void si470x_usb_release(struct v4l2_device *v4l2_dev)
 /*
  * si470x_vidioc_querycap - query device capabilities
  */
-int si470x_vidioc_querycap(struct file *file, void *priv,
-		struct v4l2_capability *capability)
+static int si470x_vidioc_querycap(struct file *file, void *priv,
+				  struct v4l2_capability *capability)
 {
 	struct si470x_device *radio = video_drvdata(file);
 
@@ -598,6 +598,12 @@ static int si470x_usb_driver_probe(struct usb_interface *intf,
 	mutex_init(&radio->lock);
 	init_completion(&radio->completion);
 
+	radio->get_register = si470x_get_register;
+	radio->set_register = si470x_set_register;
+	radio->fops_open = si470x_fops_open;
+	radio->fops_release = si470x_fops_release;
+	radio->vidioc_querycap = si470x_vidioc_querycap;
+
 	iface_desc = intf->cur_altsetting;
 
 	/* Set up interrupt endpoint information. */
diff --git a/drivers/media/radio/si470x/radio-si470x.h b/drivers/media/radio/si470x/radio-si470x.h
index 0202f8eb90c4..35fa0f3bbdd2 100644
--- a/drivers/media/radio/si470x/radio-si470x.h
+++ b/drivers/media/radio/si470x/radio-si470x.h
@@ -161,6 +161,15 @@ struct si470x_device {
 	struct completion completion;
 	bool status_rssi_auto_update;	/* Does RSSI get updated automatic? */
 
+	/* si470x ops */
+
+	int (*get_register)(struct si470x_device *radio, int regnr);
+	int (*set_register)(struct si470x_device *radio, int regnr);
+	int (*fops_open)(struct file *file);
+	int (*fops_release)(struct file *file);
+	int (*vidioc_querycap)(struct file *file, void *priv,
+			       struct v4l2_capability *capability);
+
 #if IS_ENABLED(CONFIG_USB_SI470X)
 	/* reference to USB and video device */
 	struct usb_device *usbdev;
@@ -213,13 +222,7 @@ struct si470x_device {
  **************************************************************************/
 extern const struct video_device si470x_viddev_template;
 extern const struct v4l2_ctrl_ops si470x_ctrl_ops;
-int si470x_get_register(struct si470x_device *radio, int regnr);
-int si470x_set_register(struct si470x_device *radio, int regnr);
 int si470x_disconnect_check(struct si470x_device *radio);
 int si470x_set_freq(struct si470x_device *radio, unsigned int freq);
 int si470x_start(struct si470x_device *radio);
 int si470x_stop(struct si470x_device *radio);
-int si470x_fops_open(struct file *file);
-int si470x_fops_release(struct file *file);
-int si470x_vidioc_querycap(struct file *file, void *priv,
-		struct v4l2_capability *capability);

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 12/19] media: davinci: allow build vpbe_display with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 12/19] media: davinci: allow build vpbe_display with COMPILE_TEST Mauro Carvalho Chehab
@ 2018-04-06 18:08   ` kbuild test robot
  0 siblings, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 18:08 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Lad, Prabhakar

[-- Attachment #1: Type: text/plain, Size: 5952 bytes --]

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
config: x86_64-allmodconfig (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All warnings (new ones prefixed by >>):

   In file included from drivers/media/platform/davinci/vpbe_display.c:35:0:
   drivers/media/platform/davinci/vpbe_display.c: In function 'register_device':
>> drivers/media/platform/davinci/vpbe_display.c:1358:5: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
        (int)vpbe_display_layer,
        ^
   include/media/v4l2-common.h:69:44: note: in definition of macro 'v4l2_printk'
     printk(level "%s: " fmt, (dev)->name , ## arg)
                                               ^~~
>> drivers/media/platform/davinci/vpbe_display.c:1356:2: note: in expansion of macro 'v4l2_info'
     v4l2_info(&disp_dev->vpbe_dev->v4l2_dev,
     ^~~~~~~~~
   drivers/media/platform/davinci/vpbe_display.c:1359:5: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
        (int)&vpbe_display_layer->video_dev);
        ^
   include/media/v4l2-common.h:69:44: note: in definition of macro 'v4l2_printk'
     printk(level "%s: " fmt, (dev)->name , ## arg)
                                               ^~~
>> drivers/media/platform/davinci/vpbe_display.c:1356:2: note: in expansion of macro 'v4l2_info'
     v4l2_info(&disp_dev->vpbe_dev->v4l2_dev,
     ^~~~~~~~~

vim +1358 drivers/media/platform/davinci/vpbe_display.c

a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1347  
4c62e976 drivers/media/platform/davinci/vpbe_display.c Greg Kroah-Hartman 2012-12-21  1348  static int register_device(struct vpbe_layer *vpbe_display_layer,
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1349  			   struct vpbe_display *disp_dev,
4c62e976 drivers/media/platform/davinci/vpbe_display.c Greg Kroah-Hartman 2012-12-21  1350  			   struct platform_device *pdev)
4c62e976 drivers/media/platform/davinci/vpbe_display.c Greg Kroah-Hartman 2012-12-21  1351  {
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1352  	int err;
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1353  
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1354  	v4l2_info(&disp_dev->vpbe_dev->v4l2_dev,
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1355  		  "Trying to register VPBE display device.\n");
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17 @1356  	v4l2_info(&disp_dev->vpbe_dev->v4l2_dev,
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1357  		  "layer=%x,layer->video_dev=%x\n",
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17 @1358  		  (int)vpbe_display_layer,
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1359  		  (int)&vpbe_display_layer->video_dev);
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1360  
266c9c2d drivers/media/platform/davinci/vpbe_display.c Prabhakar Lad      2014-10-12  1361  	vpbe_display_layer->video_dev.queue = &vpbe_display_layer->buffer_queue;
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1362  	err = video_register_device(&vpbe_display_layer->video_dev,
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1363  				    VFL_TYPE_GRABBER,
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1364  				    -1);
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1365  	if (err)
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1366  		return -ENODEV;
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1367  
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1368  	vpbe_display_layer->disp_dev = disp_dev;
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1369  	/* set the driver data in platform device */
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1370  	platform_set_drvdata(pdev, disp_dev);
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1371  	video_set_drvdata(&vpbe_display_layer->video_dev,
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1372  			  vpbe_display_layer);
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1373  
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1374  	return 0;
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1375  }
a2c25b44 drivers/media/video/davinci/vpbe_display.c    Manjunath Hadli    2011-06-17  1376  

:::::: The code at line 1358 was first introduced by commit
:::::: a2c25b444e99f2369b29e507568c8703186174d0 [media] davinci vpbe: V4L2 display driver for DM644X SoC

:::::: TO: Manjunath Hadli <manjunath.hadli@ti.com>
:::::: CC: Mauro Carvalho Chehab <mchehab@redhat.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 62679 bytes --]

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST Mauro Carvalho Chehab
  2018-04-06  8:41   ` Tomi Valkeinen
  2018-04-06 11:46   ` kbuild test robot
@ 2018-04-06 19:29   ` kbuild test robot
  2018-04-20 15:13   ` Bartlomiej Zolnierkiewicz
  3 siblings, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 19:29 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Tomi Valkeinen, Bartlomiej Zolnierkiewicz,
	linux-omap, linux-fbdev, dri-devel

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on v4.16 next-20180406]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
reproduce:
        # apt-get install sparse
        make ARCH=x86_64 allmodconfig
        make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

>> drivers/video/fbdev/omap2/omapfb/displays/panel-sony-acx565akm.c:230:23: sparse: cast to restricted __be32
>> drivers/video/fbdev/omap2/omapfb/displays/panel-sony-acx565akm.c:230:23: sparse: cast to restricted __be32
>> drivers/video/fbdev/omap2/omapfb/displays/panel-sony-acx565akm.c:230:23: sparse: cast to restricted __be32
>> drivers/video/fbdev/omap2/omapfb/displays/panel-sony-acx565akm.c:230:23: sparse: cast to restricted __be32
>> drivers/video/fbdev/omap2/omapfb/displays/panel-sony-acx565akm.c:230:23: sparse: cast to restricted __be32
>> drivers/video/fbdev/omap2/omapfb/displays/panel-sony-acx565akm.c:230:23: sparse: cast to restricted __be32
--
>> drivers/video/fbdev/omap2/omapfb/dss/dispc.c:289:9: sparse: context imbalance in 'mgr_fld_write' - different lock contexts for basic block

vim +230 drivers/video/fbdev/omap2/omapfb/displays/panel-sony-acx565akm.c

f76ee892 Tomi Valkeinen 2015-12-09  222  
f76ee892 Tomi Valkeinen 2015-12-09  223  static int panel_enabled(struct panel_drv_data *ddata)
f76ee892 Tomi Valkeinen 2015-12-09  224  {
f76ee892 Tomi Valkeinen 2015-12-09  225  	u32 disp_status;
f76ee892 Tomi Valkeinen 2015-12-09  226  	int enabled;
f76ee892 Tomi Valkeinen 2015-12-09  227  
f76ee892 Tomi Valkeinen 2015-12-09  228  	acx565akm_read(ddata, MIPID_CMD_READ_DISP_STATUS,
f76ee892 Tomi Valkeinen 2015-12-09  229  			(u8 *)&disp_status, 4);
f76ee892 Tomi Valkeinen 2015-12-09 @230  	disp_status = __be32_to_cpu(disp_status);
f76ee892 Tomi Valkeinen 2015-12-09  231  	enabled = (disp_status & (1 << 17)) && (disp_status & (1 << 10));
f76ee892 Tomi Valkeinen 2015-12-09  232  	dev_dbg(&ddata->spi->dev,
f76ee892 Tomi Valkeinen 2015-12-09  233  		"LCD panel %senabled by bootloader (status 0x%04x)\n",
f76ee892 Tomi Valkeinen 2015-12-09  234  		enabled ? "" : "not ", disp_status);
f76ee892 Tomi Valkeinen 2015-12-09  235  	return enabled;
f76ee892 Tomi Valkeinen 2015-12-09  236  }
f76ee892 Tomi Valkeinen 2015-12-09  237  

:::::: The code at line 230 was first introduced by commit
:::::: f76ee892a99e68b55402b8d4b8aeffcae2aff34d omapfb: copy omapdss & displays for omapfb

:::::: TO: Tomi Valkeinen <tomi.valkeinen@ti.com>
:::::: CC: Tomi Valkeinen <tomi.valkeinen@ti.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 19/19] media: staging: davinci_vpfe: allow building with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 19/19] media: staging: davinci_vpfe: allow building with COMPILE_TEST Mauro Carvalho Chehab
@ 2018-04-06 22:25   ` kbuild test robot
  0 siblings, 0 replies; 40+ messages in thread
From: kbuild test robot @ 2018-04-06 22:25 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: kbuild-all, Mauro Carvalho Chehab, Greg Kroah-Hartman,
	Mauro Carvalho Chehab, devel, Linux Media Mailing List

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[also build test WARNING on next-20180406]
[cannot apply to v4.16]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Make-all-media-drivers-build-with-COMPILE_TEST/20180406-163048
base:   git://linuxtv.org/media_tree.git master
reproduce:
        # apt-get install sparse
        make ARCH=x86_64 allmodconfig
        make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

>> drivers/staging/media/davinci_vpfe/dm365_ipipe.c:1276:45: sparse: incorrect type in initializer (different address spaces) @@    expected void [noderef] <asn:1>*from @@    got void [noderef] <asn:1>*from @@
   drivers/staging/media/davinci_vpfe/dm365_ipipe.c:1276:45:    expected void [noderef] <asn:1>*from
   drivers/staging/media/davinci_vpfe/dm365_ipipe.c:1276:45:    got void *[noderef] <asn:1><noident>
>> drivers/staging/media/davinci_vpfe/dm365_ipipe.c:1319:43: sparse: incorrect type in initializer (different address spaces) @@    expected void [noderef] <asn:1>*to @@    got void [noderef] <asn:1>*to @@
   drivers/staging/media/davinci_vpfe/dm365_ipipe.c:1319:43:    expected void [noderef] <asn:1>*to
   drivers/staging/media/davinci_vpfe/dm365_ipipe.c:1319:43:    got void *[noderef] <asn:1><noident>
>> drivers/staging/media/davinci_vpfe/dm365_ipipe.c:1276:47: sparse: dereference of noderef expression
   drivers/staging/media/davinci_vpfe/dm365_ipipe.c:1319:45: sparse: dereference of noderef expression
--
>> drivers/staging/media/davinci_vpfe/dm365_resizer.c:922:32: sparse: incorrect type in argument 2 (different address spaces) @@    expected void const [noderef] <asn:1>*from @@    got stvoid const [noderef] <asn:1>*from @@
   drivers/staging/media/davinci_vpfe/dm365_resizer.c:922:32:    expected void const [noderef] <asn:1>*from
   drivers/staging/media/davinci_vpfe/dm365_resizer.c:922:32:    got struct vpfe_rsz_config_params *config
>> drivers/staging/media/davinci_vpfe/dm365_resizer.c:945:27: sparse: incorrect type in argument 1 (different address spaces) @@    expected void [noderef] <asn:1>*to @@    got sn:1>*to @@
   drivers/staging/media/davinci_vpfe/dm365_resizer.c:945:27:    expected void [noderef] <asn:1>*to
   drivers/staging/media/davinci_vpfe/dm365_resizer.c:945:27:    got void *<noident>
--
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:201:27: sparse: incorrect type in assignment (different address spaces) @@    expected void *ipipeif_base_addr @@    got void [noderef] <avoid *ipipeif_base_addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:201:27:    expected void *ipipeif_base_addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:201:27:    got void [noderef] <asn:2>*ipipeif_base_addr
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27:    expected void const volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27:    expected void const volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:424:41: sparse: incorrect type in initializer (different address spaces) @@    expected struct ipipeif_params *config @@    got struct ipipeif_params *config @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:424:41:    expected struct ipipeif_params *config
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:424:41:    got void [noderef] <asn:1>*arg
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:474:46: sparse: incorrect type in argument 2 (different address spaces) @@    expected void [noderef] <asn:1>*arg @@    got sn:1>*arg @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:474:46:    expected void [noderef] <asn:1>*arg
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:474:46:    got void *arg
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:510:42: sparse: incorrect type in initializer (different address spaces) @@    expected void *ipipeif_base_addr @@    got void [noderef] <avoid *ipipeif_base_addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:510:42:    expected void *ipipeif_base_addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:510:42:    got void [noderef] <asn:2>*ipipeif_base_addr
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27: sparse: incorrect type in argument 1 (different address spaces) @@    expected void const volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27:    expected void const volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:71:27:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:797:42: sparse: incorrect type in initializer (different address spaces) @@    expected void *ipipeif_base_addr @@    got void [noderef] <avoid *ipipeif_base_addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:797:42:    expected void *ipipeif_base_addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:797:42:    got void [noderef] <asn:2>*ipipeif_base_addr
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *
>> drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26: sparse: incorrect type in argument 2 (different address spaces) @@    expected void volatile [noderef] <asn:2>*addr @@    got sn:2>*addr @@
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    expected void volatile [noderef] <asn:2>*addr
   drivers/staging/media/davinci_vpfe/dm365_ipipeif.c:76:26:    got void *

vim +1276 drivers/staging/media/davinci_vpfe/dm365_ipipe.c

da43b6cca Manjunath Hadli 2012-11-28  1262  
da43b6cca Manjunath Hadli 2012-11-28  1263  static int ipipe_s_config(struct v4l2_subdev *sd, struct vpfe_ipipe_config *cfg)
da43b6cca Manjunath Hadli 2012-11-28  1264  {
da43b6cca Manjunath Hadli 2012-11-28  1265  	struct vpfe_ipipe_device *ipipe = v4l2_get_subdevdata(sd);
da43b6cca Manjunath Hadli 2012-11-28  1266  	unsigned int i;
da43b6cca Manjunath Hadli 2012-11-28  1267  	int rval = 0;
da43b6cca Manjunath Hadli 2012-11-28  1268  
da43b6cca Manjunath Hadli 2012-11-28  1269  	for (i = 0; i < ARRAY_SIZE(ipipe_modules); i++) {
da43b6cca Manjunath Hadli 2012-11-28  1270  		unsigned int bit = 1 << i;
3b12c89d0 Lad, Prabhakar  2014-03-29  1271  
da43b6cca Manjunath Hadli 2012-11-28  1272  		if (cfg->flag & bit) {
da43b6cca Manjunath Hadli 2012-11-28  1273  			const struct ipipe_module_if *module_if =
da43b6cca Manjunath Hadli 2012-11-28  1274  						&ipipe_modules[i];
da43b6cca Manjunath Hadli 2012-11-28  1275  			struct ipipe_module_params *params;
da43b6cca Manjunath Hadli 2012-11-28 @1276  			void __user *from = *(void * __user *)
da43b6cca Manjunath Hadli 2012-11-28  1277  				((void *)cfg + module_if->config_offset);
da43b6cca Manjunath Hadli 2012-11-28  1278  			size_t size;
da43b6cca Manjunath Hadli 2012-11-28  1279  			void *to;
da43b6cca Manjunath Hadli 2012-11-28  1280  
da43b6cca Manjunath Hadli 2012-11-28  1281  			params = kmalloc(sizeof(struct ipipe_module_params),
da43b6cca Manjunath Hadli 2012-11-28  1282  					 GFP_KERNEL);
da43b6cca Manjunath Hadli 2012-11-28  1283  			to = (void *)params + module_if->param_offset;
da43b6cca Manjunath Hadli 2012-11-28  1284  			size = module_if->param_size;
da43b6cca Manjunath Hadli 2012-11-28  1285  
da43b6cca Manjunath Hadli 2012-11-28  1286  			if (to && from && size) {
da43b6cca Manjunath Hadli 2012-11-28  1287  				if (copy_from_user(to, from, size)) {
da43b6cca Manjunath Hadli 2012-11-28  1288  					rval = -EFAULT;
da43b6cca Manjunath Hadli 2012-11-28  1289  					break;
da43b6cca Manjunath Hadli 2012-11-28  1290  				}
da43b6cca Manjunath Hadli 2012-11-28  1291  				rval = module_if->set(ipipe, to);
da43b6cca Manjunath Hadli 2012-11-28  1292  				if (rval)
da43b6cca Manjunath Hadli 2012-11-28  1293  					goto error;
da43b6cca Manjunath Hadli 2012-11-28  1294  			} else if (to && !from && size) {
da43b6cca Manjunath Hadli 2012-11-28  1295  				rval = module_if->set(ipipe, NULL);
da43b6cca Manjunath Hadli 2012-11-28  1296  				if (rval)
da43b6cca Manjunath Hadli 2012-11-28  1297  					goto error;
da43b6cca Manjunath Hadli 2012-11-28  1298  			}
da43b6cca Manjunath Hadli 2012-11-28  1299  			kfree(params);
da43b6cca Manjunath Hadli 2012-11-28  1300  		}
da43b6cca Manjunath Hadli 2012-11-28  1301  	}
da43b6cca Manjunath Hadli 2012-11-28  1302  error:
da43b6cca Manjunath Hadli 2012-11-28  1303  	return rval;
da43b6cca Manjunath Hadli 2012-11-28  1304  }
da43b6cca Manjunath Hadli 2012-11-28  1305  
da43b6cca Manjunath Hadli 2012-11-28  1306  static int ipipe_g_config(struct v4l2_subdev *sd, struct vpfe_ipipe_config *cfg)
da43b6cca Manjunath Hadli 2012-11-28  1307  {
da43b6cca Manjunath Hadli 2012-11-28  1308  	struct vpfe_ipipe_device *ipipe = v4l2_get_subdevdata(sd);
da43b6cca Manjunath Hadli 2012-11-28  1309  	unsigned int i;
da43b6cca Manjunath Hadli 2012-11-28  1310  	int rval = 0;
da43b6cca Manjunath Hadli 2012-11-28  1311  
da43b6cca Manjunath Hadli 2012-11-28  1312  	for (i = 1; i < ARRAY_SIZE(ipipe_modules); i++) {
da43b6cca Manjunath Hadli 2012-11-28  1313  		unsigned int bit = 1 << i;
3b12c89d0 Lad, Prabhakar  2014-03-29  1314  
da43b6cca Manjunath Hadli 2012-11-28  1315  		if (cfg->flag & bit) {
da43b6cca Manjunath Hadli 2012-11-28  1316  			const struct ipipe_module_if *module_if =
da43b6cca Manjunath Hadli 2012-11-28  1317  						&ipipe_modules[i];
da43b6cca Manjunath Hadli 2012-11-28  1318  			struct ipipe_module_params *params;
da43b6cca Manjunath Hadli 2012-11-28 @1319  			void __user *to = *(void * __user *)
da43b6cca Manjunath Hadli 2012-11-28  1320  				((void *)cfg + module_if->config_offset);
da43b6cca Manjunath Hadli 2012-11-28  1321  			size_t size;
da43b6cca Manjunath Hadli 2012-11-28  1322  			void *from;
da43b6cca Manjunath Hadli 2012-11-28  1323  
da43b6cca Manjunath Hadli 2012-11-28  1324  			params =  kmalloc(sizeof(struct ipipe_module_params),
da43b6cca Manjunath Hadli 2012-11-28  1325  						GFP_KERNEL);
da43b6cca Manjunath Hadli 2012-11-28  1326  			from = (void *)params + module_if->param_offset;
da43b6cca Manjunath Hadli 2012-11-28  1327  			size = module_if->param_size;
da43b6cca Manjunath Hadli 2012-11-28  1328  
da43b6cca Manjunath Hadli 2012-11-28  1329  			if (to && from && size) {
da43b6cca Manjunath Hadli 2012-11-28  1330  				rval = module_if->get(ipipe, from);
da43b6cca Manjunath Hadli 2012-11-28  1331  				if (rval)
da43b6cca Manjunath Hadli 2012-11-28  1332  					goto error;
da43b6cca Manjunath Hadli 2012-11-28  1333  				if (copy_to_user(to, from, size)) {
da43b6cca Manjunath Hadli 2012-11-28  1334  					rval = -EFAULT;
da43b6cca Manjunath Hadli 2012-11-28  1335  					break;
da43b6cca Manjunath Hadli 2012-11-28  1336  				}
da43b6cca Manjunath Hadli 2012-11-28  1337  			}
da43b6cca Manjunath Hadli 2012-11-28  1338  			kfree(params);
da43b6cca Manjunath Hadli 2012-11-28  1339  		}
da43b6cca Manjunath Hadli 2012-11-28  1340  	}
da43b6cca Manjunath Hadli 2012-11-28  1341  error:
da43b6cca Manjunath Hadli 2012-11-28  1342  	return rval;
da43b6cca Manjunath Hadli 2012-11-28  1343  }
da43b6cca Manjunath Hadli 2012-11-28  1344  

:::::: The code at line 1276 was first introduced by commit
:::::: da43b6ccadcfe801e0316503334f8281b8679210 [media] davinci: vpfe: dm365: add IPIPE support for media controller driver

:::::: TO: Manjunath Hadli <manjunath.hadli@ti.com>
:::::: CC: Mauro Carvalho Chehab <mchehab@redhat.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 02/19] media: omap3isp: allow it to build with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 02/19] media: omap3isp: allow it to build " Mauro Carvalho Chehab
  2018-04-06 12:56   ` kbuild test robot
@ 2018-04-07 13:31   ` Laurent Pinchart
  1 sibling, 0 replies; 40+ messages in thread
From: Laurent Pinchart @ 2018-04-07 13:31 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Hans Verkuil,
	Arnd Bergmann, Stanimir Varbanov, Benjamin Gaignard,
	Philipp Zabel, Ramesh Shanmugasundaram

Hi Mauro,

Thank you for the patch.

On Thursday, 5 April 2018 23:29:29 EEST Mauro Carvalho Chehab wrote:
> There aren't much things required for it to build with COMPILE_TEST.
> It just needs to provide stub for an arm-dependent include.
> 
> Let's replicate the same solution used by ipmmu-vmsa, in order
> to allow building omap3 with COMPILE_TEST.
> 
> The actual logic here came from this driver:
> 
>    drivers/iommu/ipmmu-vmsa.c
> 
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
> ---
>  drivers/media/platform/Kconfig        | 8 ++++----
>  drivers/media/platform/omap3isp/isp.c | 7 +++++++
>  2 files changed, 11 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/media/platform/Kconfig b/drivers/media/platform/Kconfig
> index c7a1cf8a1b01..03c9dfeb7781 100644
> --- a/drivers/media/platform/Kconfig
> +++ b/drivers/media/platform/Kconfig
> @@ -62,12 +62,12 @@ config VIDEO_MUX
> 
>  config VIDEO_OMAP3
>  	tristate "OMAP 3 Camera support"
> -	depends on VIDEO_V4L2 && I2C && VIDEO_V4L2_SUBDEV_API && ARCH_OMAP3
> +	depends on VIDEO_V4L2 && I2C && VIDEO_V4L2_SUBDEV_API
>  	depends on HAS_DMA && OF
> -	depends on OMAP_IOMMU
> -	select ARM_DMA_USE_IOMMU
> +	depends on ((ARCH_OMAP3 && OMAP_IOMMU) || COMPILE_TEST)
> +	select ARM_DMA_USE_IOMMU if OMAP_IOMMU
>  	select VIDEOBUF2_DMA_CONTIG
> -	select MFD_SYSCON
> +	select MFD_SYSCON if ARCH_OMAP3

Is this needed ? Can't MFD_SYSCON be selected on non-ARM platforms ?

>  	select V4L2_FWNODE
>  	---help---
>  	  Driver for an OMAP 3 camera controller.
> diff --git a/drivers/media/platform/omap3isp/isp.c
> b/drivers/media/platform/omap3isp/isp.c index 8eb000e3d8fd..2a11a709aa4f
> 100644
> --- a/drivers/media/platform/omap3isp/isp.c
> +++ b/drivers/media/platform/omap3isp/isp.c
> @@ -61,7 +61,14 @@
>  #include <linux/sched.h>
>  #include <linux/vmalloc.h>
> 
> +#if defined(CONFIG_ARM) && !defined(CONFIG_IOMMU_DMA)
>  #include <asm/dma-iommu.h>
> +#else
> +#define arm_iommu_create_mapping(...)	NULL
> +#define arm_iommu_attach_device(...)	-ENODEV
> +#define arm_iommu_release_mapping(...)	do {} while (0)
> +#define arm_iommu_detach_device(...)	do {} while (0)
> +#endif
> 
>  #include <media/v4l2-common.h>
>  #include <media/v4l2-fwnode.h>

As just commented on in a reply to v1 I still don't think this is a proper 
solution. I'm all for extending compile-test coverage, but I don't believe we 
need to make all drivers compile on every platform. ARM is certainly a 
mainstream-enough platform nowadays to be worth having the media tree compiled 
for.

-- 
Regards,

Laurent Pinchart

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time
  2018-04-06 16:46     ` Mauro Carvalho Chehab
@ 2018-04-18 17:07       ` Daniel Scheller
  2018-04-18 18:53         ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 40+ messages in thread
From: Daniel Scheller @ 2018-04-18 17:07 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Hans Verkuil,
	Douglas Fischer, jasmin

Am Fri, 6 Apr 2018 13:46:03 -0300
schrieb Mauro Carvalho Chehab <mchehab@s-opensource.com>:

> Em Sat, 7 Apr 2018 00:21:07 +0800
> kbuild test robot <lkp@intel.com> escreveu:
> 
> > Hi Mauro,
> > 
> > I love your patch! Yet something to improve:
> > [...]
> 
> Fixed patch enclosed.
> 
> Thanks,
> Mauro
> 
> [PATCH] media: si470x: allow build both USB and I2C at the same time
> 
> Currently, either USB or I2C is built. Change it to allow
> having both enabled at the same time.
> 
> The main reason is that COMPILE_TEST all[yes/mod]builds will
> now contain all drivers under drivers/media.
> 
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

FWIW, this patch (which seemingly is commit
58757984ca3c73284a45dd53ac66f1414057cd09 in media_tree.git) seems to break media_build in a way that on my systems only 20 drivers and modules are built now, while it should be in the 650+ modules range. Hans' automated daily testbuilds suffer from the same issue, looking at todays daily build logs (Wednesday.tar.bz2). I personally build against Kernel 4.16.2 on Gentoo.

This specific commit/patch was found using

  # git bisect good v4.17-rc1
  # git bisect bad media_tree/master

And, "git revert 58767984..." makes all drivers being built again by
media_build.

Not sure if there's something other for which this patch acts as the
trigger of if this needs adaption in media_build, though I thought
reporting this doesn't hurt.

Best regards,
Daniel Scheller
-- 
https://github.com/herrnst

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time
  2018-04-18 17:07       ` Daniel Scheller
@ 2018-04-18 18:53         ` Mauro Carvalho Chehab
  2018-04-18 19:06           ` Daniel Scheller
  0 siblings, 1 reply; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-18 18:53 UTC (permalink / raw)
  To: Daniel Scheller
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Hans Verkuil,
	Douglas Fischer, jasmin

Em Wed, 18 Apr 2018 19:07:40 +0200
Daniel Scheller <d.scheller.oss@gmail.com> escreveu:

> Am Fri, 6 Apr 2018 13:46:03 -0300
> schrieb Mauro Carvalho Chehab <mchehab@s-opensource.com>:
> 
> > Em Sat, 7 Apr 2018 00:21:07 +0800
> > kbuild test robot <lkp@intel.com> escreveu:
> >   
> > > Hi Mauro,
> > > 
> > > I love your patch! Yet something to improve:
> > > [...]  
> > 
> > Fixed patch enclosed.
> > 
> > Thanks,
> > Mauro
> > 
> > [PATCH] media: si470x: allow build both USB and I2C at the same time
> > 
> > Currently, either USB or I2C is built. Change it to allow
> > having both enabled at the same time.
> > 
> > The main reason is that COMPILE_TEST all[yes/mod]builds will
> > now contain all drivers under drivers/media.
> > 
> > Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>  
> 
> FWIW, this patch (which seemingly is commit
> 58757984ca3c73284a45dd53ac66f1414057cd09 in media_tree.git) seems to break media_build in a way that on my systems only 20 drivers and modules are built now, while it should be in the 650+ modules range. Hans' automated daily testbuilds suffer from the same issue, looking at todays daily build logs (Wednesday.tar.bz2). I personally build against Kernel 4.16.2 on Gentoo.
> 
> This specific commit/patch was found using
> 
>   # git bisect good v4.17-rc1
>   # git bisect bad media_tree/master
> 
> And, "git revert 58767984..." makes all drivers being built again by
> media_build.
> 
> Not sure if there's something other for which this patch acts as the
> trigger of if this needs adaption in media_build, though I thought
> reporting this doesn't hurt.
> 
> Best regards,
> Daniel Scheller

Please try this:

diff --git a/drivers/media/radio/si470x/Makefile b/drivers/media/radio/si470x/Makefile
index 563500823e04..682b3146397e 100644
--- a/drivers/media/radio/si470x/Makefile
+++ b/drivers/media/radio/si470x/Makefile
@@ -2,6 +2,6 @@
 # Makefile for radios with Silicon Labs Si470x FM Radio Receivers
 #
 
-obj-$(CONFIG_RADIO_SI470X) := radio-si470x-common.o
+obj-$(CONFIG_RADIO_SI470X) += radio-si470x-common.o
 obj-$(CONFIG_USB_SI470X) += radio-si470x-usb.o
 obj-$(CONFIG_I2C_SI470X) += radio-si470x-i2c.o





Thanks,
Mauro

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time
  2018-04-18 18:53         ` Mauro Carvalho Chehab
@ 2018-04-18 19:06           ` Daniel Scheller
  2018-04-18 19:17             ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 40+ messages in thread
From: Daniel Scheller @ 2018-04-18 19:06 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Hans Verkuil,
	Douglas Fischer, jasmin

Am Wed, 18 Apr 2018 15:53:09 -0300
schrieb Mauro Carvalho Chehab <mchehab@s-opensource.com>:

> Em Wed, 18 Apr 2018 19:07:40 +0200
> Daniel Scheller <d.scheller.oss@gmail.com> escreveu:
> 
> > Am Fri, 6 Apr 2018 13:46:03 -0300
> > schrieb Mauro Carvalho Chehab <mchehab@s-opensource.com>:
> >   
> > > Em Sat, 7 Apr 2018 00:21:07 +0800
> > > kbuild test robot <lkp@intel.com> escreveu:
> > >     
> > > > Hi Mauro,
> > > > 
> > > > I love your patch! Yet something to improve:
> > > > [...]    
> > > 
> > > Fixed patch enclosed.
> > > 
> > > Thanks,
> > > Mauro
> > > 
> > > [PATCH] media: si470x: allow build both USB and I2C at the same
> > > time
> > > 
> > > Currently, either USB or I2C is built. Change it to allow
> > > having both enabled at the same time.
> > > 
> > > The main reason is that COMPILE_TEST all[yes/mod]builds will
> > > now contain all drivers under drivers/media.
> > > 
> > > Signed-off-by: Mauro Carvalho Chehab
> > > <mchehab@s-opensource.com>    
> > 
> > FWIW, this patch (which seemingly is commit
> > 58757984ca3c73284a45dd53ac66f1414057cd09 in media_tree.git) seems
> > to break media_build in a way that on my systems only 20 drivers
> > and modules are built now, while it should be in the 650+ modules
> > range. Hans' automated daily testbuilds suffer from the same issue,
> > looking at todays daily build logs (Wednesday.tar.bz2). I
> > personally build against Kernel 4.16.2 on Gentoo.
> > 
> > This specific commit/patch was found using
> > 
> >   # git bisect good v4.17-rc1
> >   # git bisect bad media_tree/master
> > 
> > And, "git revert 58767984..." makes all drivers being built again by
> > media_build.
> > 
> > Not sure if there's something other for which this patch acts as the
> > trigger of if this needs adaption in media_build, though I thought
> > reporting this doesn't hurt.
> > 
> > Best regards,
> > Daniel Scheller  
> 
> Please try this:
> 
> diff --git a/drivers/media/radio/si470x/Makefile
> b/drivers/media/radio/si470x/Makefile index
> 563500823e04..682b3146397e 100644 ---
> a/drivers/media/radio/si470x/Makefile +++
> b/drivers/media/radio/si470x/Makefile @@ -2,6 +2,6 @@
>  # Makefile for radios with Silicon Labs Si470x FM Radio Receivers
>  #
>  
> -obj-$(CONFIG_RADIO_SI470X) := radio-si470x-common.o
> +obj-$(CONFIG_RADIO_SI470X) += radio-si470x-common.o
>  obj-$(CONFIG_USB_SI470X) += radio-si470x-usb.o
>  obj-$(CONFIG_I2C_SI470X) += radio-si470x-i2c.o

That (ontop of media_tree.git HEAD) fixes it, back to 656 modules.

Thanks!

Best regards,
Daniel Scheller
-- 
https://github.com/herrnst

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time
  2018-04-18 19:06           ` Daniel Scheller
@ 2018-04-18 19:17             ` Mauro Carvalho Chehab
  0 siblings, 0 replies; 40+ messages in thread
From: Mauro Carvalho Chehab @ 2018-04-18 19:17 UTC (permalink / raw)
  To: Daniel Scheller
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Hans Verkuil,
	Douglas Fischer, jasmin

Em Wed, 18 Apr 2018 21:06:12 +0200
Daniel Scheller <d.scheller.oss@gmail.com> escreveu:

> Am Wed, 18 Apr 2018 15:53:09 -0300
> schrieb Mauro Carvalho Chehab <mchehab@s-opensource.com>:
> 
> > Em Wed, 18 Apr 2018 19:07:40 +0200
> > Daniel Scheller <d.scheller.oss@gmail.com> escreveu:
> >   
> > > Am Fri, 6 Apr 2018 13:46:03 -0300
> > > schrieb Mauro Carvalho Chehab <mchehab@s-opensource.com>:
> > >     
> > > > Em Sat, 7 Apr 2018 00:21:07 +0800
> > > > kbuild test robot <lkp@intel.com> escreveu:
> > > >       
> > > > > Hi Mauro,
> > > > > 
> > > > > I love your patch! Yet something to improve:
> > > > > [...]      
> > > > 
> > > > Fixed patch enclosed.
> > > > 
> > > > Thanks,
> > > > Mauro
> > > > 
> > > > [PATCH] media: si470x: allow build both USB and I2C at the same
> > > > time
> > > > 
> > > > Currently, either USB or I2C is built. Change it to allow
> > > > having both enabled at the same time.
> > > > 
> > > > The main reason is that COMPILE_TEST all[yes/mod]builds will
> > > > now contain all drivers under drivers/media.
> > > > 
> > > > Signed-off-by: Mauro Carvalho Chehab
> > > > <mchehab@s-opensource.com>      
> > > 
> > > FWIW, this patch (which seemingly is commit
> > > 58757984ca3c73284a45dd53ac66f1414057cd09 in media_tree.git) seems
> > > to break media_build in a way that on my systems only 20 drivers
> > > and modules are built now, while it should be in the 650+ modules
> > > range. Hans' automated daily testbuilds suffer from the same issue,
> > > looking at todays daily build logs (Wednesday.tar.bz2). I
> > > personally build against Kernel 4.16.2 on Gentoo.
> > > 
> > > This specific commit/patch was found using
> > > 
> > >   # git bisect good v4.17-rc1
> > >   # git bisect bad media_tree/master
> > > 
> > > And, "git revert 58767984..." makes all drivers being built again by
> > > media_build.
> > > 
> > > Not sure if there's something other for which this patch acts as the
> > > trigger of if this needs adaption in media_build, though I thought
> > > reporting this doesn't hurt.
> > > 
> > > Best regards,
> > > Daniel Scheller    
> > 
> > Please try this:
> > 
> > diff --git a/drivers/media/radio/si470x/Makefile
> > b/drivers/media/radio/si470x/Makefile index
> > 563500823e04..682b3146397e 100644 ---
> > a/drivers/media/radio/si470x/Makefile +++
> > b/drivers/media/radio/si470x/Makefile @@ -2,6 +2,6 @@
> >  # Makefile for radios with Silicon Labs Si470x FM Radio Receivers
> >  #
> >  
> > -obj-$(CONFIG_RADIO_SI470X) := radio-si470x-common.o
> > +obj-$(CONFIG_RADIO_SI470X) += radio-si470x-common.o
> >  obj-$(CONFIG_USB_SI470X) += radio-si470x-usb.o
> >  obj-$(CONFIG_I2C_SI470X) += radio-si470x-i2c.o  
> 
> That (ontop of media_tree.git HEAD) fixes it, back to 656 modules.

Good! I'll merge this with a proper description and apply ASAP.

Regards,
Mauro

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST
  2018-04-05 20:29 ` [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST Mauro Carvalho Chehab
                     ` (2 preceding siblings ...)
  2018-04-06 19:29   ` kbuild test robot
@ 2018-04-20 15:13   ` Bartlomiej Zolnierkiewicz
  3 siblings, 0 replies; 40+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2018-04-20 15:13 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Tomi Valkeinen,
	linux-omap, linux-fbdev, dri-devel

On Thursday, April 05, 2018 04:29:42 PM Mauro Carvalho Chehab wrote:
> This driver builds cleanly with COMPILE_TEST, and it is
> needed in order to allow building drivers/media omap2
> driver.
> 
> So, change the logic there to allow building it.
> 
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

This change has broken build on OF=n && COMPILE_TEST=y configs:

https://patchwork.kernel.org/patch/10352465/

[ This is not a problem when compiling for OMAP2 because it depends
  on ARM Multiplatform support which (indirectly) selects OF. ]

Also I would really prefer that people won't merge fbdev related
patches without my ACK and I see this patch in -next coming from
one of your trees..

> ---
>  drivers/video/fbdev/omap2/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/video/fbdev/omap2/Kconfig b/drivers/video/fbdev/omap2/Kconfig
> index 0921c4de8407..82008699d253 100644
> --- a/drivers/video/fbdev/omap2/Kconfig
> +++ b/drivers/video/fbdev/omap2/Kconfig
> @@ -1,4 +1,4 @@
> -if ARCH_OMAP2PLUS
> +if ARCH_OMAP2PLUS || COMPILE_TEST
>  
>  source "drivers/video/fbdev/omap2/omapfb/Kconfig"

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

^ permalink raw reply	[flat|nested] 40+ messages in thread

end of thread, other threads:[~2018-04-20 15:13 UTC | newest]

Thread overview: 40+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-05 20:29 [PATCH v2 00/19] Make all media drivers build with COMPILE_TEST Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 01/19] omap: omap-iommu.h: allow building drivers " Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 02/19] media: omap3isp: allow it to build " Mauro Carvalho Chehab
2018-04-06 12:56   ` kbuild test robot
2018-04-07 13:31   ` Laurent Pinchart
2018-04-05 20:29 ` [PATCH v2 03/19] media: omap3isp/isp: remove an unused static var Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 04/19] media: fsl-viu: mark static functions as such Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 05/19] media: fsl-viu: allow building it with COMPILE_TEST Mauro Carvalho Chehab
2018-04-06 10:43   ` kbuild test robot
2018-04-06 14:03   ` kbuild test robot
2018-04-05 20:29 ` [PATCH v2 06/19] media: cec_gpio: allow building CEC_GPIO " Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 07/19] media: exymos4-is: allow compile test for EXYNOS FIMC-LITE Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 08/19] media: mmp-camera.h: add missing platform data Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 09/19] media: marvel-ccic: re-enable mmp-driver build Mauro Carvalho Chehab
2018-04-06 14:52   ` kbuild test robot
2018-04-05 20:29 ` [PATCH v2 10/19] media: mmp-driver: make two functions static Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 11/19] media: davinci: allow building isif code Mauro Carvalho Chehab
2018-04-06 16:17   ` kbuild test robot
2018-04-05 20:29 ` [PATCH v2 12/19] media: davinci: allow build vpbe_display with COMPILE_TEST Mauro Carvalho Chehab
2018-04-06 18:08   ` kbuild test robot
2018-04-05 20:29 ` [PATCH v2 13/19] media: vpbe_venc: don't store return codes if they won't be used Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 14/19] media: davinci: get rid of lots of kernel-doc warnings Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 15/19] omap2: omapfb: allow building it with COMPILE_TEST Mauro Carvalho Chehab
2018-04-06  8:41   ` Tomi Valkeinen
2018-04-06 11:46   ` kbuild test robot
2018-04-06 19:29   ` kbuild test robot
2018-04-20 15:13   ` Bartlomiej Zolnierkiewicz
2018-04-05 20:29 ` [PATCH v2 16/19] media: omap: " Mauro Carvalho Chehab
2018-04-06 12:11   ` kbuild test robot
2018-04-05 20:29 ` [PATCH v2 17/19] media: omap4iss: make it build " Mauro Carvalho Chehab
2018-04-05 20:59   ` Laurent Pinchart
2018-04-05 20:29 ` [PATCH v2 18/19] media: si470x: allow build both USB and I2C at the same time Mauro Carvalho Chehab
2018-04-06 16:21   ` kbuild test robot
2018-04-06 16:46     ` Mauro Carvalho Chehab
2018-04-18 17:07       ` Daniel Scheller
2018-04-18 18:53         ` Mauro Carvalho Chehab
2018-04-18 19:06           ` Daniel Scheller
2018-04-18 19:17             ` Mauro Carvalho Chehab
2018-04-05 20:29 ` [PATCH v2 19/19] media: staging: davinci_vpfe: allow building with COMPILE_TEST Mauro Carvalho Chehab
2018-04-06 22:25   ` kbuild test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).