Skip to contentSkip to conversation

pinctrl: max77620: add OF dependency

PATCH In review Arnd Bergmann 2 participants 2 messages Oct 28, 2016 – Oct 29, 2016

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

PATCH 1/1 pinctrl: max77620: add OF dependency

Drivers using pinconf_generic_params tables cannot be built with CONFIG_OF disabled:

drivers/pinctrl/pinctrl-max77620.c:53:44: error: array type has incomplete element type ‘struct pinconf_generic_params’ drivers/pinctrl/pinctrl-max77620.c:55:3: error: field name not in record or union initializer drivers/pinctrl/pinctrl-max77620.c:55:3: note: (near initialization for ‘max77620_cfg_params’) drivers/pinctrl/pinctrl-max77620.c:56:3: error: field name not in record or union initializer

This adds a dependency for max77620 to disallow that configuration.

Alternatively, we could rework the pinctrl infrastructure to make the configuration valid for compile-testing.

Cc Krzysztof Kozlowski <[email protected]>
Cc Lee Jones <[email protected]>
Fixes 453943dc8f45 ("mfd: Enable compile testing for max77620 and max77686")
---
 drivers/pinctrl/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/pinctrl/Kconfig +1 -1
index 801fa8bb05e1..3eea73937ce8 100644
@@ -223,7 +223,7 @@ config PINCTRL_COH901
 
 config PINCTRL_MAX77620
 	tristate "MAX77620/MAX20024 Pincontrol support"
-	depends on MFD_MAX77620
+	depends on MFD_MAX77620 && OF
 	select PINMUX
 	select GENERIC_PINCONF
 	help
Signature · 1 line
2.9.0
#1 lore raw
Quoted 10 lines · Arnd Bergmann

Drivers using pinconf_generic_params tables cannot be built with CONFIG_OF disabled:

drivers/pinctrl/pinctrl-max77620.c:53:44: error: array type has incomplete element type ‘struct pinconf_generic_params’ drivers/pinctrl/pinctrl-max77620.c:55:3: error: field name not in record or union initializer drivers/pinctrl/pinctrl-max77620.c:55:3: note: (near initialization for ‘max77620_cfg_params’) drivers/pinctrl/pinctrl-max77620.c:56:3: error: field name not in record or union initializer

This adds a dependency for max77620 to disallow that configuration.

Quoted 7 lines

Alternatively, we could rework the pinctrl infrastructure to make the configuration valid for compile-testing.

Cc Krzysztof Kozlowski <[email protected]>
Cc Lee Jones <[email protected]>
Fixes 453943dc8f45 ("mfd: Enable compile testing for max77620 and max77686")

Patch applied.

Yours,
Linus Walleij