diff options
author | Eric Dumazet <eric.dumazet@gmail.com> | 2010-12-06 18:29:43 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-12-06 18:29:43 +0100 |
commit | 46bcf14f44d8f31ecfdc8b6708ec15a3b33316d9 (patch) | |
tree | 4d2a200387242e1ed2d95ccd367c77750379e8cc /drivers | |
parent | tulip: fix hang in dmfe driver on sending of big packet (diff) | |
download | linux-46bcf14f44d8f31ecfdc8b6708ec15a3b33316d9.tar.xz linux-46bcf14f44d8f31ecfdc8b6708ec15a3b33316d9.zip |
filter: fix sk_filter rcu handling
Pavel Emelyanov tried to fix a race between sk_filter_(de|at)tach and
sk_clone() in commit 47e958eac280c263397
Problem is we can have several clones sharing a common sk_filter, and
these clones might want to sk_filter_attach() their own filters at the
same time, and can overwrite old_filter->rcu, corrupting RCU queues.
We can not use filter->rcu without being sure no other thread could do
the same thing.
Switch code to a more conventional ref-counting technique : Do the
atomic decrement immediately and queue one rcu call back when last
reference is released.
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
0 files changed, 0 insertions, 0 deletions