]> err.no Git - linux-2.6/commitdiff
Revert "atm: Do not free already unregistered net device."
authorDavid S. Miller <davem@davemloft.net>
Tue, 6 May 2008 07:00:16 +0000 (00:00 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 6 May 2008 07:00:16 +0000 (00:00 -0700)
This reverts commit 65e4113684e50cee75357ce10dc9026b0929e4e9.

Unlike the other cases Pavel fixed, this case did not
setup a netdev->destructor of free_netdev, therefore this
change was not correct.

Signed-off-by: David S. Miller <davem@davemloft.net>
net/atm/br2684.c

index 13858e2675c5f57277f031eacece09724bc84cd3..9d52ebfc1962b360774f55e728b32ea0d8388654 100644 (file)
@@ -350,6 +350,7 @@ static void br2684_push(struct atm_vcc *atmvcc, struct sk_buff *skb)
                        list_del(&brdev->br2684_devs);
                        write_unlock_irq(&devs_lock);
                        unregister_netdev(net_dev);
+                       free_netdev(net_dev);
                }
                return;
        }
@@ -770,6 +771,7 @@ static void __exit br2684_exit(void)
 
                list_del(&brdev->br2684_devs);
                unregister_netdev(net_dev);
+               free_netdev(net_dev);
        }
 }