]> err.no Git - linux-2.6/blobdiff - drivers/ide/arm/bast-ide.c
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394...
[linux-2.6] / drivers / ide / arm / bast-ide.c
index 0e7574c0ee60bcbfa48c75ef8f3843b71c44bac5..ec46c44b061cfaa27342ce31e03ef7a2b9c2f9e4 100644 (file)
 #include <asm/arch/bast-map.h>
 #include <asm/arch/bast-irq.h>
 
-/* list of registered interfaces */
-static ide_hwif_t *ifs[2];
-
-static int __init
-bastide_register(unsigned int base, unsigned int aux, int irq,
-                ide_hwif_t **hwif)
+static int __init bastide_register(unsigned int base, unsigned int aux, int irq)
 {
        ide_hwif_t *hwif;
        hw_regs_t hw;
@@ -46,15 +41,15 @@ bastide_register(unsigned int base, unsigned int aux, int irq,
        hw.io_ports[IDE_CONTROL_OFFSET] = aux + (6 * 0x20);
        hw.irq = irq;
 
-       hwif = ide_deprecated_find_port(hw.io_ports[IDE_DATA_OFFSET]);
+       hwif = ide_find_port(hw.io_ports[IDE_DATA_OFFSET]);
        if (hwif == NULL)
                goto out;
 
        i = hwif->index;
 
        if (hwif->present)
-               ide_unregister(i, 0, 0);
-       else if (!hwif->hold)
+               ide_unregister(i);
+       else
                ide_init_port_data(hwif, i);
 
        ide_init_port_hw(hwif, &hw);
@@ -76,8 +71,9 @@ static int __init bastide_init(void)
 
        printk("BAST: IDE driver, (c) 2003-2004 Simtec Electronics\n");
 
-       bastide_register(BAST_VA_IDEPRI, BAST_VA_IDEPRIAUX, IRQ_IDE0, &ifs[0]);
-       bastide_register(BAST_VA_IDESEC, BAST_VA_IDESECAUX, IRQ_IDE1, &ifs[1]);
+       bastide_register(BAST_VA_IDEPRI, BAST_VA_IDEPRIAUX, IRQ_IDE0);
+       bastide_register(BAST_VA_IDESEC, BAST_VA_IDESECAUX, IRQ_IDE1);
+
        return 0;
 }