linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] media: staging: ipu3: Enable IOVA API only when IOMMU support is enabled
@ 2019-07-22 13:47 YueHaibing
  2019-07-24 10:30 ` Sakari Ailus
  0 siblings, 1 reply; 11+ messages in thread
From: YueHaibing @ 2019-07-22 13:47 UTC (permalink / raw)
  To: sakari.ailus, mchehab, gregkh, yong.zhi, digetx, hverkuil-cisco
  Cc: linux-kernel, devel, linux-media, YueHaibing

If IOMMU_SUPPORT is not set, ipu3 driver may select IOMMU_IOVA to m.
But for many drivers, they use "select IOMMU_IOVA if IOMMU_SUPPORT"
in the Kconfig, for example, CONFIG_TEGRA_VDE is set to y but IOMMU_IOVA
is m, then the building fails like this:

drivers/staging/media/tegra-vde/iommu.o: In function `tegra_vde_iommu_map':
iommu.c:(.text+0x41): undefined reference to `alloc_iova'
iommu.c:(.text+0x56): undefined reference to `__free_iova'

Reported-by: Hulk Robot <hulkci@huawei.com>
Fixes: 7fc7af649ca7 ("media: staging/intel-ipu3: Add imgu top level pci device driver")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/staging/media/ipu3/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/media/ipu3/Kconfig b/drivers/staging/media/ipu3/Kconfig
index 4b51c67..b7df18f 100644
--- a/drivers/staging/media/ipu3/Kconfig
+++ b/drivers/staging/media/ipu3/Kconfig
@@ -4,7 +4,7 @@ config VIDEO_IPU3_IMGU
 	depends on PCI && VIDEO_V4L2
 	depends on MEDIA_CONTROLLER && VIDEO_V4L2_SUBDEV_API
 	depends on X86
-	select IOMMU_IOVA
+	select IOMMU_IOVA if IOMMU_SUPPORT
 	select VIDEOBUF2_DMA_SG
 	help
 	  This is the Video4Linux2 driver for Intel IPU3 image processing unit,
-- 
2.7.4



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

end of thread, other threads:[~2019-09-20 22:26 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-22 13:47 [PATCH] media: staging: ipu3: Enable IOVA API only when IOMMU support is enabled YueHaibing
2019-07-24 10:30 ` Sakari Ailus
2019-07-24 13:49   ` Robin Murphy
2019-07-24 14:03     ` Yuehaibing
2019-07-24 14:09       ` Dmitry Osipenko
2019-07-24 14:23         ` Robin Murphy
2019-07-24 14:28           ` Dmitry Osipenko
2019-07-25  2:41             ` [PATCH] media: staging: tegra-vde: Fix build error YueHaibing
2019-07-25  7:19               ` Dmitry Osipenko
2019-09-20 19:32                 ` Arnd Bergmann
2019-09-20 22:26                   ` Dmitry Osipenko

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).