aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/arm/rapide.c
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2007-10-19 18:32:31 -0400
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2007-10-19 18:32:31 -0400
commit8447d9d52adbe4c653482bd0d5ccb9b5d26f9c9d (patch)
tree358aa3ca6b0657623b84e7c6278f90fc95a32879 /drivers/ide/arm/rapide.c
parentfd9bb53942a7ca3398a63f2c238afd8fbed3ec0e (diff)
ide: add ide_device_add()
* Add ide_device_add() helper and convert host drivers to use it instead of open-coded variants. * Make ide_pci_setup_ports() and do_ide_setup_pci_device() take 'u8 *idx' argument instead of 'ata_index_t *index'. * Remove no longer needed ata_index_t. * Unexport probe_hwif_init() and make it static. * Unexport ide_proc_register_port(). There should be no functionality changes caused by this patch (sgiioc4.c: ide_proc_register_port() requires hwif->present to be set and it won't be set if probe_hwif_init() fails). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/arm/rapide.c')
-rw-r--r--drivers/ide/arm/rapide.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/ide/arm/rapide.c b/drivers/ide/arm/rapide.c
index 83811af11610..6d2fe21cd729 100644
--- a/drivers/ide/arm/rapide.c
+++ b/drivers/ide/arm/rapide.c
@@ -58,6 +58,7 @@ rapide_probe(struct expansion_card *ec, const struct ecard_id *id)
58 ide_hwif_t *hwif; 58 ide_hwif_t *hwif;
59 void __iomem *base; 59 void __iomem *base;
60 int ret; 60 int ret;
61 u8 idx[4] = { 0xff, 0xff, 0xff, 0xff };
61 62
62 ret = ecard_request_resources(ec); 63 ret = ecard_request_resources(ec);
63 if (ret) 64 if (ret)
@@ -74,8 +75,11 @@ rapide_probe(struct expansion_card *ec, const struct ecard_id *id)
74 hwif->hwif_data = base; 75 hwif->hwif_data = base;
75 hwif->gendev.parent = &ec->dev; 76 hwif->gendev.parent = &ec->dev;
76 hwif->noprobe = 0; 77 hwif->noprobe = 0;
77 probe_hwif_init(hwif); 78
78 ide_proc_register_port(hwif); 79 idx[0] = hwif->index;
80
81 ide_device_add(idx);
82
79 ecard_set_drvdata(ec, hwif); 83 ecard_set_drvdata(ec, hwif);
80 goto out; 84 goto out;
81 } 85 }