linux/net/bluetooth
Satyam Sharma 4ce61d1c7a [BLUETOOTH]: Fix locking in hci_sock_dev_event().
We presently use lock_sock() to acquire a lock on a socket in
hci_sock_dev_event(), but this goes BUG because lock_sock()
can sleep and we're already holding a read-write spinlock at
that point. So, we must use the non-sleeping BH version,
bh_lock_sock().

However, hci_sock_dev_event() is called from user context and
hence using simply bh_lock_sock() will deadlock against a
concurrent softirq that tries to acquire a lock on the same
socket. Hence, disabling BH's before acquiring the socket lock
and enable them afterwards, is the proper solution to fix
socket locking in hci_sock_dev_event().

Signed-off-by: Satyam Sharma <ssatyam@cse.iitk.ac.in>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-05-17 14:20:30 -07:00
..
bnep header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
cmtp [SK_BUFF]: Introduce skb_copy_from_linear_data{_offset} 2007-04-25 22:28:23 -07:00
hidp Merge branch 'upstream-fixes' of master.kernel.org:/pub/scm/linux/kernel/git/jikos/hid 2007-05-11 09:56:05 -07:00
rfcomm [Bluetooth] Disconnect L2CAP connection after last RFCOMM DLC 2007-05-05 00:36:13 +02:00
af_bluetooth.c [SK_BUFF]: Introduce skb_reset_transport_header(skb) 2007-04-25 22:25:15 -07:00
hci_conn.c [NET] BLUETOOTH: Use cpu_to_le{16,32}() where appropriate. 2007-04-25 22:23:54 -07:00
hci_core.c [NET]: cleanup extra semicolons 2007-04-25 22:29:24 -07:00
hci_event.c [NET] BLUETOOTH: Use cpu_to_le{16,32}() where appropriate. 2007-04-25 22:23:54 -07:00
hci_sock.c [BLUETOOTH]: Fix locking in hci_sock_dev_event(). 2007-05-17 14:20:30 -07:00
hci_sysfs.c Fix bluetooth HCI sysfs compile 2007-05-07 17:32:08 -07:00
Kconfig [S390] Kconfig: unwanted menus for s390. 2007-05-10 15:46:07 +02:00
l2cap.c [Bluetooth] Fix L2CAP and HCI setsockopt() information leaks 2007-05-05 00:35:59 +02:00
lib.c [NET] BLUETOOTH: Fix whitespace errors. 2007-02-10 23:19:20 -08:00
Makefile Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sco.c [NET]: cleanup extra semicolons 2007-04-25 22:29:24 -07:00