diff options
author | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-05-10 09:33:58 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-05-11 09:36:15 -0400 |
commit | ad2fa42d044b98469449880474a9662fb689f7f9 (patch) | |
tree | d016ba7ce9600cb80168be9c23ee447b491fb071 /drivers/scsi/aha152x.c | |
parent | c8611f975403dd20e6503aff8aded5dcb718f75b (diff) |
[SCSI] aha152x: fix init suspiciously returned 1, it should follow 0/-E convention
Reported-by: Frank de Jong <frapex@xs4all.nl>
> [1.] One line summary of the problem:
> linux-2.6.25.3, aha152x'->init suspiciously returned 1, it should
> follow 0/-E convention. The module / driver works okay. Unloading the
> module is impossible.
The driver is apparently returning 0 on failure and 1 on success.
That's a bit unfortunate. Fix it by altering to -ENODEV and 0.
Cc: Stable Tree <stable@kernel.org>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/aha152x.c')
-rw-r--r-- | drivers/scsi/aha152x.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/scsi/aha152x.c b/drivers/scsi/aha152x.c index f5215fd4b73d..f0c4ffceabbe 100644 --- a/drivers/scsi/aha152x.c +++ b/drivers/scsi/aha152x.c | |||
@@ -3830,7 +3830,7 @@ static int __init aha152x_init(void) | |||
3830 | iounmap(p); | 3830 | iounmap(p); |
3831 | } | 3831 | } |
3832 | if (!ok && setup_count == 0) | 3832 | if (!ok && setup_count == 0) |
3833 | return 0; | 3833 | return -ENODEV; |
3834 | 3834 | ||
3835 | printk(KERN_INFO "aha152x: BIOS test: passed, "); | 3835 | printk(KERN_INFO "aha152x: BIOS test: passed, "); |
3836 | #else | 3836 | #else |
@@ -3909,7 +3909,7 @@ static int __init aha152x_init(void) | |||
3909 | #endif | 3909 | #endif |
3910 | } | 3910 | } |
3911 | 3911 | ||
3912 | return 1; | 3912 | return 0; |
3913 | } | 3913 | } |
3914 | 3914 | ||
3915 | static void __exit aha152x_exit(void) | 3915 | static void __exit aha152x_exit(void) |