diff options
Diffstat (limited to 'drivers/pps')
-rw-r--r-- | drivers/pps/generators/Kconfig | 6 | ||||
-rw-r--r-- | drivers/pps/generators/pps_gen_parport.c | 11 |
2 files changed, 10 insertions, 7 deletions
diff --git a/drivers/pps/generators/Kconfig b/drivers/pps/generators/Kconfig index 5fbd6148c804..f3a73dd77660 100644 --- a/drivers/pps/generators/Kconfig +++ b/drivers/pps/generators/Kconfig | |||
@@ -2,16 +2,12 @@ | |||
2 | # PPS generators configuration | 2 | # PPS generators configuration |
3 | # | 3 | # |
4 | 4 | ||
5 | if PPS | ||
6 | |||
7 | comment "PPS generators support" | 5 | comment "PPS generators support" |
8 | 6 | ||
9 | config PPS_GENERATOR_PARPORT | 7 | config PPS_GENERATOR_PARPORT |
10 | tristate "Parallel port PPS signal generator" | 8 | tristate "Parallel port PPS signal generator" |
11 | depends on PARPORT != n && GENERIC_TIME | 9 | depends on PARPORT |
12 | help | 10 | help |
13 | If you say yes here you get support for a PPS signal generator which | 11 | If you say yes here you get support for a PPS signal generator which |
14 | utilizes STROBE pin of a parallel port to send PPS signals. It uses | 12 | utilizes STROBE pin of a parallel port to send PPS signals. It uses |
15 | parport abstraction layer and hrtimers to precisely control the signal. | 13 | parport abstraction layer and hrtimers to precisely control the signal. |
16 | |||
17 | endif | ||
diff --git a/drivers/pps/generators/pps_gen_parport.c b/drivers/pps/generators/pps_gen_parport.c index a15fe25efd55..5c32f8dacf56 100644 --- a/drivers/pps/generators/pps_gen_parport.c +++ b/drivers/pps/generators/pps_gen_parport.c | |||
@@ -76,8 +76,15 @@ static enum hrtimer_restart hrtimer_event(struct hrtimer *timer) | |||
76 | long lim, delta; | 76 | long lim, delta; |
77 | unsigned long flags; | 77 | unsigned long flags; |
78 | 78 | ||
79 | /* NB: approx time with blocked interrupts = | 79 | /* We have to disable interrupts here. The idea is to prevent |
80 | send_delay + 3 * SAFETY_INTERVAL */ | 80 | * other interrupts on the same processor to introduce random |
81 | * lags while polling the clock. getnstimeofday() takes <1us on | ||
82 | * most machines while other interrupt handlers can take much | ||
83 | * more potentially. | ||
84 | * | ||
85 | * NB: approx time with blocked interrupts = | ||
86 | * send_delay + 3 * SAFETY_INTERVAL | ||
87 | */ | ||
81 | local_irq_save(flags); | 88 | local_irq_save(flags); |
82 | 89 | ||
83 | /* first of all we get the time stamp... */ | 90 | /* first of all we get the time stamp... */ |