diff options
author | Libor Pechacek <lpechacek@suse.cz> | 2014-04-29 20:38:34 +0200 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2014-05-05 19:25:06 -0700 |
commit | 86aae6c7b577654b7293374973985a153e0c147e (patch) | |
tree | 2bc969c42c78d2fa817c0bdb0d0a85dcf692d075 /net/bluetooth/rfcomm/core.c | |
parent | 22e70786413ed05950207eda7be420c280b776d7 (diff) | |
download | linux-86aae6c7b577654b7293374973985a153e0c147e.tar.bz2 |
Bluetooth: Convert RFCOMM spinlocks into mutexes
Enabling CONFIG_DEBUG_ATOMIC_SLEEP has shown that some rfcomm functions
acquiring spinlocks call sleeping locks further in the chain. Converting
the offending spinlocks into mutexes makes sleeping safe.
Signed-off-by: Libor Pechacek <lpechacek@suse.cz>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/bluetooth/rfcomm/core.c')
-rw-r--r-- | net/bluetooth/rfcomm/core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bluetooth/rfcomm/core.c b/net/bluetooth/rfcomm/core.c index 633cceeb943e..05c609b12a1d 100644 --- a/net/bluetooth/rfcomm/core.c +++ b/net/bluetooth/rfcomm/core.c @@ -307,7 +307,7 @@ struct rfcomm_dlc *rfcomm_dlc_alloc(gfp_t prio) setup_timer(&d->timer, rfcomm_dlc_timeout, (unsigned long)d); skb_queue_head_init(&d->tx_queue); - spin_lock_init(&d->lock); + mutex_init(&d->lock); atomic_set(&d->refcnt, 1); rfcomm_dlc_clear_state(d); |