aboutsummaryrefslogtreecommitdiffstats
path: root/net/atm/lec.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/atm/lec.c')
-rw-r--r--net/atm/lec.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/net/atm/lec.c b/net/atm/lec.c
index d98bde1a0ac8..ba48daa68c1f 100644
--- a/net/atm/lec.c
+++ b/net/atm/lec.c
@@ -129,7 +129,6 @@ static struct net_device *dev_lec[MAX_LEC_ITF];
129#if defined(CONFIG_BRIDGE) || defined(CONFIG_BRIDGE_MODULE) 129#if defined(CONFIG_BRIDGE) || defined(CONFIG_BRIDGE_MODULE)
130static void lec_handle_bridge(struct sk_buff *skb, struct net_device *dev) 130static void lec_handle_bridge(struct sk_buff *skb, struct net_device *dev)
131{ 131{
132 struct ethhdr *eth;
133 char *buff; 132 char *buff;
134 struct lec_priv *priv; 133 struct lec_priv *priv;
135 134
@@ -138,7 +137,6 @@ static void lec_handle_bridge(struct sk_buff *skb, struct net_device *dev)
138 * LE_TOPOLOGY_REQUEST with the same value of Topology Change bit 137 * LE_TOPOLOGY_REQUEST with the same value of Topology Change bit
139 * as the Config BPDU has 138 * as the Config BPDU has
140 */ 139 */
141 eth = (struct ethhdr *)skb->data;
142 buff = skb->data + skb->dev->hard_header_len; 140 buff = skb->data + skb->dev->hard_header_len;
143 if (*buff++ == 0x42 && *buff++ == 0x42 && *buff++ == 0x03) { 141 if (*buff++ == 0x42 && *buff++ == 0x42 && *buff++ == 0x03) {
144 struct sock *sk; 142 struct sock *sk;
@@ -220,7 +218,6 @@ static unsigned char *get_tr_dst(unsigned char *packet, unsigned char *rdesc)
220static int lec_open(struct net_device *dev) 218static int lec_open(struct net_device *dev)
221{ 219{
222 netif_start_queue(dev); 220 netif_start_queue(dev);
223 memset(&dev->stats, 0, sizeof(struct net_device_stats));
224 221
225 return 0; 222 return 0;
226} 223}
@@ -817,8 +814,7 @@ static int lec_mcast_attach(struct atm_vcc *vcc, int arg)
817 if (arg < 0 || arg >= MAX_LEC_ITF || !dev_lec[arg]) 814 if (arg < 0 || arg >= MAX_LEC_ITF || !dev_lec[arg])
818 return -EINVAL; 815 return -EINVAL;
819 vcc->proto_data = dev_lec[arg]; 816 vcc->proto_data = dev_lec[arg];
820 return lec_mcast_make((struct lec_priv *)netdev_priv(dev_lec[arg]), 817 return lec_mcast_make(netdev_priv(dev_lec[arg]), vcc);
821 vcc);
822} 818}
823 819
824/* Initialize device. */ 820/* Initialize device. */
@@ -1175,14 +1171,13 @@ static int __init lane_module_init(void)
1175#endif 1171#endif
1176 1172
1177 register_atm_ioctl(&lane_ioctl_ops); 1173 register_atm_ioctl(&lane_ioctl_ops);
1178 pr_info("lec.c: " __DATE__ " " __TIME__ " initialized\n"); 1174 pr_info("lec.c: initialized\n");
1179 return 0; 1175 return 0;
1180} 1176}
1181 1177
1182static void __exit lane_module_cleanup(void) 1178static void __exit lane_module_cleanup(void)
1183{ 1179{
1184 int i; 1180 int i;
1185 struct lec_priv *priv;
1186 1181
1187 remove_proc_entry("lec", atm_proc_root); 1182 remove_proc_entry("lec", atm_proc_root);
1188 1183
@@ -1190,7 +1185,6 @@ static void __exit lane_module_cleanup(void)
1190 1185
1191 for (i = 0; i < MAX_LEC_ITF; i++) { 1186 for (i = 0; i < MAX_LEC_ITF; i++) {
1192 if (dev_lec[i] != NULL) { 1187 if (dev_lec[i] != NULL) {
1193 priv = netdev_priv(dev_lec[i]);
1194 unregister_netdev(dev_lec[i]); 1188 unregister_netdev(dev_lec[i]);
1195 free_netdev(dev_lec[i]); 1189 free_netdev(dev_lec[i]);
1196 dev_lec[i] = NULL; 1190 dev_lec[i] = NULL;
@@ -1609,7 +1603,7 @@ static void lec_arp_destroy(struct lec_priv *priv)
1609 struct lec_arp_table *entry; 1603 struct lec_arp_table *entry;
1610 int i; 1604 int i;
1611 1605
1612 cancel_rearming_delayed_work(&priv->lec_arp_work); 1606 cancel_delayed_work_sync(&priv->lec_arp_work);
1613 1607
1614 /* 1608 /*
1615 * Remove all entries 1609 * Remove all entries