Eric Dumazet 89c4b442b7 netpoll: more efficient locking
Callers of netpoll_poll_lock() own NAPI_STATE_SCHED

Callers of netpoll_poll_unlock() have BH blocked between
the NAPI_STATE_SCHED being cleared and poll_lock is released.

We can avoid the spinlock which has no contention, and use cmpxchg()
on poll_owner which we need to set anyway.

This removes a possible lockdep violation after the cited commit,
since sk_busy_loop() re-enables BH before calling busy_poll_stop()

Fixes: 217f69743681 ("net: busy-poll: allow preemption in sk_busy_loop()")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-11-16 18:32:02 -05:00
..
2016-11-16 18:32:02 -05:00
2016-02-16 20:21:48 -05:00
2016-06-03 19:37:21 -04:00
2015-04-02 14:04:59 -04:00
2015-11-22 11:54:10 -05:00
2016-11-16 18:32:02 -05:00
2016-11-14 13:17:21 -05:00
2015-10-26 22:24:22 -07:00