Re: [syzbot] Re: [syzbot] [fs?] KASAN: slab-use-after-free Read in debugfs_u32_get
From: syzbot
Date: Thu Dec 26 2024 - 20:25:01 EST
For archival purposes, forwarding an incoming command email to
linux-kernel@xxxxxxxxxxxxxxx.
***
Subject: Re: [syzbot] [fs?] KASAN: slab-use-after-free Read in debugfs_u32_get
Author: lizhi.xu@xxxxxxxxxxxxx
#syz test
diff --git a/drivers/net/netdevsim/dev.c b/drivers/net/netdevsim/dev.c
index 3e0b61202f0c..01810508ac1e 100644
--- a/drivers/net/netdevsim/dev.c
+++ b/drivers/net/netdevsim/dev.c
@@ -1650,7 +1650,7 @@ static void nsim_dev_reload_destroy(struct nsim_dev *nsim_dev)
if (devlink_is_reload_failed(devlink))
return;
- debugfs_remove(nsim_dev->take_snapshot);
+ nsim_dev_debugfs_exit(nsim_dev);
if (nsim_dev_get_vfs(nsim_dev)) {
nsim_bus_dev_set_vfs(nsim_dev->nsim_bus_dev, 0);