ide: cleanup setting hwif->mmio flag

It is no longer needed to set hwif->mmio flag to tell IDE layer to not
manage resources so cleanup host drivers that used hwif->mmio flag only
for this purpose.

Ditto for ide_legacy_init_one().

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
This commit is contained in:
Bartlomiej Zolnierkiewicz 2008-04-26 22:25:19 +02:00
parent 5add222417
commit 3dd89a9b2a
23 changed files with 2 additions and 32 deletions

View file

@ -55,7 +55,6 @@ static int __init bastide_register(unsigned int base, unsigned int aux, int irq)
ide_init_port_data(hwif, i);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
hwif->port_ops = NULL;
idx[0] = i;

View file

@ -416,7 +416,6 @@ icside_setup(void __iomem *base, struct cardinfo *info, struct expansion_card *e
* Ensure we're using MMIO
*/
default_hwif_mmiops(hwif);
hwif->mmio = 1;
for (i = IDE_DATA_OFFSET; i <= IDE_STATUS_OFFSET; i++) {
hwif->io_ports[i] = port;

View file

@ -53,7 +53,6 @@ static int __init ide_arm_init(void)
hwif = ide_find_port();
if (hwif) {
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
idx[0] = hwif->index;
ide_device_add(idx, NULL);

View file

@ -53,7 +53,6 @@ rapide_probe(struct expansion_card *ec, const struct ecard_id *id)
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
default_hwif_mmiops(hwif);
idx[0] = hwif->index;

View file

@ -815,7 +815,7 @@ static int __init init_e100_ide(void)
continue;
ide_init_port_data(hwif, hwif->index);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
hwif->ata_input_data = &cris_ide_input_data;
hwif->ata_output_data = &cris_ide_output_data;
hwif->atapi_input_bytes = &cris_atapi_input_bytes;

View file

@ -74,7 +74,6 @@ static inline void hwif_setup(ide_hwif_t *hwif)
{
default_hwif_iops(hwif);
hwif->mmio = 1;
hwif->OUTW = mm_outw;
hwif->OUTSW = mm_outsw;
hwif->INW = mm_inw;

View file

@ -126,7 +126,6 @@ static int __init ide_generic_init(void)
ide_std_init_ports(&hw, io_addr, io_addr + 0x206);
hw.irq = ide_default_irq(io_addr);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
idx[i] = i;
}

View file

@ -63,7 +63,6 @@ static int idepnp_probe(struct pnp_dev *dev, const struct pnp_device_id *dev_id)
ide_init_port_data(hwif, index);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
printk(KERN_INFO "ide%d: generic PnP IDE interface\n", index);
pnp_set_drvdata(dev, hwif);

View file

@ -1661,7 +1661,6 @@ static void ide_legacy_init_one(u8 *idx, hw_regs_t *hw, u8 port_no,
hwif = ide_find_port_slot(d);
if (hwif) {
ide_init_port_hw(hwif, hw);
hwif->mmio = 1;
if (config)
hwif->config_data = config;
idx[port_no] = hwif->index;

View file

@ -228,8 +228,6 @@ fail_base2:
ide_init_port_data(hwif, index);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
idx[i] = index;
}
}

View file

@ -89,7 +89,6 @@ static int __init falconide_init(void)
ide_init_port_data(hwif, index);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
ide_get_lock(NULL, NULL);
ide_device_add(idx, NULL);

View file

@ -182,8 +182,6 @@ found:
ide_init_port_data(hwif, index);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
idx[i] = index;
} else
release_mem_region(res_start, res_n);

View file

@ -43,7 +43,6 @@ static int __init ide_4drives_init(void)
hwif = ide_find_port();
if (hwif) {
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
idx[0] = hwif->index;
}
@ -52,7 +51,6 @@ static int __init ide_4drives_init(void)
ide_init_port_hw(mate, &hw);
mate->drives[0].select.all ^= 0x20;
mate->drives[1].select.all ^= 0x20;
mate->mmio = 1;
idx[1] = mate->index;
if (hwif) {

View file

@ -100,7 +100,6 @@ static int __devinit plat_ide_probe(struct platform_device *pdev)
hw.dev = &pdev->dev;
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
if (mmio)
default_hwif_mmiops(hwif);

View file

@ -128,8 +128,6 @@ static int __init macide_init(void)
ide_init_port_data(hwif, index);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
ide_device_add(idx, NULL);
}

View file

@ -141,7 +141,6 @@ static int __init q40ide_init(void)
if (hwif) {
ide_init_port_data(hwif, hwif->index);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
idx[i] = hwif->index;
}

View file

@ -624,8 +624,6 @@ static int au_ide_probe(struct device *dev)
hwif->dev = dev;
hwif->mmio = 1;
/* If the user has selected DDMA assisted copies,
then set up a few local I/O function entry points
*/

View file

@ -110,8 +110,7 @@ static int __devinit swarm_ide_probe(struct device *dev)
/* Setup MMIO ops. */
default_hwif_mmiops(hwif);
/* Prevent resource map manipulation. */
hwif->mmio = 1;
hwif->chipset = ide_generic;
for (i = IDE_DATA_OFFSET; i <= IDE_STATUS_OFFSET; i++)

View file

@ -787,7 +787,6 @@ static int __init cmd640x_init(void)
*/
if (cmd_hwif0) {
ide_init_port_hw(cmd_hwif0, &hw[0]);
cmd_hwif0->mmio = 1;
idx[0] = cmd_hwif0->index;
}
@ -840,7 +839,6 @@ static int __init cmd640x_init(void)
*/
if (second_port_cmd640 && cmd_hwif1) {
ide_init_port_hw(cmd_hwif1, &hw[1]);
cmd_hwif1->mmio = 1;
idx[1] = cmd_hwif1->index;
}
printk(KERN_INFO "cmd640: %sserialized, secondary interface %s\n",

View file

@ -93,7 +93,6 @@ delkin_cb_probe (struct pci_dev *dev, const struct pci_device_id *id)
ide_init_port_data(hwif, i);
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
hwif->port_ops = &delkin_cb_port_ops;
idx[0] = i;

View file

@ -551,7 +551,6 @@ static int sgiioc4_ide_dma_setup(ide_drive_t *drive)
static void __devinit
ide_init_sgiioc4(ide_hwif_t * hwif)
{
hwif->mmio = 1;
hwif->INB = &sgiioc4_INB;
if (hwif->dma_base == 0)

View file

@ -814,7 +814,6 @@ static int __init mpc8xx_ide_probe(void)
ide_hwif_t *hwif = &ide_hwifs[0];
ide_init_port_hw(hwif, &hw);
hwif->mmio = 1;
hwif->pio_mask = ATA_PIO4;
hwif->port_ops = &m8xx_port_ops;
@ -826,7 +825,6 @@ static int __init mpc8xx_ide_probe(void)
ide_hwif_t *mate = &ide_hwifs[1];
ide_init_port_hw(mate, &hw);
mate->mmio = 1;
mate->pio_mask = ATA_PIO4;
mate->port_ops = &m8xx_port_ops;

View file

@ -1045,8 +1045,6 @@ pmac_ide_setup_device(pmac_ide_hwif_t *pmif, ide_hwif_t *hwif, hw_regs_t *hw)
default_hwif_mmiops(hwif);
hwif->OUTBSYNC = pmac_outbsync;
/* Tell common code _not_ to mess with resources */
hwif->mmio = 1;
hwif->hwif_data = pmif;
ide_init_port_hw(hwif, hw);
hwif->cbl = pmif->cable_80 ? ATA_CBL_PATA80 : ATA_CBL_PATA40;