CAPI: Fix locking around capiminor's output queue and drop workaround_lock
authorJan Kiszka <jan.kiszka@web.de>
Mon, 8 Feb 2010 10:12:40 +0000 (10:12 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 17 Feb 2010 00:01:34 +0000 (16:01 -0800)
commitdfbb84ffe94e75e2d56250fa948db40f6c62093f
tree97661005c3f9e79fe19bd9bcabfc7ef6ef71739f
parent68d7347b280b4c1f8253c0676a520fb754f213c7
CAPI: Fix locking around capiminor's output queue and drop workaround_lock

Introduce outlock as a spin lock that protects capiminor's outqueue,
outbytes and outskb (formerly known as ttyskb). outlock can be acquired
from soft-IRQ context via capinc_write, so make it bh-safe.

This finally removes the last reason for keeping the workaround lock
around (which was incomplete and partly broken anyway). And as we no
longer call handle_recv_skb in atomic context, gen_data_b3_resp_for can
use non-atomic allocation now.

Signed-off-by: Jan Kiszka <jan.kiszka@web.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/isdn/capi/capi.c