commit aec6e75b9af551cd5ddbf52ad535843fd0700bfa Author: Miroslav Lichvar Date: Thu Aug 6 14:59:13 2026 +0200 add 38-l2 test diff --git a/38-l2 b/38-l2 new file mode 100755 index 0000000..dd39439 --- /dev/null +++ b/38-l2 @@ -0,0 +1,13 @@ +#!/bin/bash + +. test.common + +test_start "ptp4l with L2 transport" + +master_conf="network_transport L2" +slave_conf="network_transport L2" + +run_ptp4l || test_fail +check_sync || test_fail + +test_pass commit ce79d10d5e34e293b4dabc84719bbe36cac1e5bf Author: Miroslav Lichvar Date: Mon Aug 17 14:09:36 2026 +0200 UPDATE: add 39-pn test diff --git a/39-pn b/39-pn new file mode 100755 index 0000000..fae9fa4 --- /dev/null +++ b/39-pn @@ -0,0 +1,28 @@ +#!/bin/bash + +. test.common + +test_start "ptp4l with PROFINET transport" + +# this is effectively the same as subnets="1 2 | 2 3", but it allows all nodes +# to have the same interfaces to work with a limitation in how clknetsim maps +# raw sockets to ports +base_delay=$(cat <<-EOF | tr -d '\n' + (+ $default_base_delay -1 + (* (equal 0.1 subnet 1) (equal 0.1 from 1) (equal 0.1 to 2)) + (* (equal 0.1 subnet 1) (equal 0.1 from 2) (equal 0.1 to 1)) + (* (equal 0.1 subnet 2) (equal 0.1 from 2) (equal 0.1 to 3)) + (* (equal 0.1 subnet 2) (equal 0.1 from 3) (equal 0.1 to 2))) +EOF +) +subnets="1 2 3 | 1 2 3" +nodes=3 +master_conf="network_transport PN +rh_estimate_sync_timestamp 1 +delay_mechanism P2P" +slave_conf="$master_conf" + +run_ptp4l || test_fail +check_sync || test_fail + +test_pass