Merge branch 'halasa-hdlc' of git://git.tuxdriver.com/git/netdev-jwl
This commit is contained in:
@@ -192,7 +192,9 @@ static int cisco_rx(struct sk_buff *skb)
|
|||||||
"uptime %ud%uh%um%us)\n",
|
"uptime %ud%uh%um%us)\n",
|
||||||
dev->name, days, hrs,
|
dev->name, days, hrs,
|
||||||
min, sec);
|
min, sec);
|
||||||
|
#if 0
|
||||||
netif_carrier_on(dev);
|
netif_carrier_on(dev);
|
||||||
|
#endif
|
||||||
hdlc->state.cisco.up = 1;
|
hdlc->state.cisco.up = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -225,7 +227,9 @@ static void cisco_timer(unsigned long arg)
|
|||||||
hdlc->state.cisco.settings.timeout * HZ)) {
|
hdlc->state.cisco.settings.timeout * HZ)) {
|
||||||
hdlc->state.cisco.up = 0;
|
hdlc->state.cisco.up = 0;
|
||||||
printk(KERN_INFO "%s: Link down\n", dev->name);
|
printk(KERN_INFO "%s: Link down\n", dev->name);
|
||||||
|
#if 0
|
||||||
netif_carrier_off(dev);
|
netif_carrier_off(dev);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
cisco_keepalive_send(dev, CISCO_KEEPALIVE_REQ,
|
cisco_keepalive_send(dev, CISCO_KEEPALIVE_REQ,
|
||||||
@@ -261,8 +265,10 @@ static void cisco_stop(struct net_device *dev)
|
|||||||
{
|
{
|
||||||
hdlc_device *hdlc = dev_to_hdlc(dev);
|
hdlc_device *hdlc = dev_to_hdlc(dev);
|
||||||
del_timer_sync(&hdlc->state.cisco.timer);
|
del_timer_sync(&hdlc->state.cisco.timer);
|
||||||
|
#if 0
|
||||||
if (netif_carrier_ok(dev))
|
if (netif_carrier_ok(dev))
|
||||||
netif_carrier_off(dev);
|
netif_carrier_off(dev);
|
||||||
|
#endif
|
||||||
hdlc->state.cisco.up = 0;
|
hdlc->state.cisco.up = 0;
|
||||||
hdlc->state.cisco.request_sent = 0;
|
hdlc->state.cisco.request_sent = 0;
|
||||||
}
|
}
|
||||||
|
@@ -545,8 +545,10 @@ static void fr_set_link_state(int reliable, struct net_device *dev)
|
|||||||
|
|
||||||
hdlc->state.fr.reliable = reliable;
|
hdlc->state.fr.reliable = reliable;
|
||||||
if (reliable) {
|
if (reliable) {
|
||||||
|
#if 0
|
||||||
if (!netif_carrier_ok(dev))
|
if (!netif_carrier_ok(dev))
|
||||||
netif_carrier_on(dev);
|
netif_carrier_on(dev);
|
||||||
|
#endif
|
||||||
|
|
||||||
hdlc->state.fr.n391cnt = 0; /* Request full status */
|
hdlc->state.fr.n391cnt = 0; /* Request full status */
|
||||||
hdlc->state.fr.dce_changed = 1;
|
hdlc->state.fr.dce_changed = 1;
|
||||||
@@ -560,8 +562,10 @@ static void fr_set_link_state(int reliable, struct net_device *dev)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
#if 0
|
||||||
if (netif_carrier_ok(dev))
|
if (netif_carrier_ok(dev))
|
||||||
netif_carrier_off(dev);
|
netif_carrier_off(dev);
|
||||||
|
#endif
|
||||||
|
|
||||||
while (pvc) { /* Deactivate all PVCs */
|
while (pvc) { /* Deactivate all PVCs */
|
||||||
pvc_carrier(0, pvc);
|
pvc_carrier(0, pvc);
|
||||||
|
@@ -79,11 +79,13 @@ static void __hdlc_set_carrier_on(struct net_device *dev)
|
|||||||
hdlc_device *hdlc = dev_to_hdlc(dev);
|
hdlc_device *hdlc = dev_to_hdlc(dev);
|
||||||
if (hdlc->proto.start)
|
if (hdlc->proto.start)
|
||||||
return hdlc->proto.start(dev);
|
return hdlc->proto.start(dev);
|
||||||
|
#if 0
|
||||||
#ifdef DEBUG_LINK
|
#ifdef DEBUG_LINK
|
||||||
if (netif_carrier_ok(dev))
|
if (netif_carrier_ok(dev))
|
||||||
printk(KERN_ERR "hdlc_set_carrier_on(): already on\n");
|
printk(KERN_ERR "hdlc_set_carrier_on(): already on\n");
|
||||||
#endif
|
#endif
|
||||||
netif_carrier_on(dev);
|
netif_carrier_on(dev);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -94,11 +96,13 @@ static void __hdlc_set_carrier_off(struct net_device *dev)
|
|||||||
if (hdlc->proto.stop)
|
if (hdlc->proto.stop)
|
||||||
return hdlc->proto.stop(dev);
|
return hdlc->proto.stop(dev);
|
||||||
|
|
||||||
|
#if 0
|
||||||
#ifdef DEBUG_LINK
|
#ifdef DEBUG_LINK
|
||||||
if (!netif_carrier_ok(dev))
|
if (!netif_carrier_ok(dev))
|
||||||
printk(KERN_ERR "hdlc_set_carrier_off(): already off\n");
|
printk(KERN_ERR "hdlc_set_carrier_off(): already off\n");
|
||||||
#endif
|
#endif
|
||||||
netif_carrier_off(dev);
|
netif_carrier_off(dev);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -294,8 +298,10 @@ int register_hdlc_device(struct net_device *dev)
|
|||||||
if (result != 0)
|
if (result != 0)
|
||||||
return -EIO;
|
return -EIO;
|
||||||
|
|
||||||
|
#if 0
|
||||||
if (netif_carrier_ok(dev))
|
if (netif_carrier_ok(dev))
|
||||||
netif_carrier_off(dev); /* no carrier until DCD goes up */
|
netif_carrier_off(dev); /* no carrier until DCD goes up */
|
||||||
|
#endif
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user