[PATCH] Char: sx, fix return in module init

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>
This commit is contained in:
Jiri Slaby 2006-12-08 02:39:06 -08:00 committed by Linus Torvalds
parent c9594643c0
commit 7eb9976f10

View file

@ -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);