30a476586ee74244ddad272a3b5f0e637fb81e1e
[openwrt/staging/nbd.git] /
1 From 24c68c2525de5fcd0f3b16b2ad1028fb13b53393 Mon Sep 17 00:00:00 2001
2 From: Arnd Bergmann <arnd@arndb.de>
3 Date: Mon, 15 Jul 2024 08:02:30 +0200
4 Subject: [PATCH 11/11] platform: cznic: turris-omnia-mcu: fix Kconfig
5 dependencies
6
7 The newly added driver causes a Kconfig warning:
8
9 WARNING: unmet direct dependencies detected for RTC_CLASS
10 Depends on [n]: !S390 [=y]
11 Selected by [m]:
12 - TURRIS_OMNIA_MCU [=m] && CZNIC_PLATFORMS [=y] && (MACH_ARMADA_38X || COMPILE_TEST [=y]) && I2C [=m] && OF [=y] && WATCHDOG [=y]
13
14 The problem here is that it selects entire subsystems, which normal
15 device drivers should not do. Changes all of these to 'depends on'
16 instead.
17
18 Fixes: dfa556e45ae9e ("platform: cznic: turris-omnia-mcu: Add support for MCU connected GPIOs")
19 Fixes: 90e700fd12b61 ("platform: cznic: turris-omnia-mcu: Add support for poweroff and wakeup")
20 Fixes: ab89fb5fb92c7 ("platform: cznic: turris-omnia-mcu: Add support for MCU watchdog")
21 Fixes: 41bb142a40289 ("platform: cznic: turris-omnia-mcu: Add support for MCU provided TRNG")
22 Reported-by: Nathan Chancellor <nathan@kernel.org>
23 Signed-off-by: Arnd Bergmann <arnd@arndb.de>
24 ---
25 drivers/platform/cznic/Kconfig | 8 ++++----
26 1 file changed, 4 insertions(+), 4 deletions(-)
27
28 --- a/drivers/platform/cznic/Kconfig
29 +++ b/drivers/platform/cznic/Kconfig
30 @@ -18,11 +18,11 @@ config TURRIS_OMNIA_MCU
31 depends on I2C
32 depends on OF
33 depends on WATCHDOG
34 - select GPIOLIB
35 + depends on GPIOLIB
36 + depends on HW_RANDOM
37 + depends on RTC_CLASS
38 + depends on WATCHDOG_CORE
39 select GPIOLIB_IRQCHIP
40 - select HW_RANDOM
41 - select RTC_CLASS
42 - select WATCHDOG_CORE
43 help
44 Say Y here to add support for the features implemented by the
45 microcontroller on the CZ.NIC's Turris Omnia SOHO router.