Skip to content

Commit

Permalink
iommu/mediatek: Fix MTK_IOMMU dependencies
Browse files Browse the repository at this point in the history
If NO_DMA=y (e.g. Sun-3 all{mod,yes}-config):

    drivers/iommu/dma-iommu.o: In function `iommu_dma_mmap':
    dma-iommu.c:(.text+0x836): undefined reference to `dma_pgprot'

IOMMU_DMA must not be selected, unless HAS_DMA=y.

Hence fix this by making MTK_IOMMU depend on HAS_DMA.
While at it, remove the dependency on ARM || ARM64, as that is already
implied by the dependency on ARCH_MEDIATEK.

Fixes: e93a169 ("iommu: Enable compile testing for some of drivers")
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Link: https://lore.kernel.org/r/20200410143047.19691-1-geert@linux-m68k.org
Signed-off-by: Joerg Roedel <jroedel@suse.de>
  • Loading branch information
Geert Uytterhoeven authored and Joerg Roedel committed Apr 29, 2020
1 parent 5375e87 commit d1dcb72
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/iommu/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,7 @@ config S390_AP_IOMMU

config MTK_IOMMU
bool "MTK IOMMU Support"
depends on ARM || ARM64 || COMPILE_TEST
depends on HAS_DMA
depends on ARCH_MEDIATEK || COMPILE_TEST
select ARM_DMA_USE_IOMMU
select IOMMU_API
Expand Down

0 comments on commit d1dcb72

Please sign in to comment.