[ovs-dev] [PATCH] datapath: Use call_rcu() when deleting a datapath.
Ben Pfaff
blp at nicira.com
Wed Jan 5 21:16:59 UTC 2011
On Wed, Jan 05, 2011 at 01:12:41PM -0800, Jesse Gross wrote:
> When deleting a datapath, we remove all of the vports and then immediately
> free the datapath data structures. Since the vports are allowed to use
> call_rcu() to free their data, it's possible for them to return immediately
> while packet processing is still taking place. This breaks apart the dropping
> of references and the freeing of the data using call_rcu() for protection.
>
> This race cannot actually occur in practice since the last port to be
> deleted is an internal device, which uses synchronize_rcu() itself
> (implicitly through unregister_netdevice()). However, there is no
> requirement that it must do this nor should there be.
>
> Reported-by: Ben Pfaff <blp at nicira.com>
> Signed-off-by: Jesse Gross <jesse at nicira.com>
Acked-by: Ben Pfaff <blp at nicira.com>
More information about the dev
mailing list