[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 4 Apr 2013 18:08:34 +0200
From: Jiri Pirko <jiri@...nulli.us>
To: Eric Dumazet <eric.dumazet@...il.com>
Cc: David Miller <davem@...emloft.net>, vfalico@...hat.com,
netdev@...r.kernel.org, stephen@...workplumber.org
Subject: Re: [PATCH net-next] bridge: remove a redundant synchronize_net()
Thu, Apr 04, 2013 at 06:03:45PM CEST, eric.dumazet@...il.com wrote:
>On Thu, 2013-04-04 at 08:44 -0700, Eric Dumazet wrote:
>
>> Because maybe the synchronize_net() in netdev_rx_handler_unregister()
>> is enough and you dont even need the call_rcu(). Thats was my question.
>
>So we have the following sequence in team_port_del()
>
> netdev_rx_handler_unregister(port_dev);
>
> netdev_upper_dev_unlink(port_dev, dev);
> team_port_disable_netpoll(port);
> vlan_vids_del_by_dev(port_dev, dev);
> dev_uc_unsync(port_dev, dev);
> dev_mc_unsync(port_dev, dev);
> dev_close(port_dev);
> team_port_leave(team, port);
>
> __team_option_inst_mark_removed_port(team, port);
> __team_options_change_check(team);
> __team_option_inst_del_port(team, port);
> __team_port_change_port_removed(port);
>
> team_port_set_orig_dev_addr(port);
> dev_set_mtu(port_dev, port->orig.mtu);
> synchronize_rcu();
> kfree(port);
>
>And I suspect we can remove synchronize_rcu() call.
I agree.
>
>But as this is a long list of operations, maybe some of them requires
>the rcu grace period before kfree(port)
None of them requires that.
>
>
>
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists