Commit e90d017c authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] Fix megaraid oops on unload

Reported by Wakko Warner.

The megaraid driver is trying to remove a non-empty directory in procfs.

Trivially fixed by first unregistering the driver, which will remove all
the per-controller files in the megaraid directory, and only _then_
removing the megaraid /proc directory entry.
parent ee7ce018
......@@ -5109,11 +5109,11 @@ static void __exit megaraid_exit(void)
*/
unregister_chrdev(major, "megadev");
pci_unregister_driver(&megaraid_pci_driver);
#ifdef CONFIG_PROC_FS
remove_proc_entry("megaraid", &proc_root);
#endif
pci_unregister_driver(&megaraid_pci_driver);
}
module_init(megaraid_init);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment