patch-2.1.37 linux/drivers/net/hdlcdrv.c

Next file: linux/drivers/net/ibmtr.c
Previous file: linux/drivers/net/fmv18x.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.36/linux/drivers/net/hdlcdrv.c linux/drivers/net/hdlcdrv.c
@@ -288,7 +288,7 @@
 	
 	if (!s || s->magic != HDLCDRV_MAGIC) 
 		return;
-	if (set_bit(0, &s->hdlcrx.in_hdlc_rx))
+	if (test_and_set_bit(0, &s->hdlcrx.in_hdlc_rx))
 		return;
 
 	while (!hdlcdrv_hbuf_empty(&s->hdlcrx.hbuf)) {
@@ -387,7 +387,7 @@
 
 	if (!s || s->magic != HDLCDRV_MAGIC) 
 		return;
-	if (set_bit(0, &s->hdlctx.in_hdlc_tx))
+	if (test_and_set_bit(0, &s->hdlctx.in_hdlc_tx))
 		return;
 	for (;;) {
 		if (s->hdlctx.numbits >= 16) {

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov