On 16-06-18 11:16 AM, Eric Dumazet wrote:
Given an update/replace of an action is such a rare occassion, what
is wrong with init doing a spin lock on existing action?
Sure, there is performance impact on fast path at that point - but:
as established update/replace is _a rare occassion_ ;->
The potential 'problem' is not the write side, but the read side.
If you read say 3 values <A, B, C> you might want to read them in a
consistent way, instead of <new_A, old_B, old_C>
That part i get.
What i meant is: while the fast path is doing rcu_read_lock()
of <A, B, C> and on the rare occassion that _init() is doing a
write to <A,B,C> then if it should spin lock it would not corrupt
what fast path sees as <A, B, C> during the transition.
Am i misunderstanding?
cheers,
jamal