Skip to content

Commit

Permalink
[PATCH] Char: sx, fix return in module init
Browse files Browse the repository at this point in the history
If pci_register_driver fails, but eisa_driver_register doesn't, we don't call
misc_deregister, but returns error.  Return OK in such cases.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Jiri Slaby authored and Linus Torvalds committed Dec 8, 2006
1 parent c959464 commit 7eb9976
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/char/sx.c
Original file line number Diff line number Diff line change
Expand Up @@ -2791,6 +2791,7 @@ static int __init sx_init(void)
retval = 0;
} else if (retval) {
#ifdef CONFIG_EISA
retval = retval1;
if (retval1)
#endif
misc_deregister(&sx_fw_device);
Expand Down

0 comments on commit 7eb9976

Please sign in to comment.