diff options
author | nikolay@redhat.com <nikolay@redhat.com> | 2013-04-05 20:54:37 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-04-08 16:45:09 -0400 |
commit | ffcdedb667b6db8ee31c7efa76a3ec59d9c3b0fc (patch) | |
tree | 6fc19386e085c0bff5930acc5256bd975ec6272d | |
parent | 0f27f575f9e0d9eb43247da5d90a0f93574a0790 (diff) |
Revert "bonding: remove sysfs before removing devices"
This reverts commit 4de79c737b200492195ebc54a887075327e1ec1d.
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>
-rw-r--r-- | drivers/net/bonding/bond_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c index 171b10f167a5..a51241b2e621 100644 --- a/drivers/net/bonding/bond_main.c +++ b/drivers/net/bonding/bond_main.c | |||
@@ -4902,8 +4902,8 @@ static void __exit bonding_exit(void) | |||
4902 | 4902 | ||
4903 | bond_destroy_debugfs(); | 4903 | bond_destroy_debugfs(); |
4904 | 4904 | ||
4905 | unregister_pernet_subsys(&bond_net_ops); | ||
4906 | rtnl_link_unregister(&bond_link_ops); | 4905 | rtnl_link_unregister(&bond_link_ops); |
4906 | unregister_pernet_subsys(&bond_net_ops); | ||
4907 | 4907 | ||
4908 | #ifdef CONFIG_NET_POLL_CONTROLLER | 4908 | #ifdef CONFIG_NET_POLL_CONTROLLER |
4909 | /* | 4909 | /* |