Activate Hardware timestamping for PTP

Hello,
I am using a Jetson Xavier AGX with tegra 35.4.1 and I try to use ptp over my eth1 interface.
Here is the output of ethtool.

ethtool -T eth1
Time stamping parameters for eth1:
Capabilities:
hardware-transmit
software-transmit
hardware-receive
software-receive
software-system-clock
hardware-raw-clock
PTP Hardware Clock: 1
Hardware Transmit Timestamp Modes:
off
on
onestep-sync
Hardware Receive Filter Modes:
none
ptpv1-l4-sync
ptpv1-l4-delay-req
ptpv2-l4-sync
ptpv2-l4-delay-req
ptpv2-l2-sync
ptpv2-l2-delay-req
ptpv2-event

Is there a way to have as hardware receive filter mode “all”? Or nvethernet driver does not support this?
Do you have any alternative?

Regards,
Alvaro.

1 Like

Hello there,
may be i was not specific enough.

I added on our kernel the flag CONFIG_NETWORK_PHY_TIMESTAMPING to our kernel and my client application which uses PTP needs a Hardware Receive Filter Mode: “all”.

Could I be missing something? Is this possible or do you have an alternative?

I see that sw timestamping is not supported by the nvethernet driver so we are really needing a solution here.

Thanks in advance,
Alvaro.

What is eth1 here?

Hi,
eth1 is actually what in your predefined ubuntu would be eth0. I tried in the ubuntu distribution and we have the same problem, the filter HWTSTAMP_FILTER_ALL is not provided by the driver for eth0.
On my case I am building a specific yocto distribution, but i am using anyway the nvethernet driver.

Is there any version where that filter is enabled? Or a patch?

I found this topic (Nvidia Orin linuxptp (ptp4l) hardware timestamping[Uploading: ptp4l.conf...]() - #6 by sebastian-uav2022) interesting on that regard, but they just fix ptp sources and the actually work over layer 2.

Regards,
Alvaro.

Hi again,
checking the driver sources, I have found the for ptp, there is the HWTSTAMP_FILTER_ALL filter available. Where it wasnt is for ethtool, which is the tool used by our software to look for the filter.
I modified in nvethernet ethtool.c the available filters and patched to have manually HWTSTAMP_FILTER_ALL available. Is that filter for ethtool not available for a specific reason? The driver itself seem to be able to work with it, so I dont understand why should not be shared with ethtool, but I guess nvidia did it like this for a reason.

Thanks in advance,
Alvaro.

Hi,

I don’t actually know what is your purpose of enable this and why it wasn’t enabled in the beginning.

I can help check but this would take time and please be aware that the release for Jetpack5 on Xaiver is already in maintenance mode. We won’t add much new feature anymore unless it is fatal issue.

Hi,
it is fine, we are interacting with a tool that needs the filter offered from ethtool. I patched the driver to give it back and seems to work.
Regards,
Alvaro.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.