diff options
| author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2026-07-13 19:06:00 -0700 |
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2026-07-13 19:06:00 -0700 |
| commit | 76904fccf81936c084faebc73ac72c0919a42941 (patch) | |
| tree | aee33280e3559d1efc4463cfebbca7ce9302fbec /include/linux/pps_kernel.h | |
| parent | 79d7a453c79e818b8059b1aa6d6a7ad53d9d4f72 (diff) | |
| parent | a13c140cc289c0b7b3770bce5b3ad42ab35074aa (diff) | |
Merge tag 'v7.2-rc3' into next
Sync up with mainline to pull in stable fixes to avoid merge conflicts.
Diffstat (limited to 'include/linux/pps_kernel.h')
| -rw-r--r-- | include/linux/pps_kernel.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/include/linux/pps_kernel.h b/include/linux/pps_kernel.h index aab0aebb529e..9f088c9023b1 100644 --- a/include/linux/pps_kernel.h +++ b/include/linux/pps_kernel.h @@ -99,12 +99,14 @@ static inline void timespec_to_pps_ktime(struct pps_ktime *kt, static inline void pps_get_ts(struct pps_event_time *ts) { +#ifdef CONFIG_NTP_PPS struct system_time_snapshot snap; - ktime_get_snapshot(&snap); - ts->ts_real = ktime_to_timespec64(snap.real); -#ifdef CONFIG_NTP_PPS - ts->ts_raw = ktime_to_timespec64(snap.raw); + ktime_get_snapshot_id(CLOCK_REALTIME, &snap); + ts->ts_real = ktime_to_timespec64(snap.systime); + ts->ts_raw = ktime_to_timespec64(snap.monoraw); +#else + ktime_get_real_ts64(&ts->ts_real); #endif } |
