: Megaraid patch for 2.6 2/5
Subsystems (2)
PATCH 1/1 : Megaraid patch for 2.6 2/5
Hi all,
On Linux-SCSI over the last few days I have been discussing a couple of problems with the 2.6.2 megaraid driver. This patch fixes the problem that the /proc files were being created in the wrong place, the reason for this is that the /proc/megaraid directory was being created too late, so it has been moved earlier in the initialisation sequence. There has been one comment made about the #ifdef CONFIG_PROC_FS not being needed, but if they are removed then I would also need to remove the error when we can't create it, since it always "fails" to create a proc entry when CONFIG_PROC_FS is not set. Please let me know if you would like this re-submitted.
patch is attached and below.
drivers/scsi/megaraid.c +7 -4
@@ -5119,10 +5119,6 @@if (max_mbox_busy_wait >MBOX_BUSY_WAIT ) max_mbox_busy_wait =MBOX_BUSY_WAIT ; - error =pci_module_init (&megaraid_pci_driver); -if (error) -return error; -#ifdef CONFIG_PROC_FS mega_proc_dir_entry =proc_mkdir ("megaraid" , &proc_root);if (!mega_proc_dir_entry) {
@@ -5130,6 +5126,13 @@ "megaraid: failed to create megaraid root\n"); }#endif + error =pci_module_init (&megaraid_pci_driver); +if (error) { +#ifdef CONFIG_PROC_FS +remove_proc_entry ("megaraid" , &proc_root); +#endif +return error; + }/* * Register the driver as a character device, for applications
drivers/scsi/megaraid.c +7 -4
@@ -5119,10 +5119,6 @@if (max_mbox_busy_wait >MBOX_BUSY_WAIT ) max_mbox_busy_wait =MBOX_BUSY_WAIT ; - error =pci_module_init (&megaraid_pci_driver); -if (error) -return error; -#ifdef CONFIG_PROC_FS mega_proc_dir_entry =proc_mkdir ("megaraid" , &proc_root);if (!mega_proc_dir_entry) {
@@ -5130,6 +5126,13 @@ "megaraid: failed to create megaraid root\n"); }#endif + error =pci_module_init (&megaraid_pci_driver); +if (error) { +#ifdef CONFIG_PROC_FS +remove_proc_entry ("megaraid" , &proc_root); +#endif +return error; + }/* * Register the driver as a character device, for applications