diff options
| author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2012-10-30 00:20:56 -0700 |
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2012-10-30 00:20:56 -0700 |
| commit | 53279f36dccffc26ff536003fd6bb97cc21c3b82 (patch) | |
| tree | 9d16e497c0e4158c7c054c479bd0e9ff0388d7bb /include/linux/pps_kernel.h | |
| parent | a6e8c0a25377e27958b11b20e1927885ae7c9857 (diff) | |
| parent | 8f0d8163b50e01f398b14bcd4dc039ac5ab18d64 (diff) | |
| download | cachepc-linux-53279f36dccffc26ff536003fd6bb97cc21c3b82.tar.gz cachepc-linux-53279f36dccffc26ff536003fd6bb97cc21c3b82.zip | |
Merge tag 'v3.7-rc3' into next to sync up with recent USB and MFD changes
Diffstat (limited to 'include/linux/pps_kernel.h')
| -rw-r--r-- | include/linux/pps_kernel.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/pps_kernel.h b/include/linux/pps_kernel.h index 94048547f29a..0cc45ae1afd5 100644 --- a/include/linux/pps_kernel.h +++ b/include/linux/pps_kernel.h @@ -116,5 +116,14 @@ static inline void pps_get_ts(struct pps_event_time *ts) #endif /* CONFIG_NTP_PPS */ +/* Subtract known time delay from PPS event time(s) */ +static inline void pps_sub_ts(struct pps_event_time *ts, struct timespec delta) +{ + ts->ts_real = timespec_sub(ts->ts_real, delta); +#ifdef CONFIG_NTP_PPS + ts->ts_raw = timespec_sub(ts->ts_raw, delta); +#endif +} + #endif /* LINUX_PPS_KERNEL_H */ |
