From: Sven Eckelmann <sven@narfation.org>
To: netdev@vger.kernel.org, Simon Wunderlich <sw@simonwunderlich.de>
Cc: "David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>,
b.a.t.m.a.n@lists.open-mesh.org,
Jiexun Wang <wangjiexun2025@gmail.com>,
stable@kernel.org, Yuan Tan <yuantan098@gmail.com>,
Yifan Wu <yifanwucs@gmail.com>,
Juefei Pu <tomapufckgml@gmail.com>, Xin Liu <bird@lzu.edu.cn>,
Luxing Yin <tr0jan@lzu.edu.cn>, Ren Wei <n05ec@lzu.edu.cn>,
Simon Wunderlich <sw@simonwunderlich.de>
Subject: Re: [PATCH net 3/8] batman-adv: stop tp_meter sessions during mesh teardown
Date: Sat, 09 May 2026 20:52:06 +0200 [thread overview]
Message-ID: <118589593.nniJfEyVGO@sven-desktop> (raw)
In-Reply-To: <20260508154314.12817-4-sw@simonwunderlich.de>
[-- Attachment #1: Type: text/plain, Size: 1252 bytes --]
On Friday, 8 May 2026 17:43:09 CEST Simon Wunderlich wrote:
> From: Jiexun Wang <wangjiexun2025@gmail.com>
>
> TP meter sessions remain linked on bat_priv->tp_list after the netlink
> request has already finished. When the mesh interface is removed,
> batadv_mesh_free() currently tears down the mesh without first draining
> these sessions.
>
> A running sender thread or a late incoming tp_meter packet can then keep
> processing against a mesh instance which is already shutting down.
> Synchronize tp_meter with the mesh lifetime by stopping all active
> sessions from batadv_mesh_free() and waiting for sender threads to exit
> before teardown continues.
Regarding the review under
https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20260508154314.12817-1-sw%40simonwunderlich.de
The fix for this existing problem is planned for the second net PR - splitted
due to the amount of patches. Besides this split, was not included in this one
because I am waiting for the author to submit the v2 with my change request
(to also fix the second occurrence of the invalid `atomic_dec_and_test`):
https://patchwork.open-mesh.org/project/b.a.t.m.a.n./patch/df73e607bda0c84b22d64d80f8ac887190242baf.1778118303.git.rakukuip@gmail.com/
Regards,
Sven
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2026-05-09 18:52 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-08 15:43 [PATCH net 0/8] pull request: batman-adv 2026-05-08 Simon Wunderlich
2026-05-08 15:43 ` [PATCH net 1/8] batman-adv: fix integer overflow on buff_pos Simon Wunderlich
2026-05-10 17:10 ` patchwork-bot+netdevbpf
2026-05-08 15:43 ` [PATCH net 2/8] batman-adv: reject new tp_meter sessions during teardown Simon Wunderlich
2026-05-08 15:43 ` [PATCH net 3/8] batman-adv: stop tp_meter sessions during mesh teardown Simon Wunderlich
2026-05-09 18:52 ` Sven Eckelmann [this message]
2026-05-08 15:43 ` [PATCH net 4/8] batman-adv: stop caching unowned originator pointers in BAT IV Simon Wunderlich
2026-05-08 15:43 ` [PATCH net 5/8] batman-adv: tp_meter: fix tp_num leak on kmalloc failure Simon Wunderlich
2026-05-08 15:43 ` [PATCH net 6/8] batman-adv: bla: prevent use-after-free when deleting claims Simon Wunderlich
2026-05-08 15:43 ` [PATCH net 7/8] batman-adv: bla: only purge non-released claims Simon Wunderlich
2026-05-08 15:43 ` [PATCH net 8/8] batman-adv: bla: put backbone reference on failed claim hash insert Simon Wunderlich
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=118589593.nniJfEyVGO@sven-desktop \
--to=sven@narfation.org \
--cc=b.a.t.m.a.n@lists.open-mesh.org \
--cc=bird@lzu.edu.cn \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=n05ec@lzu.edu.cn \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=stable@kernel.org \
--cc=sw@simonwunderlich.de \
--cc=tomapufckgml@gmail.com \
--cc=tr0jan@lzu.edu.cn \
--cc=wangjiexun2025@gmail.com \
--cc=yifanwucs@gmail.com \
--cc=yuantan098@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