clocksource: atmel_tcb: fix kconfig dependency
PATCH 1/1 clocksource: atmel_tcb: fix kconfig dependency
From: Arnd Bergmann <[email protected]>
Build-testing this driver on arm without CONFIG_OF produces a warning:
drivers/clocksource/timer-atmel-tcb.c:368:34: error: 'atmel_tcb_of_match' defined but not used [-Werror=unused-const-variable=]
368 | static const struct of_device_id atmel_tcb_of_match[] = {
| ^~~~~~~~~~~~~~~~~~Change the dependency to allow build-testing on all architectures but instead require CONFIG_OF to be present.
---
I saw this for the first time today in a randconfig build, but I think this has been around for a long time without ever showing up in random configs.
--- drivers/clocksource/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/clocksource/Kconfig +2 -2
@@ -437,8 +437,8 @@ config ATMEL_ST config ATMEL_TCB_CLKSRC bool "Atmel TC Block timer driver" if COMPILE_TEST - depends on ARM && HAS_IOMEM - select TIMER_OF if OF + depends on OF && HAS_IOMEM + select TIMER_OF help Support for Timer Counter Blocks on Atmel SoCs.
Signature · 1 line
2.39.5
Quoted 4 lines · Arnd Bergmann
From: Arnd Bergmann <[email protected]>
Build-testing this driver on arm without
CONFIG_OFproduces a warning:
Quoted 9 lines
drivers/clocksource/timer-atmel-tcb.c:368:34: error:
'atmel_tcb_of_match' defined but not used [-Werror=unused-const-variable=]368 | static const struct of_device_id atmel_tcb_of_match[] = { | ^~~~~~~~~~~~~~~~~~Change the dependency to allow build-testing on all architectures but instead require
CONFIG_OFto be present.
And the second I send this out, another failure pops up, please disregard this version as the CONFIG_ARM dependency is still needed for register_current_timer_delay().
Arnd