Thread (3 messages) flat view 3 messages, 3 authors, 1d ago

Re: [PATCH] net: add missing ref_tracker_dir_exit() to alloc_netdev_mqs()

From: Eric Dumazet <edumazet@google.com>
Date: 2026-08-17 05:41:56

On Sat, Aug 15, 2026 at 8:50 AM Tetsuo Handa
[off-list ref] wrote:
sashiko is reporting that trying to read /sys/kernel/debug/ref_tracker/*
causes use-afer-free crash when either alloc_percpu() or dev_addr_init()
in alloc_netdev_mqs() failed, for commit 4d92b95ff2f9 ("net: add net device
refcount tracker infrastructure") added ref_tracker_dir_exit() to only
free_netdev() path.

Reported-by: sashiko.dev (no mail address)
Closes: https://sashiko.dev/#/patchset/56c707e7-1fb0-43ec-b8fb-cf6f451e513e%40I-love.SAKURA.ne.jp
Fixes: 4d92b95ff2f9 ("net: add net device refcount tracker infrastructure")
Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
I have the same remark.

Fixes: 4d92b95ff2f9 ("net: add net device refcount tracker
infrastructure") is where the omission originated in Linux 5.18,
though it was benign until debugfs registration was added to ref_tracker.

Reviewed-by: Eric Dumazet <edumazet@google.com>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help