On Thu, Mar 02, 2006 at 03:49:10PM -0800, [email protected] wrote:
...
>
> From: Bjorn Helgaas <[email protected]>
>
> 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 <[email protected]>
> Cc: Jeff Garzik <[email protected]>
> Signed-off-by: Andrew Morton <[email protected]>
...
> diff -puN drivers/net/3c59x.c~eisa-tidy-up-driver_register-return-value drivers/net/3c59x.c
> --- 25/drivers/net/3c59x.c~eisa-tidy-up-driver_register-return-value Thu Mar 2 15:48:23 2006
> +++ 25-akpm/drivers/net/3c59x.c Thu Mar 2 15:48:23 2006
> @@ -1094,9 +1094,11 @@ static int __init vortex_eisa_init (void
> {
> int eisa_found = 0;
> int orig_cards_found = vortex_cards_found;
> + int err;
>
> #ifdef CONFIG_EISA
> - if (eisa_driver_register (&vortex_eisa_driver) >= 0) {
> + 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
This results in
drivers/net/3c59x.c: In function `vortex_eisa_init':
drivers/net/3c59x.c:1091: warning: unused variable `err'
if CONFIG_EISA is not defined.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]