From 644c12d7f695c0a30662ac781b0f06f79d7f9bab Mon Sep 17 00:00:00 2001 From: Eric Sesterhenn Date: Tue, 3 Oct 2006 23:34:11 +0200 Subject: BUG_ON cleanup in drivers/net/tokenring/ This patch converts one if() BUG(); to BUG_ON(); so it can be safely optimized away. Signed-off-by: Eric Sesterhenn Signed-off-by: Adrian Bunk --- drivers/net/tokenring/tmspci.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'drivers/net') diff --git a/drivers/net/tokenring/tmspci.c b/drivers/net/tokenring/tmspci.c index 7d3e270c4f45..3b2f00b9b7bd 100644 --- a/drivers/net/tokenring/tmspci.c +++ b/drivers/net/tokenring/tmspci.c @@ -224,8 +224,7 @@ static void __devexit tms_pci_detach (struct pci_dev *pdev) { struct net_device *dev = pci_get_drvdata(pdev); - if (!dev) - BUG(); + BUG_ON(!dev); unregister_netdev(dev); release_region(dev->base_addr, TMS_PCI_IO_EXTENT); free_irq(dev->irq, dev); -- cgit v1.2.3