RE: [PATCH net-next v11 10/14] net: ethernet: onsemi: s2500: Add driver support for S2500
From: Selvamani Rajagopal
Date: Wed Nov 18 2026 - 15:41:04 EST
> -----Original Message-----
> From: netdev-bot+sashiko@xxxxxxxxxx <netdev-bot+sashiko@xxxxxxxxxx>
> Sent: Tuesday, November 17, 2026 11:53 AM
> To: Selvamani Rajagopal <Selvamani.Rajagopal@xxxxxxxxxx>
> Subject: Re: [PATCH net-next v11 10/14] net: ethernet: onsemi: s2500: Add driver support
> for S2500
>
>
>
>
> [Severity: Medium]
> Does "rx_mismatch_drops" duplicate a standard counter? It reports the
> hardware count of frames dropped by the MAC address filter, and
> include/uapi/linux/if_link.h documents rtnl_link_stats64 as:
Reported as rx_otherhost_dropped; the private rx_mismatch_drops in vendor's code
has been removed.
>
> [Severity: Medium]
> Can the 32-bit hardware counters wrap before anything reads them?
We are updating the counter every 3 seconds now.
>
> [Severity: Medium]
> Can this threshold stall transmit? The framework only learns about new
> TX credits from a data footer or after an IRQ. Once the cached tx_credits
> reaches 0, the loop in oa_tc6_macphy_threaded_irq() stops:
>
> while (tc6->int_flag ||
> (tc6->waiting_tx_skb && tc6->tx_credits)) {
I believe int_flag would not let it stall. When credit becomes available, device
would generate interrupt that will set int_flag.
>
>
> What is the S2500 TX buffer size? Could the commit message explain why
> 8 credits is safe?
We have been testing with 8 credits for many months. We haven't seen any issue.
>
> [Severity: Medium]
> Can max_adj be larger than the PTP core can pass through on 32-bit?
> S2500_PTP_MAX_ADJ_PPB is GENMASK(27, 0) / 8, which is 33,554,431 ppb.
> ptp_clock_adjtime() converts tx->freq with scaled_ppm_to_ppb() and then
> calls ->adjfine(). Both take the scaled_ppm value as a long:
We kept the hardware limit of 33,554,431 ppb. I don't think there is anything else to
do in vendor's code
> Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261113-s2500-
> mac-phy-support-v11-0-7a186141952c%40onsemi.com
> <https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261113-s2500-mac-phy-support-v11-0-7a186141952c%40onsemi.com
> tdev-ai.bots.linux.dev>