Skip to contentSkip to conversation

gpio: GPIO_SCH: depends on PCI same as LPC_SCH

PATCH Superseded Randy Dunlap 1 participant 2 messages Apr 2, 2021 1 message not in the archive GPIO

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gpio: GPIO_SCH: depends on PCI same as LPC_SCH

Since LPC_SCH depends on PCI, GPIO_SCH must also depend on PCI to prevent kconfig warning and build errors:

WARNING: unmet direct dependencies detected for LPC_SCH
Depends on [n]: HAS_IOMEM [=y] && PCI [=n]
Selected by [y]:
- GPIO_SCH [=y] && GPIOLIB [=y] && X86 [=y] && (X86 [=y] || COMPILE_TEST [=n]) && ACPI [=y]

and

../drivers/mfd/lpc_sch.c:204:1: warning: data definition has no type or storage class
module_pci_driver(lpc_sch_driver);
^~~~~~~~~~~~~~~~~
../drivers/mfd/lpc_sch.c:204:1: error: type defaults to ‘int’ in declaration of ‘module_pci_driver’ [-Werror=implicit-int] ../drivers/mfd/lpc_sch.c:204:1: warning: parameter names (without types) in function declaration ../drivers/mfd/lpc_sch.c:197:26: warning: ‘lpc_sch_driver’ defined but not used [-Wunused-variable]

 static struct pci_driver lpc_sch_driver = {
                          ^~~~~~~~~~~~~~
Fixes 6c46215d6b62 ("gpio: sch: Hook into ACPI GPE handler to catch GPIO edge events")
Cc Andy Shevchenko <[email protected]>
Cc Linus Walleij <[email protected]>
Cc Bartosz Golaszewski <[email protected]>
Cc Denis Turischev <[email protected]>
---
 drivers/gpio/Kconfig |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpio/Kconfig +1 -1
@@ -860,7 +860,7 @@ config GPIO_IT87
 
 config GPIO_SCH
 	tristate "Intel SCH/TunnelCreek/Centerton/Quark X1000 GPIO"
-	depends on (X86 || COMPILE_TEST) && ACPI
+	depends on (X86 || COMPILE_TEST) && ACPI && PCI
 	select GPIOLIB_IRQCHIP
 	select MFD_CORE
 	select LPC_SCH

A message that is not in the archive (sent off-list or not yet received): CAHp75VfqFde+uBHfYe5tZDgwcy3z_yME6MmQea5rydVOfFVkhQ@mail.gmail.com

#2 lore raw
Quoted 27 lines · Andy Shevchenko
Quoted 21 lines · Randy Dunlap

Since LPC_SCH depends on PCI, GPIO_SCH must also depend on PCI to prevent kconfig warning and build errors:

WARNING: unmet direct dependencies detected for LPC_SCH
Depends on [n]: HAS_IOMEM [=y] && PCI [=n]
Selected by [y]:
- GPIO_SCH [=y] && GPIOLIB [=y] && X86 [=y] && (X86 [=y] || COMPILE_TEST
[=n]) && ACPI [=y]

and

../drivers/mfd/lpc_sch.c:204:1: warning: data definition has no type or storage class
module_pci_driver(lpc_sch_driver);
^~~~~~~~~~~~~~~~~
../drivers/mfd/lpc_sch.c:204:1: error: type defaults to ‘int’ in declaration of ‘module_pci_driver’ [-Werror=implicit-int] ../drivers/mfd/lpc_sch.c:204:1: warning: parameter names (without types) in function declaration
../drivers/mfd/lpc_sch.c:197:26: warning: ‘lpc_sch_driver’ defined but not used [-Wunused-variable]

Quoted 4 lines
 static struct pci_driver lpc_sch_driver = {
                          ^~~~~~~~~~~~~~
Quoted 4 lines

Thanks for catching this!
But I am wondering if this actually should be fixed by switching to depends on LPC_SCH. What do you think?

Sounds good to me. I'll send v2 like that.
Thanks.

Quoted 28 lines
Quoted 26 lines
Fixes 6c46215d6b62 ("gpio: sch: Hook into ACPI GPE handler to catch GPIO

edge events")

Cc Andy Shevchenko <[email protected]>
Cc Linus Walleij <[email protected]>
Cc Bartosz Golaszewski <[email protected]>
Cc Denis Turischev <[email protected]>
---
 drivers/gpio/Kconfig |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpio/Kconfig +1 -1
@@ -860,7 +860,7 @@ config GPIO_IT87
 
 config GPIO_SCH
        tristate "Intel SCH/TunnelCreek/Centerton/Quark X1000 GPIO"
-       depends on (X86 || COMPILE_TEST) && ACPI
+       depends on (X86 || COMPILE_TEST) && ACPI && PCI
        select GPIOLIB_IRQCHIP
        select MFD_CORE
        select LPC_SCH
Signature · 1 line
~Randy