Skip to content

Commit ffcdedb

Browse files
nikolay@redhat.comdavem330
authored andcommitted
Revert "bonding: remove sysfs before removing devices"
This reverts commit 4de79c7. This patch introduces a new bug which causes access to freed memory. In bond_uninit: list_del(&bond->bond_list); bond_list is linked in bond_net's dev_list which is freed by unregister_pernet_subsys. Signed-off-by: Nikolay Aleksandrov <nikolay@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 0f27f57 commit ffcdedb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/bonding/bond_main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4902,8 +4902,8 @@ static void __exit bonding_exit(void)
49024902

49034903
bond_destroy_debugfs();
49044904

4905-
unregister_pernet_subsys(&bond_net_ops);
49064905
rtnl_link_unregister(&bond_link_ops);
4906+
unregister_pernet_subsys(&bond_net_ops);
49074907

49084908
#ifdef CONFIG_NET_POLL_CONTROLLER
49094909
/*

0 commit comments

Comments
 (0)