aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/setup-pci.c
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-07-24 16:53:12 -0400
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-07-24 16:53:12 -0400
commita742d6cf0b37b1a96a1549b1fda0d6b19e0185c2 (patch)
treefef538fa41fdded0b3644d3e39c1a34d667d3f22 /drivers/ide/setup-pci.c
parenta95925a309cd9a2e7f5a5713fd70e0dadb09890c (diff)
ide: move ide_setup_pci_controller() call to ide_setup_pci_device[s]()
There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/setup-pci.c')
-rw-r--r--drivers/ide/setup-pci.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/drivers/ide/setup-pci.c b/drivers/ide/setup-pci.c
index 58f4a95f6f5c..98c663d62b9f 100644
--- a/drivers/ide/setup-pci.c
+++ b/drivers/ide/setup-pci.c
@@ -488,10 +488,6 @@ static int do_ide_setup_pci_device(struct pci_dev *dev,
488{ 488{
489 int pciirq, ret; 489 int pciirq, ret;
490 490
491 ret = ide_setup_pci_controller(dev, d, noisy);
492 if (ret < 0)
493 goto out;
494
495 /* 491 /*
496 * Can we trust the reported IRQ? 492 * Can we trust the reported IRQ?
497 */ 493 */
@@ -534,6 +530,10 @@ int ide_setup_pci_device(struct pci_dev *dev, const struct ide_port_info *d)
534 hw_regs_t hw[4], *hws[] = { NULL, NULL, NULL, NULL }; 530 hw_regs_t hw[4], *hws[] = { NULL, NULL, NULL, NULL };
535 int ret; 531 int ret;
536 532
533 ret = ide_setup_pci_controller(dev, d, 1);
534 if (ret < 0)
535 goto out;
536
537 ret = do_ide_setup_pci_device(dev, d, 1); 537 ret = do_ide_setup_pci_device(dev, d, 1);
538 538
539 if (ret >= 0) { 539 if (ret >= 0) {
@@ -542,7 +542,7 @@ int ide_setup_pci_device(struct pci_dev *dev, const struct ide_port_info *d)
542 542
543 ret = ide_host_add(d, hws, NULL); 543 ret = ide_host_add(d, hws, NULL);
544 } 544 }
545 545out:
546 return ret; 546 return ret;
547} 547}
548EXPORT_SYMBOL_GPL(ide_setup_pci_device); 548EXPORT_SYMBOL_GPL(ide_setup_pci_device);
@@ -555,6 +555,10 @@ int ide_setup_pci_devices(struct pci_dev *dev1, struct pci_dev *dev2,
555 hw_regs_t hw[4], *hws[] = { NULL, NULL, NULL, NULL }; 555 hw_regs_t hw[4], *hws[] = { NULL, NULL, NULL, NULL };
556 556
557 for (i = 0; i < 2; i++) { 557 for (i = 0; i < 2; i++) {
558 ret = ide_setup_pci_controller(pdev[i], d, !i);
559 if (ret < 0)
560 goto out;
561
558 ret = do_ide_setup_pci_device(pdev[i], d, !i); 562 ret = do_ide_setup_pci_device(pdev[i], d, !i);
559 563
560 /* 564 /*