From: "Théo Lebrun" <theo.lebrun@bootlin.com>
To: "김우석[학생](전자정보대학 전자공학과)" <5mghybrid@khu.ac.kr>, netdev@vger.kernel.org
Cc: "Paolo Abeni" <pabeni@redhat.com>, <conor.dooley@microchip.com>,
<andrew+netdev@lunn.ch>, <davem@davemloft.net>,
<edumazet@google.com>, <kuba@kernel.org>,
<richardcochran@gmail.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH net RESEND 1/2] net: macb: Preserve one-step mode on rejected timestamp requests
Date: Mon, 21 Sep 2026 15:11:13 +0200 [thread overview]
Message-ID: <DLL0PZY25HAD.1RWXC61P3MZRV@bootlin.com> (raw)
In-Reply-To: <CAH1Bc_z6PFc7N6XVZ2dQEH=7D9mkXwGkXP2KKMW-Emd4zcf3fA@mail.gmail.com>
Hello Woo-seok Kim,
On Sun Sep 20, 2026 at 11:04 AM CEST, Woo-seok Kim wrote:
> Following up on my September 15 reply. I noticed that the series is
> still marked "Changes Requested" in Patchwork.
>
> This series fixes rejected timestamp requests changing the TX mode and
> the two PTPv1 RX filters disabling receive timestamping. As explained in
> my reply, the additional issues predate this series and are not made
> worse by it. I propose keeping those fixes separate so that this series
> remains focused on the two reported bugs.
>
> Could you please reconsider the Changes Requested status in light of
> that reply and continue reviewing the series as posted?
To me it all depends on the intent behind your series. If you have faced
this bug in practice and your patches are intended to fix your usecase
and prevent others from facing it, then we can take your patches as-is.
If they are edge-cases cleanup patches and you never encountered the
issue (maybe because you don't have hardware), then either
- the patch won't be accepted because it's overall churn or
- you fix the full sequence fully and we consider it a noticeable
improvement and take that series.
About "the proper way(TM)", I expect something like:
int gem_set_hwtst(struct net_device *netdev,
struct kernel_hwtstamp_config *tstamp_config,
struct netlink_ext_ack *extack)
{
struct macb *bp = netdev_priv(netdev);
u32 regval;
if (!macb_dma_ptp(bp))
return -EOPNOTSUPP;
// Step (1): tstamp_config->tx_type validation and precomputing
// of TXBDCTRL and NCR values/masks.
// Step (2): same for tstamp_config->rx_filter.
// Step (3): read-modify-write NCR, writel TXBDCTRL & RXBDCTRL.
bp->tstamp_config = *tstamp_config;
return 0;
}
Improvements:
- we remove writel from the validation code
- we write to NCR once and not twice
- we don't have a tiny gem_ptp_set_ts_mode() function that returns an
int for no reason
- also NCR RMW probably deserves some atomicity through locking
Thanks,
--
Théo Lebrun, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
next prev parent reply other threads:[~2026-09-21 13:11 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-11 8:04 [PATCH net RESEND 0/2] net: macb: Fix PTP timestamp configuration handling kimwooseok
2026-09-11 8:04 ` [PATCH net RESEND 1/2] net: macb: Preserve one-step mode on rejected timestamp requests kimwooseok
2026-09-11 9:51 ` Nicolai Buchwitz
2026-09-15 8:38 ` Paolo Abeni
2026-09-15 11:47 ` kimwooseok
2026-09-20 9:04 ` 김우석[학생](전자정보대학 전자공학과)
2026-09-21 13:11 ` Théo Lebrun [this message]
2026-09-21 15:48 ` 김우석[학생](전자정보대학 전자공학과)
2026-09-21 18:16 ` Théo Lebrun
2026-09-11 8:04 ` [PATCH net RESEND 2/2] net: macb: Use all-frame timestamping for PTPv1 RX filters kimwooseok
2026-09-11 9:55 ` Nicolai Buchwitz
2026-09-15 8:38 ` Paolo Abeni
2026-09-15 11:48 ` kimwooseok
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DLL0PZY25HAD.1RWXC61P3MZRV@bootlin.com \
--to=theo.lebrun@bootlin.com \
--cc=5mghybrid@khu.ac.kr \
--cc=andrew+netdev@lunn.ch \
--cc=conor.dooley@microchip.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=richardcochran@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®