Skip to contentSkip to conversation

drm: hisilicon: depends on MMU

PATCH In review Randy Dunlap 2 participants 3 messages May 31, 2022 – Jun 19, 2022

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm: hisilicon: depends on MMU

Prevent a kconfig warning when MMU is not enabled by making DRM_HISI_HIBMC depend on MMU.

WARNING: unmet direct dependencies detected for DRM_TTM
Depends on [n]: HAS_IOMEM [=y] && DRM [=m] && MMU [=n]
Selected by [m]:
- DRM_TTM_HELPER [=m] && HAS_IOMEM [=y] && DRM [=m]
- DRM_HISI_HIBMC [=m] && HAS_IOMEM [=y] && DRM [=m] && PCI [=y] && (ARM64 || COMPILE_TEST [=y])

Fixes 4f7f1973b0c8 ("drm/vram: fix Kconfig")
Cc Gerd Hoffmann <[email protected]>
Cc Thomas Zimmermann <[email protected]>
Cc Xinliang Liu <[email protected]>
Cc Tian Tao <[email protected]>
Cc John Stultz <[email protected]>
Cc Xinwei Kong <[email protected]>
Cc Chen Feng <[email protected]>
Cc Christian Koenig <[email protected]>
Cc Huang Rui <[email protected]>
Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
---
 drivers/gpu/drm/hisilicon/hibmc/Kconfig |    1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/hisilicon/hibmc/Kconfig +1 -0
@@ -2,6 +2,7 @@
 config DRM_HISI_HIBMC
 	tristate "DRM Support for Hisilicon Hibmc"
 	depends on DRM && PCI && (ARM64 || COMPILE_TEST)
+	depends on MMU
 	select DRM_KMS_HELPER
 	select DRM_VRAM_HELPER
 	select DRM_TTM
Reviewed-by on v1 1/1
#1 lore raw

Hello Randy,

Quoted 11 lines · Randy Dunlap

Prevent a kconfig warning when MMU is not enabled by making DRM_HISI_HIBMC depend on MMU.

WARNING: unmet direct dependencies detected for DRM_TTM
Depends on [n]: HAS_IOMEM [=y] && DRM [=m] && MMU [=n]
Selected by [m]:
- DRM_TTM_HELPER [=m] && HAS_IOMEM [=y] && DRM [=m]
- DRM_HISI_HIBMC [=m] && HAS_IOMEM [=y] && DRM [=m] && PCI [=y] && (ARM64 || COMPILE_TEST [=y])

Fixes 4f7f1973b0c8 ("drm/vram: fix Kconfig")

Patch looks good to me.

Signature · 5 lines
Best regards,

Javier Martinez Canillas
Linux Engineering
Red Hat
#2 lore raw
Quoted 13 lines · Javier Martinez Canillas

Hello Randy,

Quoted 10 lines · Randy Dunlap

Prevent a kconfig warning when MMU is not enabled by making DRM_HISI_HIBMC depend on MMU.

WARNING: unmet direct dependencies detected for DRM_TTM
Depends on [n]: HAS_IOMEM [=y] && DRM [=m] && MMU [=n]
Selected by [m]:
- DRM_TTM_HELPER [=m] && HAS_IOMEM [=y] && DRM [=m]
- DRM_HISI_HIBMC [=m] && HAS_IOMEM [=y] && DRM [=m] && PCI [=y] && (ARM64 || COMPILE_TEST [=y])

Fixes 4f7f1973b0c8 ("drm/vram: fix Kconfig")

Actually this fixes isn't the correct one AFAICT, it should probably be either acad3fe650a5 ("drm/hisilicon: Removed the dependency on the mmu") or a0f25a6bb319 ("drm/hisilicon/hibmc: Allow to be built if COMPILE_TEST is enabled"). And those two commits should be mentioned in the description.

Maybe we can append the following two paragraphs to your commit message ?

The Kconfig symbol depended on MMU but that was dropped by commit acad3fe650a5 ("drm/hisilicon: Removed the dependency on the mmu") because it already had as a dependency ARM64 that already selects MMU.

But later, commit a0f25a6bb319 ("drm/hisilicon/hibmc: Allow to be built if COMPILE_TEST is enabled") allowed the driver to be built for non-ARM64 when the COMPILE_TEST is set but that could lead to unmet direct dependencies and linking errors.

If you agree with the changes, I can do it before applying. Please let me know.

Signature · 5 lines
Best regards,

Javier Martinez Canillas
Linux Engineering
Red Hat