[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:

committed by
Linus Torvalds

parent
e51c01b084
commit
c2f6fabb2e
@@ -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)
|
||||
|
Reference in New Issue
Block a user