summaryrefslogtreecommitdiff
path: root/ppsthread.c
Commit message (Collapse)AuthorAgeFilesLines
* Re-integrate Miroslav's support for large PPS offsets.Eric S. Raymond2014-08-221-10/+12
| | | | | | The factoring on this could use some cleanup. All regression tests pass. PPS is live in both gpsd and gpsmon.
* Restore PPS function by backing out Miroslav Lichtvar's last commit.Eric S. Raymond2014-08-211-12/+10
| | | | | | | | It came in way, way out of sequence ansd screwed something up. He may have been fixing some real problem, however. This requures investigation. All regression tests pass.
* splint/cppcheck/coverity cleanup.Eric S. Raymond2014-08-211-0/+1
|
* Fix PPS with large offsets.Miroslav Lichvar2014-08-171-10/+12
| | | | | | | | | | | | | | This was broken by commit 575444. The check if the PPS time isn't referenced with an old message time used PPS offset instead of the difference between local PPS time and local time of the last message. The PPS sample was reported via SHM or chrony socket only if the offset was between -1 and 1000001 seconds. Keep the local timestamp of the last fix in struct gps_device_t in addition to the real timestamp and use it to check the PPS delay. Rename the l_offset variable to delay to avoid further confusion. Signed-off-by: Eric S. Raymond <esr@thyrsus.com>
* ppsthread.c: delete a stray commaGary E. Miller2014-01-021-1/+1
| | | | From: Beat Bolli <bbolli@ewanet.ch>
* ppsthread.c: delete more stray commasGary E. Miller2014-01-021-3/+3
| | | | From: Beat Bolli <bbolli@ewanet.ch>
* Fix stupid typo of TIOCMIWAIT.Gary E. Miller2013-12-261-5/+5
|
* Fix my stupid PPS mistake. PPS still not quit right...Gary E. Miller2013-12-161-1/+1
| | | | Patch by: Mick Durkin <mick.durkin@napierdeltic.demon.co.uk>
* Document a broken assumption about serial and PPS time.Gary E. Miller2013-12-011-0/+3
| | | | | | | The GR-601W can send the serial time fix 10 mSec before the PPS status line change. My guess is some sort of race condition. The consequence is the PPS is matched to the wrong secnod. Leading to an off by one result.
* remove debug gpsd_report() that escaped into git.Gary E. Miller2013-11-301-2/+0
|
* Fix an out of bounds on pulse[] in ppsthread.cGary E. Miller2013-11-301-16/+25
| | | | | | The variable state used to be a boolean, and was used to index into pulse[] to find the last two edges. state became a mask and was accessing pulsep[] out of bounds, doing off things.
* 2nd try at rejecting negative cycle times.Gary E. Miller2013-11-291-5/+4
|
* ppsthread now detects all edges. reject impossible cycle times.Gary E. Miller2013-11-291-2/+9
|
* WHoops, let a debug thing get into git head, revert that.Gary E. Miller2013-11-291-2/+2
|
* Quick, grab a copy of last_fixtime in ppsthread before it changes.Gary E. Miller2013-11-291-5/+8
|
* Improve separation of KPPS and PPS in ppsthread.cGary E. Miller2013-11-291-11/+16
|
* More ppsthread comment tweaks.Gary E. Miller2013-11-261-5/+9
|
* Improve ppsthread comments.Gary E. Miller2013-11-261-2/+6
|
* Fix a comment, a style nit, and a mistaken #ifdef in ppsthread.Gary E. Miller2013-11-261-7/+11
|
* Fix KPPS on Linux, by reverting part of 7d06e770d5f4f8e903a5720a924a93901a140a69Gary E. Miller2013-11-261-6/+0
|
* Fix inane comment in ppsthread.cGary E. Miller2013-11-261-5/+5
|
* Clean up of ntpshm logging.Gary E. Miller2013-11-261-1/+1
|
* Fix some PPS logging.Gary E. Miller2013-11-261-3/+8
|
* Clean up ppsthread comments.Gary E. Miller2013-11-251-6/+6
|
* Fix a bad case of the not-nots.Gary E. Miller2013-11-251-20/+20
|
* Static checker cleanup.Eric S. Raymond2013-11-251-0/+1
|
* Add NetBSD support for RFC2783 PPS.Greg Troxel2013-11-241-10/+84
| | | | | | | | | | | This commit rewrites the introductory comment to be OS-neutral, but does not substantially change it for the "#ifdef linux" reader. Add linux ifdefs around Linux-specific code, and add alternate code for systems that use the serial port file descriptor for RFC2783 calls. Signed-off-by: Eric S. Raymond <esr@thyrsus.com>
* spint annotation fixes. No logic changes.Eric S. Raymond2013-11-181-0/+2
| | | | All regression tests pass, PPS is live.
* Reduce noice when debugging PPS.Eric S. Raymond2013-11-161-4/+11
| | | | All regression tests pass. PPS is live in both gpsmon and gpsd.
* Remove a stray (but harmless) unlock.Eric S. Raymond2013-11-151-1/+0
|
* splint cleanup.Eric S. Raymond2013-11-121-1/+5
|
* Fix PPS offset display bug by properly thread-locking some accesses.Eric S. Raymond2013-11-121-0/+28
|
* Remove more duplicative logging.Michael Tatarinov2013-11-121-5/+4
| | | | Signed-off-by: Eric S. Raymond <esr@thyrsus.com>
* Whoops, fix ppsthread.c. Can't fit float nSec in a long.Gary E. Miller2013-11-101-5/+7
|
* Show PPS edge (when the hook fires) at LOG_INF.Eric S. Raymond2013-11-091-1/+1
|
* Code is fully cppcheck, splint, and Coverity clean.Eric S. Raymond2013-11-061-0/+1
| | | | All regression tests pass. PPS is live.
* Unify time-difference computations. All regression tests pass, PPS is live.Eric S. Raymond2013-11-061-9/+4
|
* Simplify the PPS hook.Michael Tatarinov2013-11-061-13/+7
| | | | Signed-off-by: Eric S. Raymond <esr@thyrsus.com>
* Stamp out timeval in gpsd_ppsmonitor()Gary E. Miller2013-11-051-31/+25
| | | | uSec are the past, nSec are the future
* Fix a bad precision in a debug reportGary E. Miller2013-11-051-1/+1
|
* Full splint cleanup. Partial cppcheck cleanup.Eric S. Raymond2013-11-051-3/+7
|
* More splint fixups.Eric S. Raymond2013-11-051-2/+4
|
* Partial splint cleanup. All regression tests pass. PPS is live.Eric S. Raymond2013-11-051-7/+14
|
* Eliminate a variable simplifying data management.Eric S. Raymond2013-11-031-11/+9
|
* Change two variable names for clarity.Eric S. Raymond2013-11-031-18/+19
|
* Use timedrift_t for all hook arguments.Eric S. Raymond2013-11-031-2/+7
| | | | | | | | | No logic changes in this commit. We push naosecond precision closer to where time hints are shipped. Changes to ppsthread.c are kept minimal; it needs a cleanup but that will be done in another change that can be separately reviewed. All regression tests pass. PPS is live in gpsmon and reported by gpsd.
* ppsthread: clarify the description.Beat Bolli2013-11-021-4/+5
| | | | Signed-off-by: Beat Bolli <bbolli@ewanet.ch>
* Typo fixes.Beat Bolli2013-11-021-3/+3
| | | | Signed-off-by: Beat Bolli <bbolli@ewanet.ch>
* Finish decoupling the PPS watcher code from NTP shared-segment management.Eric S. Raymond2013-11-021-12/+10
| | | | Also, further contain the latter.
* Typo fix.Beat Bolli2013-11-011-1/+1
| | | | | Signed-off-by: Beat Bolli <bbolli@ewanet.ch> Signed-off-by: Eric S. Raymond <esr@thyrsus.com>