Ryan Malloy 1ed8f720d6 Correct the PTP page: no PTP on a 4B, but the CM4 has it
Reader sent Geerling's CM4 PTP write-up, which shows two CM4s syncing to 10-15ns.
Our headline overclaimed ('impossible on a Pi 4') and our mechanism was wrong (we
blamed the bcmgenet MAC for not exposing a PHC).

The real story is better: the CM4 (BCM54210PE) and the 4B (BCM54213PE) report the
IDENTICAL PHY ID 0x600d84a2, so the kernel cannot tell them apart by asking the
chip. bcm-phy-ptp.c disambiguates by MDIO bus address instead — addr 0 = CM4,
proceed; addr 1 = 4B, return NULL. Ours is addr 1.

It is not a kernel config gap and not our RT patch: CONFIG_BCM_NET_PHYPTP=y and
CONFIG_NETWORK_PHY_TIMESTAMPING=y are both set. The driver loads, looks at the
board, and declines.

Correction is visible on the page rather than quietly patched. Credit to Geerling.
2026-07-14 14:50:27 -06:00

The Cuckoo Escapement

What the Raspberry Pi time-server guides get wrong, and the numbers to prove it.

Docs: escapement.warehack.ing

We built a GPS-disciplined Stratum 1 NTP server on a Raspberry Pi 4, followed the published advice, and measured everything. Most of that advice is wrong on this board. One piece of it is wrong on every board.

Change RMS offset
Baseline 823 ns
chrony median filter + prefer on the PPS refclock 440 ns
PREEMPT_RT, as the guides recommend 2468 nsworse
PREEMPT_RT + our IRQF_NO_THREAD patch 199 ns

The one thing worth stealing

kernel/0001-pps-gpio-keep-timestamp-in-hard-irq-under-PREEMPT_RT.patch

PREEMPT_RT force-threads interrupt handlers. pps-gpio takes its timestamp inside its handler. So the realtime kernel — the marquee upgrade in every guide — puts a scheduler between the electrical edge and the clock, and triples your jitter. Four lines fix it.

As far as we can tell this isn't applied anywhere, which means anyone running GPIO-based PPS on a realtime kernel today is silently eating microseconds of jitter with no reason to suspect it. chrony still says Stratum 1. Everything still looks fine.

What's here

kernel/ The patch, and how to build it
dashboard/ The live status page (FastAPI + WebSocket, no build step)
docs-site/ The write-up — Astro / Starlight

n = 1

Every number here comes from one Pi 4 and one GPS module. This is a field report, not a study. We're publishing the method alongside the results precisely so you can check it against your own board rather than take our word for it.


A Supported Systems joint.

Description
What the Raspberry Pi time-server guides get wrong, and the numbers to prove it. GPS Stratum 1 on a Pi 4.
Readme 1.1 MiB
2026-07-14 15:54:08 +00:00
Languages
CSS 25.5%
Python 18.3%
Astro 16.6%
JavaScript 15.2%
HTML 8.3%
Other 16.1%