net: hns3: fix debugfs concurrency issue between kfree buffer and read
Now in hns3_dbg_uninit(), there may be concurrency between kfree buffer and read, it may result in memory error. Moving debugfs_remove_recursive() in front of kfree buffer to ensure they don't happen at the same time. Fixes: 5e69ea7e ("net: hns3: refactor the debugfs process") Signed-off-by: NHao Chen <chenhao418@huawei.com> Signed-off-by: NJijie Shao <shaojijie@huawei.com> Signed-off-by: NPaolo Abeni <pabeni@redhat.com>
Showing
想要评论请 注册 或 登录