Subject: Re: Race condition in ipv6 code

From: Ben Greear <[email-masked]>
Date: Fri, 13 Jan 2012 09:04:46 -0800

On 01/12/2012 11:40 PM, Eric W. Biederman wrote:

> So I really think the best solution to avoid the locking craziness is to
> have a wrapper that gets the value from userspace and calls
> schedule_work to get another thread to actually process the change.  I
> don't see any problems with writing a helper function for that.  The
> only downside with using schedule_work is that we return to userspace
> before the change has been fully installed in the kernel.  I don't
> expect that would be a problem but stranger things have happened.

That sounds a bit risky to me.  If something sets a value, and then
queries it, it should always show the proper result for the previous
calls.

If the queries also went through the the same sched-work queue
then maybe it would be OK.

Thanks,
Ben

-- 
Ben Greear <[email-masked]>
Candela Technologies Inc  http://www.candelatech.com