* [PATCH 2.5.70] tulip/xircom initialization bug
@ 2003-06-04 18:21 Stephen Hemminger
2003-06-05 4:17 ` David S. Miller
0 siblings, 1 reply; 2+ messages in thread
From: Stephen Hemminger @ 2003-06-04 18:21 UTC (permalink / raw)
To: David S. Miller, Jeff Garzik; +Cc: netdev
By inspection of device initialization code, this driver unregister's the net device
in the error path even though the register_netdevice never succeeded.
Compiles, but don't have the hardware.
diff -Nru a/drivers/net/tulip/xircom_tulip_cb.c b/drivers/net/tulip/xircom_tulip_cb.c
--- a/drivers/net/tulip/xircom_tulip_cb.c Wed Jun 4 11:18:44 2003
+++ b/drivers/net/tulip/xircom_tulip_cb.c Wed Jun 4 11:18:44 2003
@@ -648,7 +648,6 @@
pci_set_drvdata(pdev, NULL);
pci_release_regions(pdev);
err_out_free_netdev:
- unregister_netdev(dev);
kfree(dev);
return -ENODEV;
}
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH 2.5.70] tulip/xircom initialization bug
2003-06-04 18:21 [PATCH 2.5.70] tulip/xircom initialization bug Stephen Hemminger
@ 2003-06-05 4:17 ` David S. Miller
0 siblings, 0 replies; 2+ messages in thread
From: David S. Miller @ 2003-06-05 4:17 UTC (permalink / raw)
To: shemminger; +Cc: jgarzik, netdev
From: Stephen Hemminger <shemminger@osdl.org>
Date: Wed, 4 Jun 2003 11:21:36 -0700
By inspection of device initialization code, this driver
unregister's the net device in the error path even though the
register_netdevice never succeeded.
This is fully legal, unregister_netdevice() checks for existence of
the netdev in the device list and if not found it returns an error.
This severely simplifies error path handling while we convert all
these drivers away from init_etherdev().
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-06-05 4:17 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-06-04 18:21 [PATCH 2.5.70] tulip/xircom initialization bug Stephen Hemminger
2003-06-05 4:17 ` David S. Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).