diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-07-08 13:27:22 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-07-08 13:27:22 -0400 |
commit | a861beb1401d65e3f095fee074c13645ab06490e (patch) | |
tree | a464f863ddd8421bdfe6a05fdfcb56da33c0b9e7 /drivers/ide/ide-probe.c | |
parent | 86df86424939d316b1f6cfac1b6204f0c7dee317 (diff) |
ide: add __ide_default_irq() inline helper
Add __ide_default_irq() inline helper and use it instead of
ide_default_irq() in ide-probe.c and ns87415.c (all host drivers
except IDE PCI ones always setup hwif->irq so it is enough to
check only for I/O bases 0x1f0 and 0x170).
This fixes post-2.6.25 regression since ide_default_irq()
define could shadow ide_default_irq() inline.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-probe.c')
-rw-r--r-- | drivers/ide/ide-probe.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c index d27061b39324..26e68b65b7cf 100644 --- a/drivers/ide/ide-probe.c +++ b/drivers/ide/ide-probe.c | |||
@@ -1218,16 +1218,12 @@ static void drive_release_dev (struct device *dev) | |||
1218 | complete(&drive->gendev_rel_comp); | 1218 | complete(&drive->gendev_rel_comp); |
1219 | } | 1219 | } |
1220 | 1220 | ||
1221 | #ifndef ide_default_irq | ||
1222 | #define ide_default_irq(irq) 0 | ||
1223 | #endif | ||
1224 | |||
1225 | static int hwif_init(ide_hwif_t *hwif) | 1221 | static int hwif_init(ide_hwif_t *hwif) |
1226 | { | 1222 | { |
1227 | int old_irq; | 1223 | int old_irq; |
1228 | 1224 | ||
1229 | if (!hwif->irq) { | 1225 | if (!hwif->irq) { |
1230 | hwif->irq = ide_default_irq(hwif->io_ports.data_addr); | 1226 | hwif->irq = __ide_default_irq(hwif->io_ports.data_addr); |
1231 | if (!hwif->irq) { | 1227 | if (!hwif->irq) { |
1232 | printk("%s: DISABLED, NO IRQ\n", hwif->name); | 1228 | printk("%s: DISABLED, NO IRQ\n", hwif->name); |
1233 | return 0; | 1229 | return 0; |
@@ -1257,7 +1253,7 @@ static int hwif_init(ide_hwif_t *hwif) | |||
1257 | * It failed to initialise. Find the default IRQ for | 1253 | * It failed to initialise. Find the default IRQ for |
1258 | * this port and try that. | 1254 | * this port and try that. |
1259 | */ | 1255 | */ |
1260 | hwif->irq = ide_default_irq(hwif->io_ports.data_addr); | 1256 | hwif->irq = __ide_default_irq(hwif->io_ports.data_addr); |
1261 | if (!hwif->irq) { | 1257 | if (!hwif->irq) { |
1262 | printk("%s: Disabled unable to get IRQ %d.\n", | 1258 | printk("%s: Disabled unable to get IRQ %d.\n", |
1263 | hwif->name, old_irq); | 1259 | hwif->name, old_irq); |