Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=6855036aa035913bc2bfb31c41576a49f42ecd5f
Commit:     6855036aa035913bc2bfb31c41576a49f42ecd5f
Parent:     82ab1eeceba6705cd5a8815c48eb03af1dada744
Author:     Tejun Heo <[EMAIL PROTECTED]>
AuthorDate: Sat Jan 27 13:47:02 2007 +0100
Committer:  Bartlomiej Zolnierkiewicz <[EMAIL PROTECTED]>
CommitDate: Sat Jan 27 13:47:02 2007 +0100

    ide: unregister idepnp driver on unload
    
    idepnp driver is registered as a pnp driver on ide init but doesn't
    get unregistered on ide unload causing driver list corruption and
    eventually oops.  Fix it.
    
    Signed-off-by: Tejun Heo <[EMAIL PROTECTED]>
    Signed-off-by: Bartlomiej Zolnierkiewicz <[EMAIL PROTECTED]>
---
 drivers/ide/ide-pnp.c |    5 +++++
 drivers/ide/ide.c     |    5 +++++
 2 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/drivers/ide/ide-pnp.c b/drivers/ide/ide-pnp.c
index df7d150..98410ca 100644
--- a/drivers/ide/ide-pnp.c
+++ b/drivers/ide/ide-pnp.c
@@ -73,3 +73,8 @@ void __init pnpide_init(void)
 {
        pnp_register_driver(&idepnp_driver);
 }
+
+void __exit pnpide_exit(void)
+{
+       pnp_unregister_driver(&idepnp_driver);
+}
diff --git a/drivers/ide/ide.c b/drivers/ide/ide.c
index 1689076..3b334af 100644
--- a/drivers/ide/ide.c
+++ b/drivers/ide/ide.c
@@ -1782,6 +1782,7 @@ done:
 }
 
 extern void pnpide_init(void);
+extern void pnpide_exit(void);
 extern void h8300_ide_init(void);
 
 /*
@@ -2094,6 +2095,10 @@ void cleanup_module (void)
        for (index = 0; index < MAX_HWIFS; ++index)
                ide_unregister(index);
 
+#ifdef CONFIG_BLK_DEV_IDEPNP
+       pnpide_exit();
+#endif
+
 #ifdef CONFIG_PROC_FS
        proc_ide_destroy();
 #endif
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to