diff mbox series

"ACPI: video: Drop X86 dependency from Kconfig" is causing config issues elsewhere

Message ID a385b626-217f-25be-f076-7478da3d1147@redhat.com
State New
Headers show
Series "ACPI: video: Drop X86 dependency from Kconfig" is causing config issues elsewhere | expand

Commit Message

Hans de Goede Aug. 7, 2022, 8:34 p.m. UTC
Hi,

I just noticed this change:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=038275d227841d4978ceceb397b584b4b39f2b50


I think this is going to cause random-config build errors because
at the nouveau driver calls acpi_video functions and it expects
those functions to either be there or to get the stubs.

This is an issue when acpi_video is build as a module and the
i915 / nouveau code is builtin.

To avoid this issue nouveau does a select on ACPI_VIDEO,
here is the code from drivers/gpu/drm/nouveau/Kconfig

        # Similar to i915, we need to select ACPI_VIDEO and it's dependencies
        select BACKLIGHT_CLASS_DEVICE if ACPI && X86
        select INPUT if ACPI && X86
        select THERMAL if ACPI && X86
        select ACPI_VIDEO if ACPI && X86

notice the if ACPI && X86, since ACPI_VIDEO can now be selected
on ARM, this can lead to ACPI_VIDEO being enabled as
module (so no stubs) while nouveau can be builtin which will
lead to unresolved symbol errors in nouveau when building the zImage.

I believe that to fix this the conditions after the select must
be changed from "if ACPI && X86" to just "if ACPI"

Riwen Lu, can you please submit follow up patch to fix
the conditions for the ACPI_VIDEO (and dependency) selection
for nouveau?

Regards,

Hans
diff mbox series

Patch

--- a/drivers/acpi/Kconfig
+++ b/drivers/acpi/Kconfig
@@ -210,7 +210,7 @@  config ACPI_TINY_POWER_BUTTON_SIGNAL
 
 config ACPI_VIDEO
 	tristate "Video"
-	depends on X86 && BACKLIGHT_CLASS_DEVICE
+	depends on BACKLIGHT_CLASS_DEVICE
 	depends on INPUT
 	select THERMAL
 	help