[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>
This commit is contained in:
Bjorn Helgaas
2006-03-25 03:07:19 -08:00
committed by Linus Torvalds
parent e51c01b084
commit c2f6fabb2e
3 changed files with 20 additions and 21 deletions

View File

@@ -135,13 +135,8 @@ struct bus_type eisa_bus_type = {
int eisa_driver_register (struct eisa_driver *edrv)
{
int r;
edrv->driver.bus = &eisa_bus_type;
if ((r = driver_register (&edrv->driver)) < 0)
return r;
return 0;
return driver_register (&edrv->driver);
}
void eisa_driver_unregister (struct eisa_driver *edrv)