aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/3c59x.c
diff options
context:
space:
mode:
authorBjorn Helgaas <bjorn.helgaas@hp.com>2006-03-25 03:07:19 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-25 08:22:53 -0800
commitc2f6fabb2ed3b869bc254c6cdc73d6beaaaf700f (patch)
tree8744d970a801a64ac3cb64f47e735dc3d33c44b9 /drivers/net/3c59x.c
parente51c01b08474ea454a965a937fff0407ab6714c7 (diff)
[PATCH] EISA: tidy-up driver_register() return value
Remove the assumption that driver_register() returns the number of devices bound to the driver. In fact, it returns zero for success or a negative error value. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Acked-by: Jeff Garzik <jgarzik@pobox.com> Acked-by: Marc Zyngier <maz@misterjones.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/net/3c59x.c')
-rw-r--r--drivers/net/3c59x.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/drivers/net/3c59x.c b/drivers/net/3c59x.c
index 5d11a06ecb2..d339308539f 100644
--- a/drivers/net/3c59x.c
+++ b/drivers/net/3c59x.c
@@ -1096,14 +1096,18 @@ static int __init vortex_eisa_init (void)
int orig_cards_found = vortex_cards_found;
#ifdef CONFIG_EISA
- if (eisa_driver_register (&vortex_eisa_driver) >= 0) {
- /* Because of the way EISA bus is probed, we cannot assume
- * any device have been found when we exit from
- * eisa_driver_register (the bus root driver may not be
- * initialized yet). So we blindly assume something was
- * found, and let the sysfs magic happend... */
-
- eisa_found = 1;
+ int err;
+
+ err = eisa_driver_register (&vortex_eisa_driver);
+ if (!err) {
+ /*
+ * Because of the way EISA bus is probed, we cannot assume
+ * any device have been found when we exit from
+ * eisa_driver_register (the bus root driver may not be
+ * initialized yet). So we blindly assume something was
+ * found, and let the sysfs magic happend...
+ */
+ eisa_found = 1;
}
#endif