diff options
author | Krzysztof Halasa <khc@pm.waw.pl> | 2005-11-10 19:10:30 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2005-11-16 14:11:11 -0500 |
commit | 1f7bad72c0ed8cf29d13bac81ceeba9e1ac05c66 (patch) | |
tree | d4c59ecdeb6b75cb71d852b4ee4c9c5c8cecee50 /drivers/net/wan/hdlc_generic.c | |
parent | cd52d1ee9a92587b242d946a2300a3245d3b885a (diff) |
[PATCH] Generic HDLC WAN drivers - disable netif_carrier_off()
As we are currently unable to fix the problem with carrier and protocol
state signaling in net core I've to disable netif_carrier_off()
calls used by WAN protocol drivers. The attached patch should make
them working again.
The remaining netif_carrier_*() calls in hdlc_fr.c are fine as they
don't touch the physical device.
Signed-off-by: Krzysztof Halasa <khc@pm.waw.pl>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wan/hdlc_generic.c')
-rw-r--r-- | drivers/net/wan/hdlc_generic.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/wan/hdlc_generic.c b/drivers/net/wan/hdlc_generic.c index cdd4c09c2d90..46cef8f92133 100644 --- a/drivers/net/wan/hdlc_generic.c +++ b/drivers/net/wan/hdlc_generic.c | |||
@@ -79,11 +79,13 @@ static void __hdlc_set_carrier_on(struct net_device *dev) | |||
79 | hdlc_device *hdlc = dev_to_hdlc(dev); | 79 | hdlc_device *hdlc = dev_to_hdlc(dev); |
80 | if (hdlc->proto.start) | 80 | if (hdlc->proto.start) |
81 | return hdlc->proto.start(dev); | 81 | return hdlc->proto.start(dev); |
82 | #if 0 | ||
82 | #ifdef DEBUG_LINK | 83 | #ifdef DEBUG_LINK |
83 | if (netif_carrier_ok(dev)) | 84 | if (netif_carrier_ok(dev)) |
84 | printk(KERN_ERR "hdlc_set_carrier_on(): already on\n"); | 85 | printk(KERN_ERR "hdlc_set_carrier_on(): already on\n"); |
85 | #endif | 86 | #endif |
86 | netif_carrier_on(dev); | 87 | netif_carrier_on(dev); |
88 | #endif | ||
87 | } | 89 | } |
88 | 90 | ||
89 | 91 | ||
@@ -94,11 +96,13 @@ static void __hdlc_set_carrier_off(struct net_device *dev) | |||
94 | if (hdlc->proto.stop) | 96 | if (hdlc->proto.stop) |
95 | return hdlc->proto.stop(dev); | 97 | return hdlc->proto.stop(dev); |
96 | 98 | ||
99 | #if 0 | ||
97 | #ifdef DEBUG_LINK | 100 | #ifdef DEBUG_LINK |
98 | if (!netif_carrier_ok(dev)) | 101 | if (!netif_carrier_ok(dev)) |
99 | printk(KERN_ERR "hdlc_set_carrier_off(): already off\n"); | 102 | printk(KERN_ERR "hdlc_set_carrier_off(): already off\n"); |
100 | #endif | 103 | #endif |
101 | netif_carrier_off(dev); | 104 | netif_carrier_off(dev); |
105 | #endif | ||
102 | } | 106 | } |
103 | 107 | ||
104 | 108 | ||
@@ -294,8 +298,10 @@ int register_hdlc_device(struct net_device *dev) | |||
294 | if (result != 0) | 298 | if (result != 0) |
295 | return -EIO; | 299 | return -EIO; |
296 | 300 | ||
301 | #if 0 | ||
297 | if (netif_carrier_ok(dev)) | 302 | if (netif_carrier_ok(dev)) |
298 | netif_carrier_off(dev); /* no carrier until DCD goes up */ | 303 | netif_carrier_off(dev); /* no carrier until DCD goes up */ |
304 | #endif | ||
299 | 305 | ||
300 | return 0; | 306 | return 0; |
301 | } | 307 | } |