aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wan
diff options
context:
space:
mode:
authorandrew hendry <andrew.hendry@gmail.com>2010-04-19 09:30:13 -0400
committerDavid S. Miller <davem@davemloft.net>2010-04-22 19:12:50 -0400
commit5d74731437b8c8914d2d2956c497c66af3bd6a52 (patch)
tree88c246b39a51d77cf631a4a34c3a4bffcbcaf5f8 /drivers/net/wan
parent4d99503e0b28edf654ca1918229a317a3f738f08 (diff)
X25: Use identifiers for cyclades device to x25 interface
Change magic numbers to identifiers for X25 interface. Signed-off-by: Andrew Hendry <andrew.hendry@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wan')
-rw-r--r--drivers/net/wan/cycx_x25.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/net/wan/cycx_x25.c b/drivers/net/wan/cycx_x25.c
index cd8cb95c5bd7..cf9e15fd8d91 100644
--- a/drivers/net/wan/cycx_x25.c
+++ b/drivers/net/wan/cycx_x25.c
@@ -634,11 +634,12 @@ static netdev_tx_t cycx_netdevice_hard_start_xmit(struct sk_buff *skb,
634 } 634 }
635 } else { /* chan->protocol == ETH_P_X25 */ 635 } else { /* chan->protocol == ETH_P_X25 */
636 switch (skb->data[0]) { 636 switch (skb->data[0]) {
637 case 0: break; 637 case X25_IFACE_DATA:
638 case 1: /* Connect request */ 638 break;
639 case X25_IFACE_CONNECT:
639 cycx_x25_chan_connect(dev); 640 cycx_x25_chan_connect(dev);
640 goto free_packet; 641 goto free_packet;
641 case 2: /* Disconnect request */ 642 case X25_IFACE_DISCONNECT:
642 cycx_x25_chan_disconnect(dev); 643 cycx_x25_chan_disconnect(dev);
643 goto free_packet; 644 goto free_packet;
644 default: 645 default:
@@ -1406,7 +1407,8 @@ static void cycx_x25_set_chan_state(struct net_device *dev, u8 state)
1406 reset_timer(dev); 1407 reset_timer(dev);
1407 1408
1408 if (chan->protocol == ETH_P_X25) 1409 if (chan->protocol == ETH_P_X25)
1409 cycx_x25_chan_send_event(dev, 1); 1410 cycx_x25_chan_send_event(dev,
1411 X25_IFACE_CONNECT);
1410 1412
1411 break; 1413 break;
1412 case WAN_CONNECTING: 1414 case WAN_CONNECTING:
@@ -1424,7 +1426,8 @@ static void cycx_x25_set_chan_state(struct net_device *dev, u8 state)
1424 } 1426 }
1425 1427
1426 if (chan->protocol == ETH_P_X25) 1428 if (chan->protocol == ETH_P_X25)
1427 cycx_x25_chan_send_event(dev, 2); 1429 cycx_x25_chan_send_event(dev,
1430 X25_IFACE_DISCONNECT);
1428 1431
1429 netif_wake_queue(dev); 1432 netif_wake_queue(dev);
1430 break; 1433 break;