Skip to contentSkip to conversation

char/rtc: replace blacklist with whitelist

PATCH In review Arnd Bergmann 3 participants 5 messages Apr 27, 2016 – May 1, 2016 Char and misc drivers

lore
Share & tools
lore

Arnd Bergmann

author maintainer
#0 lore raw

PATCH v3 1/1 char/rtc: replace blacklist with whitelist

Every new architecture has to add itself to the growing list of those that do not support the legacy PC RTC driver.

This replaces the long list of architectures that don't support it with a shorter list of those that do.

The list is taken from those architectures that have a non-empty asm/mc146818rtc.h header file and were not explicitly blacklisted or select RTC_LIB.

Alpha and Loongson64 can already choose between this driver and an rtc-class based one. mn10300 is actually the only architecture now that still requires this driver, and that should be fairly easy to change to use rtc-cmos if we want to kill off rtc.ko for good.

---
This time I've trimmed down the whitelist even more, and separate the patch from the other ones that are now all about the GEN_RTC driver.

 drivers/char/Kconfig | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/char/Kconfig +1 -2
index 3ec0766ed5e9..ca397384dc15 100644
@@ -279,8 +279,7 @@ if RTC_LIB=n
 
 config RTC
 	tristate "Enhanced Real Time Clock Support (legacy PC RTC driver)"
-	depends on !PPC && !PARISC && !IA64 && !M68K && !SPARC && !FRV \
-			&& !ARM && !SUPERH && !S390 && !AVR32 && !BLACKFIN && !UML
+	depends on ALPHA || (MIPS && MACH_LOONGSON64) || MN10300
 	---help---
 	  If you say Y here and create a character special file /dev/rtc with
 	  major number 10 and minor number 135 using mknod ("man mknod"), you
Signature · 1 line
2.7.0
Acked-by on v3 1/1
#1 lore raw
Quoted 10 lines · Arnd Bergmann

Every new architecture has to add itself to the growing list of those that do not support the legacy PC RTC driver.

This replaces the long list of architectures that don't support it with a shorter list of those that do.

The list is taken from those architectures that have a non-empty asm/mc146818rtc.h header file and were not explicitly blacklisted or select RTC_LIB.

Quoted 8 lines

Alpha and Loongson64 can already choose between this driver and an rtc-class based one. mn10300 is actually the only architecture now that still requires this driver, and that should be fairly easy to change to use rtc-cmos if we want to kill off rtc.ko for good.

drivers/char/Kconfig if RTC_LIB=n · line 282

Quoted 9 lines
drivers/char/Kconfig +1 -2
@@ -279,8 +279,7 @@ if RTC_LIB=n
 
 config RTC
        tristate "Enhanced Real Time Clock Support (legacy PC RTC driver)"
-       depends on !PPC && !PARISC && !IA64 && !M68K && !SPARC && !FRV \
-                       && !ARM && !SUPERH && !S390 && !AVR32 && !BLACKFIN && !UML
+       depends on ALPHA || (MIPS && MACH_LOONGSON64) || MN10300

Minor nit: MACH_LOONGSON64 implies MIPS, so I think you can drop the latter.

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds

author maintainer
#2 lore raw
Quoted 4 lines · On Wednesday 27 April 2016 21:52:48 Geert Uytterhoeven wrote:
Quoted 4 lines
drivers/char/Kconfig +0 -0
@@ -279,8 +279,7 @@ if RTC_LIB=n
 
Quoted 8 lines

drivers/char/Kconfig if RTC_LIB=n · line 282

Quoted 5 lines
drivers/char/Kconfig +1 -2
 config RTC
        tristate "Enhanced Real Time Clock Support (legacy PC RTC driver)"
-       depends on !PPC && !PARISC && !IA64 && !M68K && !SPARC && !FRV \
-                       && !ARM && !SUPERH && !S390 && !AVR32 && !BLACKFIN && !UML
+       depends on ALPHA || (MIPS && MACH_LOONGSON64) || MN10300

Minor nit: MACH_LOONGSON64 implies MIPS, so I think you can drop the latter.

I listed it intentionally, to make it clearer to the reader what is going on. Actually MIPS as a dependency by itself would also be sufficient, because that contains

select RTC_LIB if !MACH_LOONGSON64

and RTC depends on !RTC_LIB.

Arnd

#3 lore raw
In reply to Arnd Bergmann
Quoted 16 lines · Arnd Bergmann

Every new architecture has to add itself to the growing list of those that do not support the legacy PC RTC driver.

This replaces the long list of architectures that don't support it with a shorter list of those that do.

The list is taken from those architectures that have a non-empty asm/mc146818rtc.h header file and were not explicitly blacklisted or select RTC_LIB.

Alpha and Loongson64 can already choose between this driver and an rtc-class based one. mn10300 is actually the only architecture now that still requires this driver, and that should be fairly easy to change to use rtc-cmos if we want to kill off rtc.ko for good.

Quoted 6 lines

---
This time I've trimmed down the whitelist even more, and separate the patch from the other ones that are now all about the GEN_RTC driver.

So this is safe to take on it's own and you are going to redo that larger series?

confused,

greg k-h

author maintainer
#4 lore raw
Quoted 24 lines · On Sunday 01 May 2016 13:21:07 Greg Kroah-Hartman wrote:
Quoted 16 lines · Arnd Bergmann

Every new architecture has to add itself to the growing list of those that do not support the legacy PC RTC driver.

This replaces the long list of architectures that don't support it with a shorter list of those that do.

The list is taken from those architectures that have a non-empty asm/mc146818rtc.h header file and were not explicitly blacklisted or select RTC_LIB.

Alpha and Loongson64 can already choose between this driver and an rtc-class based one. mn10300 is actually the only architecture now that still requires this driver, and that should be fairly easy to change to use rtc-cmos if we want to kill off rtc.ko for good.

Quoted 6 lines

---
This time I've trimmed down the whitelist even more, and separate the patch from the other ones that are now all about the GEN_RTC driver.

Quoted 2 lines

So this is safe to take on it's own and you are going to redo that larger series?

What I tried to say here is that this patch is now completely independent from the longer series, please apply it directly.

Arnd