[L4s-discuss] Rpi5 and hardware PTP

rjmcmahon <rjmcmahon@rjmcmahon.com> Sat, 25 November 2023 22:51 UTC

Return-Path: <rjmcmahon@rjmcmahon.com>
X-Original-To: l4s-discuss@ietfa.amsl.com
Delivered-To: l4s-discuss@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id D7ABBC14F5E0 for <l4s-discuss@ietfa.amsl.com>; Sat, 25 Nov 2023 14:51:45 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -7.104
X-Spam-Level:
X-Spam-Status: No, score=-7.104 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HK_RANDOM_ENVFROM=0.001, HK_RANDOM_FROM=0.001, RCVD_IN_DNSWL_HI=-5, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=rjmcmahon.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id lhrMGpcf2rsm for <l4s-discuss@ietfa.amsl.com>; Sat, 25 Nov 2023 14:51:40 -0800 (PST)
Received: from bobcat.rjmcmahon.com (bobcat.rjmcmahon.com [45.33.58.123]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id EA543C14F736 for <l4s-discuss@ietf.org>; Sat, 25 Nov 2023 14:51:40 -0800 (PST)
Received: from mail.rjmcmahon.com (bobcat.rjmcmahon.com [45.33.58.123]) by bobcat.rjmcmahon.com (Postfix) with ESMTPA id AB2D21B313 for <l4s-discuss@ietf.org>; Sat, 25 Nov 2023 14:51:40 -0800 (PST)
DKIM-Filter: OpenDKIM Filter v2.11.0 bobcat.rjmcmahon.com AB2D21B313
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rjmcmahon.com; s=bobcat; t=1700952700; bh=FopJkc1XYqru6cVx3CpcdZBqeWz3Q0J22SbEhKtfFko=; h=Date:From:To:Subject:From; b=HkkH/4WHS+EmM/+tmwdpMh8zePom9NYdODY8OCfkqlAR/Ta8y2bycribqqC3VtaK8 I5rJD2II3becCzOionAfI+nI0NN45dG7d+nMEe6NIN/IBqw4weay0mWtb3+fivJyvO b5+U7QQxYdLz4qZk1xyYL+sxC7XBZXvHyKstD+ms=
MIME-Version: 1.0
Date: Sat, 25 Nov 2023 14:51:40 -0800
From: rjmcmahon <rjmcmahon@rjmcmahon.com>
To: l4s-discuss@ietf.org
Message-ID: <ad0d27e2a0094e8984695fb0c9109f8c@rjmcmahon.com>
X-Sender: rjmcmahon@rjmcmahon.com
Content-Type: text/plain; charset="UTF-8"; format="flowed"
Content-Transfer-Encoding: 8bit
Archived-At: <https://mailarchive.ietf.org/arch/msg/l4s-discuss/0_vtoK0rMDapNUxcptmrYyD2Y9A>
Subject: [L4s-discuss] Rpi5 and hardware PTP
X-BeenThere: l4s-discuss@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: "Low Latency, Low Loss, Scalable Throughput \(L4S\) " <l4s-discuss.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/l4s-discuss>, <mailto:l4s-discuss-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/l4s-discuss/>
List-Post: <mailto:l4s-discuss@ietf.org>
List-Help: <mailto:l4s-discuss-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/l4s-discuss>, <mailto:l4s-discuss-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 25 Nov 2023 22:51:45 -0000

Hi All,

Folks are asking about hardware ptp support for a raspberry pi 5. This 
is supported using linuxptp (or ptp4l)

root@raspberrypi5:/etc/sysconfig# ethtool -T eth0
Time stamping parameters for eth0:
Capabilities:
	hardware-transmit
	software-transmit
	hardware-receive
	software-receive
	software-system-clock
	hardware-raw-clock
PTP Hardware Clock: 0
Hardware Transmit Timestamp Modes:
	off
	on
	onestep-sync
Hardware Receive Filter Modes:
	none
	all

root@raspberrypi5:/etc/sysconfig# pmc -u -b 0 'GET TIME_STATUS_NP'
sending: GET TIME_STATUS_NP
	d83add.fffe.95dc73-0 seq 0 RESPONSE MANAGEMENT TIME_STATUS_NP
		master_offset              -99
		ingress_time               1700948724701986653
		cumulativeScaledRateOffset +0.000000000
		scaledLastGmPhaseChange    0
		gmTimeBaseIndicator        0
		lastGmPhaseChange          0x0000'0000000000000000.0000
		gmPresent                  true
		gmIdentity                 6cb311.fffe.071aaa

root@raspberrypi5:/etc/sysconfig# pmc -u -b 0 'GET CURRENT_DATA_SET'
sending: GET CURRENT_DATA_SET
	d83add.fffe.95dc73-0 seq 0 RESPONSE MANAGEMENT CURRENT_DATA_SET
		stepsRemoved     1
		offsetFromMaster -17.0
		meanPathDelay    4495.0

root@raspberrypi5:/etc/sysconfig# systemctl status phc2sys
● phc2sys.service - Synchronize system clock or PTP hardware clock (PHC)
      Loaded: loaded (/lib/systemd/system/phc2sys.service; disabled; 
preset: enabled)
      Active: active (running) since Sat 2023-11-25 12:33:28 PST; 1h 
11min ago
    Main PID: 5136 (phc2sys)
       Tasks: 1 (limit: 4441)
         CPU: 311ms
      CGroup: /system.slice/phc2sys.service
              └─5136 /usr/sbin/phc2sys -a -r

Nov 25 13:44:49 raspberrypi5 phc2sys[5136]: [56125.404] CLOCK_REALTIME 
phc offset       100 s2 freq    -742 delay   1037
Nov 25 13:44:50 raspberrypi5 phc2sys[5136]: [56126.404] CLOCK_REALTIME 
phc offset       -17 s2 freq    -829 delay   1055
Nov 25 13:44:51 raspberrypi5 phc2sys[5136]: [56127.404] CLOCK_REALTIME 
phc offset       -10 s2 freq    -827 delay   1037
Nov 25 13:44:52 raspberrypi5 phc2sys[5136]: [56128.405] CLOCK_REALTIME 
phc offset        90 s2 freq    -730 delay   1037
Nov 25 13:44:53 raspberrypi5 phc2sys[5136]: [56129.405] CLOCK_REALTIME 
phc offset        90 s2 freq    -703 delay   1055
Nov 25 13:44:54 raspberrypi5 phc2sys[5136]: [56130.405] CLOCK_REALTIME 
phc offset       -99 s2 freq    -865 delay   1037
Nov 25 13:44:55 raspberrypi5 phc2sys[5136]: [56131.405] CLOCK_REALTIME 
phc offset       -26 s2 freq    -821 delay   1037
Nov 25 13:44:56 raspberrypi5 phc2sys[5136]: [56132.405] CLOCK_REALTIME 
phc offset        45 s2 freq    -758 delay   1055
Nov 25 13:44:57 raspberrypi5 phc2sys[5136]: [56133.405] CLOCK_REALTIME 
phc offset        41 s2 freq    -749 delay   1055
Nov 25 13:44:58 raspberrypi5 phc2sys[5136]: [56134.405] CLOCK_REALTIME 
phc offset       105 s2 freq    -672 delay   1037

Bob