Re: [PATCH net-next 07/14] mptcp: annotate data-races around pernet sysctls

From
Matthieu Baerts <matttbe@kernel.org>
Date
2026-11-10 11:28:17
Also in
bridge, linux-rdma, linux-s390, linux-sctp, linux-security-module, lkml, lvs-devel, mptcp, netfilter-devel
Reply to
Jiayuan Chen, 2026-11-09
Hi Jiayuan,

Thank you for the patch!

On 09/11/2026 03:52, Jiayuan Chen wrote:
enabled, add_addr_timeout, checksum_enabled, allow_join_initial_addr_port,
stale_loss_cnt, close_timeout, pm_type and syn_retrans_before_tcp_fallback
are read by their ctrl.c helpers without any lock while the sysctl
handlers update them with WRITE_ONCE(), and the path_manager handler
stores pm_type with a plain write. Add READ_ONCE() to the readers and
WRITE_ONCE() to that handler.
I have the same patch on the MPTCP ML (the WRITE_ONCE() is split in
another one):


https://lore.kernel.org/e8335e14eff144774aec63393f5cce13e69dddc0.1790147728.git.yangang@kylinos.cn (local)

So that's good to me:

Reviewed-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>

Note that my patch was still in review because Sashiko kept complaining
that this was not fixing all issues, e.g. the new WRITE_ONCE() you
introduced is not enough. Gang has a fix for that [1], and that's not
blocking your patch.

[1]
https://lore.kernel.org/c9f533ea507e6a88d3401768785153a63790c3d8.1790147728.git.yangang@kylinos.cn (local)

Cheers,
Matt
-- 
Sponsored by the NGI0 Core fund.
Thread (37 messages) 37 messages, 6 authors, last reply 2d ago
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help