On 11/17, Paul E. McKenney wrote:
>
> Oleg, any thoughts about Jens's optimization?  He would code something
> like:
> 
>       if (srcu_readers_active(&my_srcu))
>               synchronize_srcu();
>       else
>               smp_mb();

Well, this is clearly racy, no? I am not sure, but may be we can do

        smp_mb();
        if (srcu_readers_active(&my_srcu))
                synchronize_srcu();

in this case we also need to add 'smp_mb()' into srcu_read_lock() after
'atomic_inc(&sp->hardluckref)'.

> However, he is doing ordered I/O requests rather than protecting data
> structures.

Probably this makes a difference, but I don't understand this.

Oleg.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to