On Sat, 2 Mar 2002 kuznet@ms2.inr.ac.ru wrote:
> > w = jiffies % fi->fib_power;
>
> power = fi->fib_power;
> barrier();
> if (power) ...
>
> Such thing are made in this way.
I hope you are sure about this solution for fib_select_multipath
because I'm not. IMO, the solution from Andi looks more correct
for the current scheduler.
What about the new scheduler (for 2.5?), of course, after
replacing the wrong write_lock() with spin_lock_bh(&fib_nh_powers) ?
This lock will be used only in fib_select_multipath because
fib_sync_{up,down} will not play with nh_power. It will protect
only nh_power and I hope the DEAD flag change will not make big
problems for fib_select_multipath.
> Alexey
Regards
-- Julian Anastasov <ja@ssi.bg>- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/