Skip to contentSkip to conversation

bluetooth: replace deprecated RW_LOCK_UNLOCKED macros

PATCH Applied [email protected] 2 participants 2 messages Mar 28, 2008

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 4/4 bluetooth: replace deprecated RW_LOCK_UNLOCKED macros

From: "Robert P. J. Day" <[email protected]>

The older RW_LOCK_UNLOCKED macros defeat lockdep state tracing so replace them with the newer __RW_LOCK_UNLOCKED macros.

---

 net/bluetooth/hci_sock.c    |    2 +-
 net/bluetooth/l2cap.c       |    2 +-
 net/bluetooth/rfcomm/sock.c |    2 +-
 net/bluetooth/sco.c         |    2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)
net/bluetooth/hci_sock.c renamed from net/bluetooth/hci_sock.c~bluetooth-replace-deprecated-rw_lock_unlocked-macros +1 -1
diff -puN net/bluetooth/hci_sock.c~bluetooth-replace-deprecated-rw_lock_unlocked-macros net/bluetooth/hci_sock.c
@@ -84,7 +84,7 @@ static struct hci_sec_filter hci_sec_fil
 };
 
 static struct bt_sock_list hci_sk_list = {
-	.lock = RW_LOCK_UNLOCKED
+	.lock = __RW_LOCK_UNLOCKED(hci_sk_list.lock)
 };
 
 /* Send frame to RAW socket */
net/bluetooth/l2cap.c renamed from net/bluetooth/l2cap.c~bluetooth-replace-deprecated-rw_lock_unlocked-macros +1 -1
diff -puN net/bluetooth/l2cap.c~bluetooth-replace-deprecated-rw_lock_unlocked-macros net/bluetooth/l2cap.c
@@ -62,7 +62,7 @@ static u32 l2cap_feat_mask = 0x0000;
 static const struct proto_ops l2cap_sock_ops;
 
 static struct bt_sock_list l2cap_sk_list = {
-	.lock = RW_LOCK_UNLOCKED
+	.lock = __RW_LOCK_UNLOCKED(l2cap_sk_list.lock)
 };
 
 static void __l2cap_sock_close(struct sock *sk, int reason);
net/bluetooth/rfcomm/sock.c renamed from net/bluetooth/rfcomm/sock.c~bluetooth-replace-deprecated-rw_lock_unlocked-macros +1 -1
diff -puN net/bluetooth/rfcomm/sock.c~bluetooth-replace-deprecated-rw_lock_unlocked-macros net/bluetooth/rfcomm/sock.c
@@ -60,7 +60,7 @@
 static const struct proto_ops rfcomm_sock_ops;
 
 static struct bt_sock_list rfcomm_sk_list = {
-	.lock = RW_LOCK_UNLOCKED
+	.lock = __RW_LOCK_UNLOCKED(rfcomm_sk_list.lock)
 };
 
 static void rfcomm_sock_close(struct sock *sk);
net/bluetooth/sco.c renamed from net/bluetooth/sco.c~bluetooth-replace-deprecated-rw_lock_unlocked-macros +1 -1
diff -puN net/bluetooth/sco.c~bluetooth-replace-deprecated-rw_lock_unlocked-macros net/bluetooth/sco.c
@@ -58,7 +58,7 @@
 static const struct proto_ops sco_sock_ops;
 
 static struct bt_sock_list sco_sk_list = {
-	.lock = RW_LOCK_UNLOCKED
+	.lock = __RW_LOCK_UNLOCKED(sco_sk_list.lock)
 };
 
 static void __sco_chan_add(struct sco_conn *conn, struct sock *sk, struct sock *parent);

_