patch-1.3.77 linux/net/ax25/ax25_subr.c

Next file: linux/net/core/datagram.c
Previous file: linux/net/ax25/ax25_in.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.76/linux/net/ax25/ax25_subr.c linux/net/ax25/ax25_subr.c
@@ -215,7 +215,7 @@
 
 	if (ax25->sk != NULL) {
 		skb->sk = ax25->sk;
-        	ax25->sk->wmem_alloc += skb->truesize;
+		atomic_add(skb->truesize, &ax25->sk->wmem_alloc);
 	}
 
 	/* Assume a response - address structure for DTE */
@@ -498,7 +498,7 @@
 
 	if (ax25->sk != NULL) {
 		skb->sk = ax25->sk;
-		ax25->sk->wmem_alloc += skb->truesize;
+		atomic_add(skb->truesize, &ax25->sk->wmem_alloc);
 	}
 
 	skb->protocol = htons(ETH_P_AX25);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this