Re: [PATCH net-next v4 6/8] net: dsa: microchip: Enable Ethernet PTP detection

From: Bastien Curutchet

Date: Wed Feb 18 2026 - 05:36:53 EST


Hi,

On 1/30/26 6:16 AM, Tristram.Ha@xxxxxxxxxxxxx wrote:
On Tue, 27 Jan 2026 10:06:48 +0100 Bastien Curutchet (Schneider
Electric) wrote:
KSZ8463 needs to enable the Ethernet PTP detection to fire the
interrupts when a timestamp is captured.

Is it worth stating our expectation WRT other switches given this
is a shared function (not advocating to add a condition to be clear,
just document).

The PTP_ETH_ENABLE bit added here is already set by default on the 'second generation' switches Tristram mentioned but not on the KSZ8463. I'll add details to the commit log.


KSZ8464 uses the first generation of PTP engine while KSZ9477/KSZ9567 and
LAN937X use the second generation. Most of their basic operations like
transmitting are the same. KSZ8463 enables 1-step E2E TC operation by
default while the newer switches need to enable the function manually.
Because of that the PTP function in KSZ8463 is disabled after driver
starts until the Linux PTP stack wants to enable the feature.


I think that here you refer to the PTP_ENABLE bit. It's indeed unset at init in ksz8_config_cpu_port() but it's then set back by ksz_ptp_enable_mode() when needed.

PTP_ETH_ENABLE (bit 5) enables detection of L2 PTP frames
PTP_ENABLE (bit 6) enables the full PTP feature.


Best regards,
Bastien