Commit 22a4bcc2 authored by Bartlomiej Zolnierkiewicz's avatar Bartlomiej Zolnierkiewicz Committed by Ben Collins

[PATCH] fix /proc/ide/<hwif> for IDE PCI modules

From: Andrey Borzenkov <arvidjaar@mail.ru>

Also add dummy create_proc_ide_interfaces()
for CONFIG_PROC_FS=n (per Linus' suggestion).
parent 5cdb4c53
......@@ -22,9 +22,8 @@ static int __init ide_generic_init(void)
if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET])
ide_release_lock(); /* for atari only */
#ifdef CONFIG_PROC_FS
create_proc_ide_interfaces();
#endif
return 0;
}
......
......@@ -995,9 +995,7 @@ int ide_register_hw (hw_regs_t *hw, ide_hwif_t **hwifp)
if (!initializing) {
probe_hwif_init(hwif);
#ifdef CONFIG_PROC_FS
create_proc_ide_interfaces();
#endif
}
if (hwifp)
......
......@@ -749,6 +749,8 @@ void ide_setup_pci_device (struct pci_dev *dev, ide_pci_device_t *d)
probe_hwif_init(&ide_hwifs[index_list.b.low]);
if ((index_list.b.high & 0xf0) != 0xf0)
probe_hwif_init(&ide_hwifs[index_list.b.high]);
create_proc_ide_interfaces();
}
EXPORT_SYMBOL_GPL(ide_setup_pci_device);
......@@ -766,6 +768,8 @@ void ide_setup_pci_devices (struct pci_dev *dev, struct pci_dev *dev2, ide_pci_d
probe_hwif_init(&ide_hwifs[index_list2.b.low]);
if ((index_list2.b.high & 0xf0) != 0xf0)
probe_hwif_init(&ide_hwifs[index_list2.b.high]);
create_proc_ide_interfaces();
}
EXPORT_SYMBOL_GPL(ide_setup_pci_devices);
......
......@@ -1119,6 +1119,7 @@ void ide_pci_create_host_proc(const char *, get_info_t *);
return len; \
}
#else
static inline void create_proc_ide_interfaces(void) { ; }
#define PROC_IDE_READ_RETURN(page,start,off,count,eof,len) return 0;
#endif
......
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