Skip to contentSkip to conversation

remove now unneeded references to sk_protinfo

PATCH In review Arnaldo Carvalho de Melo 2 participants 2 messages Mar 19, 2005

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

PATCH 1/1 remove now unneeded references to sk_protinfo

Hi David, Marcel,

Please apply this patch, now only the HAM radio protocols
and af_wanpipe uses sk_protinfo.

Available at:

bk://kernel.bkbits.net/acme/connection_sock-2.6

- Arnaldo

===================================================================

[email protected], 2005-03-19 14:41:18-03:00, [email protected]
[BLUETOOTH] remove now unneeded references to sk_protinfo

Now that sk_protinfo is not used anymore for storing private proto state, we can safely remove the code in the sock destruct path to kfree it.

 l2cap.c       |    3 ---
 rfcomm/sock.c |    3 ---
 sco.c         |    3 ---
 3 files changed, 9 deletions(-)
net/bluetooth/l2cap.c +0 -3
diff -Nru a/net/bluetooth/l2cap.c b/net/bluetooth/l2cap.c
@@ -264,9 +264,6 @@
 
 	skb_queue_purge(&sk->sk_receive_queue);
 	skb_queue_purge(&sk->sk_write_queue);
-
-	if (sk->sk_protinfo)
-		kfree(sk->sk_protinfo);
 }
 
 static void l2cap_sock_cleanup_listen(struct sock *parent)
net/bluetooth/rfcomm/sock.c +0 -3
diff -Nru a/net/bluetooth/rfcomm/sock.c b/net/bluetooth/rfcomm/sock.c
@@ -196,9 +196,6 @@
 	rfcomm_dlc_unlock(d);
 
 	rfcomm_dlc_put(d);
-
-	if (sk->sk_protinfo)
-		kfree(sk->sk_protinfo);
 }
 
 static void rfcomm_sock_cleanup_listen(struct sock *parent)
net/bluetooth/sco.c +0 -3
diff -Nru a/net/bluetooth/sco.c b/net/bluetooth/sco.c
@@ -334,9 +334,6 @@
 
 	skb_queue_purge(&sk->sk_receive_queue);
 	skb_queue_purge(&sk->sk_write_queue);
-
-	if (sk->sk_protinfo)
-		kfree(sk->sk_protinfo);
 }
 
 static void sco_sock_cleanup_listen(struct sock *parent)
maintainer
#1 lore raw

Hi Arnaldo,

Quoted 6 lines

Please apply this patch, now only the HAM radio protocols
and af_wanpipe uses sk_protinfo.

Available at:

bk://kernel.bkbits.net/acme/connection_sock-2.6

patch is in my tree now and I will send it to Dave with fixes for some other race conditions very soon. One of them needs some extra testing.

Regards

Marcel