patch-2.3.47 linux/drivers/net/hamradio/baycom_epp.c

Next file: linux/drivers/net/hamradio/baycom_par.c
Previous file: linux/drivers/net/hamradio/6pack.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.46/linux/drivers/net/hamradio/baycom_epp.c linux/drivers/net/hamradio/baycom_epp.c
@@ -1275,7 +1275,7 @@
 		break;
 
 	case HDLCDRVCTL_SETMODEMPAR:
-		if ((!suser()) || test_bit(LINK_STATE_START, &dev->state))
+		if ((!suser()) || netif_running(dev))
 			return -EACCES;
 		dev->base_addr = hi.data.mp.iobase;
 		dev->irq = /*hi.data.mp.irq*/0;
@@ -1314,7 +1314,7 @@
 		break;
 
 	case HDLCDRVCTL_SETMODE:
-		if (!suser() || test_bit(LINK_STATE_START, &dev->state))
+		if (!suser() || netif_running(dev))
 			return -EACCES;
 		hi.data.modename[sizeof(hi.data.modename)-1] = '\0';
 		return baycom_setmode(bc, hi.data.modename);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)