Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions configs/AM64X/AM64X_linux_toc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ linux/Foundational_Components/Kernel/Kernel_Drivers/Network/CPSW-IET
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/CPSW-TSN-Tuning
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/NETCONF-YANG
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_Non_Offload
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_Offload
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/PRP_Offload
linux/Foundational_Components/Kernel/Kernel_Drivers/SPI
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,12 @@ Example:

# ip maddr del 01:80:c4:00:00:0e dev hsr0.5

.. ifconfig:: CONFIG_part_variant in ('AM64X')

.. rubric:: *PTP Support*

For PTP support over HSR, see :ref:`hsr-prp-ptp`.

.. rubric:: Performance

This section describes the throughput and CPU usage metrics in the offload case
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
.. _hsr-prp-ptp:

Check warning on line 1 in source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst

View workflow job for this annotation

GitHub Actions / vale

[vale] reported by reviewdog 🐶 [RedHat.ReadabilityGrade] Simplify your language. The calculated Flesch–Kincaid grade level of 9.43 is above the recommended reading grade level of 9. Raw Output: {"message": "[RedHat.ReadabilityGrade] Simplify your language. The calculated Flesch–Kincaid grade level of 9.43 is above the recommended reading grade level of 9.", "location": {"path": "source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst", "range": {"start": {"line": 1, "column": 1}}}, "severity": "INFO"}

=======================
HSR and PRP PTP support

Check warning on line 4 in source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst

View workflow job for this annotation

GitHub Actions / vale

[vale] reported by reviewdog 🐶 [RedHat.Definitions] Define acronyms and abbreviations (such as 'PRP') on first occurrence if they're likely to be unfamiliar. Raw Output: {"message": "[RedHat.Definitions] Define acronyms and abbreviations (such as 'PRP') on first occurrence if they're likely to be unfamiliar.", "location": {"path": "source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst", "range": {"start": {"line": 4, "column": 9}}}, "severity": "INFO"}

Check warning on line 4 in source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst

View workflow job for this annotation

GitHub Actions / vale

[vale] reported by reviewdog 🐶 [RedHat.Headings] Use sentence-style capitalization in 'HSR and PRP PTP support'. Raw Output: {"message": "[RedHat.Headings] Use sentence-style capitalization in 'HSR and PRP PTP support'.", "location": {"path": "source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst", "range": {"start": {"line": 4, "column": 1}}}, "severity": "INFO"}

Check warning on line 4 in source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst

View workflow job for this annotation

GitHub Actions / vale

[vale] reported by reviewdog 🐶 [RedHat.Definitions] Define acronyms and abbreviations (such as 'HSR') on first occurrence if they're likely to be unfamiliar. Raw Output: {"message": "[RedHat.Definitions] Define acronyms and abbreviations (such as 'HSR') on first occurrence if they're likely to be unfamiliar.", "location": {"path": "source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst", "range": {"start": {"line": 4, "column": 1}}}, "severity": "INFO"}
=======================

The `linuxptp-hsr <https://git.kernel.org/pub/scm/linux/kernel/git/bigeasy/linuxptp-hsr.git>`_
implementation on the ``hsr_prp_v2_plus`` branch supports PTP (Precision Time Protocol)
synchronization over High-availability Seamless Redundancy (HSR) and Parallel Redundancy
Protocol (PRP) interfaces.

In the following commands, replace ``<proto>`` with ``hsr`` or ``prp`` as appropriate.

.. rubric:: Prerequisites

Complete the following steps on each node.

Clone linuxptp-hsr:

.. code-block:: console

git clone https://git.kernel.org/pub/scm/linux/kernel/git/bigeasy/linuxptp-hsr.git
cd linuxptp-hsr
git checkout hsr_prp_v2_plus

Patch the config files with the actual interface names and the P2P destination MAC
address. The config files use INI-style sections where ``[eth1]`` and ``[eth2]``

Check warning on line 27 in source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst

View workflow job for this annotation

GitHub Actions / vale

[vale] reported by reviewdog 🐶 [RedHat.Definitions] Define acronyms and abbreviations (such as 'INI') on first occurrence if they're likely to be unfamiliar. Raw Output: {"message": "[RedHat.Definitions] Define acronyms and abbreviations (such as 'INI') on first occurrence if they're likely to be unfamiliar.", "location": {"path": "source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst", "range": {"start": {"line": 27, "column": 31}}}, "severity": "INFO"}
denote the two physical interfaces. The first command appends the ``p2p_dst_mac``
key (destination MAC for P2P delay-request messages) into the ``[global]``
section just after the ``delay_mechanism`` key. The second command replaces the
``[eth1]`` and ``[eth2]`` section headers with the actual interface names:

.. code-block:: console

sed -i '/^delay_mechanism/a p2p_dst_mac 01:1B:19:00:00:01' configs/<proto>-master.cfg configs/<proto>-slave.cfg
sed -i 's/^\[eth1\]/[<INTF_A>]/; s/^\[eth2\]/[<INTF_B>]/' configs/<proto>-master.cfg configs/<proto>-slave.cfg

Build and install:

.. code-block:: console

make && make install

.. rubric:: Running PTP

Set up the HSR or PRP interface as described in the respective offload documentation.

Check warning on line 46 in source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst

View workflow job for this annotation

GitHub Actions / vale

[vale] reported by reviewdog 🐶 [RedHat.DoNotUseTerms] Do not use "respective" or "respectively". Rewrite to avoid using these words. Raw Output: {"message": "[RedHat.DoNotUseTerms] Do not use \"respective\" or \"respectively\". Rewrite to avoid using these words.", "location": {"path": "source/linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP.rst", "range": {"start": {"line": 46, "column": 53}}}, "severity": "WARNING"}
On the PTP primary node:

.. code-block:: console

./ptp4l -f configs/<proto>-master.cfg

On each PTP secondary node:

.. code-block:: console

./ptp4l -f configs/<proto>-slave.cfg

.. rubric:: Verifying PTP synchronization

Inspect the ``master offset`` values in the ptp4l log output to verify PTP synchronization.

Sample ptp4l output showing a synchronized secondary node:

.. code-block:: text

ptp4l[xx.xxx]: master offset -123 s2 freq +4321 path delay 543
ptp4l[xx.xxx]: master offset 45 s2 freq +4290 path delay 541
ptp4l[xx.xxx]: master offset -78 s2 freq +4310 path delay 544
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,12 @@ Example:

# ip maddr del 01:80:c4:00:00:0e dev prp0.5

.. ifconfig:: CONFIG_part_variant in ('AM64X')

.. rubric:: *PTP Support*

For PTP support over PRP, see :ref:`hsr-prp-ptp`.

.. rubric:: Performance

This section describes the throughput and CPU usage metrics in the offload case
Expand Down
1 change: 1 addition & 0 deletions source/linux/Foundational_Components_Kernel_Drivers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ Kernel Drivers
Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_Non_Offload
Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_Offload
Foundational_Components/Kernel/Kernel_Drivers/Network/PRP_Offload
Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_PTP
Foundational_Components/Kernel/Kernel_Drivers/Network/CPSW-Ethernet
Foundational_Components/Kernel/Kernel_Drivers/Network/CPSW2g
Foundational_Components/Kernel/Kernel_Drivers/Network/NETCONF-YANG
Expand Down
Loading