diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2007-05-09 18:01:11 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2007-05-09 18:01:11 -0400 |
commit | 6d208b39c45edee5def6c201fcd51561c5a39828 (patch) | |
tree | 55645d2b6173e3161d12e5c9efdc4bd052b75b56 /drivers/ide/ide.c | |
parent | 5cbf79cdb37be2aa2a1b4fa94144526b14557060 (diff) |
ide: legacy PCI bus order probing fixes
IDE PCI host drivers should register themselves with IDE core only when
IDE driver is built-in, otherwise (IDE driver is modular and thus IDE PCI
host drivers are also modular) the code has no effect and just complicates
the probing.
Fix it by adding new config option CONFIG_IDEPCI_PCIBUS (defined only when
needed and invisible to the user) and covering by #ifdef/#endif the code
in question. It turned out that "ide=reverse" was silently accepted but did
nothing in case when IDE driver was modular, this is fixed now.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide.c')
-rw-r--r-- | drivers/ide/ide.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/ide/ide.c b/drivers/ide/ide.c index 038f2610e734..f2b547ff7722 100644 --- a/drivers/ide/ide.c +++ b/drivers/ide/ide.c | |||
@@ -172,7 +172,7 @@ static int system_bus_speed; /* holds what we think is VESA/PCI bus speed */ | |||
172 | DECLARE_MUTEX(ide_cfg_sem); | 172 | DECLARE_MUTEX(ide_cfg_sem); |
173 | __cacheline_aligned_in_smp DEFINE_SPINLOCK(ide_lock); | 173 | __cacheline_aligned_in_smp DEFINE_SPINLOCK(ide_lock); |
174 | 174 | ||
175 | #ifdef CONFIG_BLK_DEV_IDEPCI | 175 | #ifdef CONFIG_IDEPCI_PCIBUS_ORDER |
176 | static int ide_scan_direction; /* THIS was formerly 2.2.x pci=reverse */ | 176 | static int ide_scan_direction; /* THIS was formerly 2.2.x pci=reverse */ |
177 | #endif | 177 | #endif |
178 | 178 | ||
@@ -1333,13 +1333,13 @@ static int __init ide_setup(char *s) | |||
1333 | return 1; | 1333 | return 1; |
1334 | } | 1334 | } |
1335 | 1335 | ||
1336 | #ifdef CONFIG_BLK_DEV_IDEPCI | 1336 | #ifdef CONFIG_IDEPCI_PCIBUS_ORDER |
1337 | if (!strcmp(s, "ide=reverse")) { | 1337 | if (!strcmp(s, "ide=reverse")) { |
1338 | ide_scan_direction = 1; | 1338 | ide_scan_direction = 1; |
1339 | printk(" : Enabled support for IDE inverse scan order.\n"); | 1339 | printk(" : Enabled support for IDE inverse scan order.\n"); |
1340 | return 1; | 1340 | return 1; |
1341 | } | 1341 | } |
1342 | #endif /* CONFIG_BLK_DEV_IDEPCI */ | 1342 | #endif |
1343 | 1343 | ||
1344 | #ifdef CONFIG_BLK_DEV_IDEACPI | 1344 | #ifdef CONFIG_BLK_DEV_IDEACPI |
1345 | if (!strcmp(s, "ide=noacpi")) { | 1345 | if (!strcmp(s, "ide=noacpi")) { |
@@ -1599,9 +1599,9 @@ extern void __init h8300_ide_init(void); | |||
1599 | */ | 1599 | */ |
1600 | static void __init probe_for_hwifs (void) | 1600 | static void __init probe_for_hwifs (void) |
1601 | { | 1601 | { |
1602 | #ifdef CONFIG_BLK_DEV_IDEPCI | 1602 | #ifdef CONFIG_IDEPCI_PCIBUS_ORDER |
1603 | ide_scan_pcibus(ide_scan_direction); | 1603 | ide_scan_pcibus(ide_scan_direction); |
1604 | #endif /* CONFIG_BLK_DEV_IDEPCI */ | 1604 | #endif |
1605 | 1605 | ||
1606 | #ifdef CONFIG_ETRAX_IDE | 1606 | #ifdef CONFIG_ETRAX_IDE |
1607 | { | 1607 | { |