Skip to content

Commit ab4f526

Browse files
robertpjdaytorvalds
authored andcommitted
drivers/pps: use surrounding "if PPS" to remove numerous dependency checks
Adding high-level "if PPS" makes lower-level dependency tests superfluous. Link: http://lkml.kernel.org/r/alpine.LFD.2.20.1708261050500.8156@localhost.localdomain Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Acked-by: Rodolfo Giometti <giometti@enneenne.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent a2d8180 commit ab4f526

3 files changed

Lines changed: 8 additions & 9 deletions

File tree

‎drivers/pps/Kconfig‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,18 @@ menuconfig PPS
1919
To compile this driver as a module, choose M here: the module
2020
will be called pps_core.ko.
2121

22+
if PPS
23+
2224
config PPS_DEBUG
2325
bool "PPS debugging messages"
24-
depends on PPS
2526
help
2627
Say Y here if you want the PPS support to produce a bunch of debug
2728
messages to the system log. Select this if you are having a
2829
problem with PPS support and want to see more of what is going on.
2930

3031
config NTP_PPS
3132
bool "PPS kernel consumer support"
32-
depends on PPS && !NO_HZ_COMMON
33+
depends on !NO_HZ_COMMON
3334
help
3435
This option adds support for direct in-kernel time
3536
synchronization using an external PPS signal.
@@ -39,3 +40,5 @@ config NTP_PPS
3940
source drivers/pps/clients/Kconfig
4041

4142
source drivers/pps/generators/Kconfig
43+
44+
endif # PPS

‎drivers/pps/clients/Kconfig‎

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,9 @@
33
#
44

55
comment "PPS clients support"
6-
depends on PPS
76

87
config PPS_CLIENT_KTIMER
98
tristate "Kernel timer client (Testing client, use for debug)"
10-
depends on PPS
119
help
1210
If you say yes here you get support for a PPS debugging client
1311
which uses a kernel timer to generate the PPS signal.
@@ -17,21 +15,20 @@ config PPS_CLIENT_KTIMER
1715

1816
config PPS_CLIENT_LDISC
1917
tristate "PPS line discipline"
20-
depends on PPS && TTY
18+
depends on TTY
2119
help
2220
If you say yes here you get support for a PPS source connected
2321
with the CD (Carrier Detect) pin of your serial port.
2422

2523
config PPS_CLIENT_PARPORT
2624
tristate "Parallel port PPS client"
27-
depends on PPS && PARPORT
25+
depends on PARPORT
2826
help
2927
If you say yes here you get support for a PPS source connected
3028
with the interrupt pin of your parallel port.
3129

3230
config PPS_CLIENT_GPIO
3331
tristate "PPS client using GPIO"
34-
depends on PPS
3532
help
3633
If you say yes here you get support for a PPS source using
3734
GPIO. To be useful you must also register a platform device

‎drivers/pps/generators/Kconfig‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,10 @@
33
#
44

55
comment "PPS generators support"
6-
depends on PPS
76

87
config PPS_GENERATOR_PARPORT
98
tristate "Parallel port PPS signal generator"
10-
depends on PPS && PARPORT && BROKEN
9+
depends on PARPORT && BROKEN
1110
help
1211
If you say yes here you get support for a PPS signal generator which
1312
utilizes STROBE pin of a parallel port to send PPS signals. It uses

0 commit comments

Comments
 (0)