Commit cfce0221 authored by Ben Greear's avatar Ben Greear Committed by Jeff Garzik

[VLAN]: Quiet some printks and free devices/groups correctly.

parent 311d2538
...@@ -45,7 +45,7 @@ spinlock_t vlan_group_lock = SPIN_LOCK_UNLOCKED; ...@@ -45,7 +45,7 @@ spinlock_t vlan_group_lock = SPIN_LOCK_UNLOCKED;
static char vlan_fullname[] = "802.1Q VLAN Support"; static char vlan_fullname[] = "802.1Q VLAN Support";
static unsigned int vlan_version = 1; static unsigned int vlan_version = 1;
static unsigned int vlan_release = 7; static unsigned int vlan_release = 8;
static char vlan_copyright[] = "Ben Greear <greearb@candelatech.com>"; static char vlan_copyright[] = "Ben Greear <greearb@candelatech.com>";
static char vlan_buggyright[] = "David S. Miller <davem@redhat.com>"; static char vlan_buggyright[] = "David S. Miller <davem@redhat.com>";
...@@ -257,6 +257,12 @@ static int unregister_vlan_dev(struct net_device *real_dev, ...@@ -257,6 +257,12 @@ static int unregister_vlan_dev(struct net_device *real_dev,
__grp_unhash(grp); __grp_unhash(grp);
spin_unlock_bh(&vlan_group_lock); spin_unlock_bh(&vlan_group_lock);
/* Free the group, after we have removed it
* from the hash.
*/
kfree(grp);
grp = NULL;
ret = 1; ret = 1;
} }
...@@ -627,6 +633,7 @@ static int vlan_device_event(struct notifier_block *unused, unsigned long event, ...@@ -627,6 +633,7 @@ static int vlan_device_event(struct notifier_block *unused, unsigned long event,
ret = unregister_vlan_dev(dev, ret = unregister_vlan_dev(dev,
VLAN_DEV_INFO(vlandev)->vlan_id); VLAN_DEV_INFO(vlandev)->vlan_id);
dev_put(vlandev);
unregister_netdevice(vlandev); unregister_netdevice(vlandev);
/* Group was destroyed? */ /* Group was destroyed? */
......
...@@ -738,7 +738,7 @@ static void vlan_flush_mc_list(struct net_device *dev) ...@@ -738,7 +738,7 @@ static void vlan_flush_mc_list(struct net_device *dev)
while (dmi) { while (dmi) {
dev_mc_delete(dev, dmi->dmi_addr, dmi->dmi_addrlen, 0); dev_mc_delete(dev, dmi->dmi_addr, dmi->dmi_addrlen, 0);
printk(KERN_INFO "%s: del %.2x:%.2x:%.2x:%.2x:%.2x:%.2x mcast address from vlan interface\n", printk(KERN_DEBUG "%s: del %.2x:%.2x:%.2x:%.2x:%.2x:%.2x mcast address from vlan interface\n",
dev->name, dev->name,
dmi->dmi_addr[0], dmi->dmi_addr[0],
dmi->dmi_addr[1], dmi->dmi_addr[1],
...@@ -820,7 +820,7 @@ void vlan_dev_set_multicast_list(struct net_device *vlan_dev) ...@@ -820,7 +820,7 @@ void vlan_dev_set_multicast_list(struct net_device *vlan_dev)
for (dmi = vlan_dev->mc_list; dmi != NULL; dmi = dmi->next) { for (dmi = vlan_dev->mc_list; dmi != NULL; dmi = dmi->next) {
if (vlan_should_add_mc(dmi, VLAN_DEV_INFO(vlan_dev)->old_mc_list)) { if (vlan_should_add_mc(dmi, VLAN_DEV_INFO(vlan_dev)->old_mc_list)) {
dev_mc_add(real_dev, dmi->dmi_addr, dmi->dmi_addrlen, 0); dev_mc_add(real_dev, dmi->dmi_addr, dmi->dmi_addrlen, 0);
printk(KERN_INFO "%s: add %.2x:%.2x:%.2x:%.2x:%.2x:%.2x mcast address to master interface\n", printk(KERN_DEBUG "%s: add %.2x:%.2x:%.2x:%.2x:%.2x:%.2x mcast address to master interface\n",
vlan_dev->name, vlan_dev->name,
dmi->dmi_addr[0], dmi->dmi_addr[0],
dmi->dmi_addr[1], dmi->dmi_addr[1],
...@@ -838,7 +838,7 @@ void vlan_dev_set_multicast_list(struct net_device *vlan_dev) ...@@ -838,7 +838,7 @@ void vlan_dev_set_multicast_list(struct net_device *vlan_dev)
* delete it from the real list on the underlying device. * delete it from the real list on the underlying device.
*/ */
dev_mc_delete(real_dev, dmi->dmi_addr, dmi->dmi_addrlen, 0); dev_mc_delete(real_dev, dmi->dmi_addr, dmi->dmi_addrlen, 0);
printk(KERN_INFO "%s: del %.2x:%.2x:%.2x:%.2x:%.2x:%.2x mcast address from master interface\n", printk(KERN_DEBUG "%s: del %.2x:%.2x:%.2x:%.2x:%.2x:%.2x mcast address from master interface\n",
vlan_dev->name, vlan_dev->name,
dmi->dmi_addr[0], dmi->dmi_addr[0],
dmi->dmi_addr[1], dmi->dmi_addr[1],
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment