diff options
Diffstat (limited to 'drivers/ata/pata_pcmcia.c')
-rw-r--r-- | drivers/ata/pata_pcmcia.c | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/drivers/ata/pata_pcmcia.c b/drivers/ata/pata_pcmcia.c index 171da0aeb65f..75dc84797ff3 100644 --- a/drivers/ata/pata_pcmcia.c +++ b/drivers/ata/pata_pcmcia.c | |||
@@ -125,7 +125,6 @@ static struct ata_port_operations pcmcia_port_ops = { | |||
125 | 125 | ||
126 | .data_xfer = ata_data_xfer_noirq, | 126 | .data_xfer = ata_data_xfer_noirq, |
127 | 127 | ||
128 | .irq_handler = ata_interrupt, | ||
129 | .irq_clear = ata_bmdma_irq_clear, | 128 | .irq_clear = ata_bmdma_irq_clear, |
130 | .irq_on = ata_irq_on, | 129 | .irq_on = ata_irq_on, |
131 | .irq_ack = ata_irq_ack, | 130 | .irq_ack = ata_irq_ack, |
@@ -146,7 +145,8 @@ do { last_fn = (fn); if ((last_ret = (ret)) != 0) goto cs_failed; } while (0) | |||
146 | 145 | ||
147 | static int pcmcia_init_one(struct pcmcia_device *pdev) | 146 | static int pcmcia_init_one(struct pcmcia_device *pdev) |
148 | { | 147 | { |
149 | struct ata_probe_ent ae; | 148 | struct ata_host *host; |
149 | struct ata_port *ap; | ||
150 | struct ata_pcmcia_info *info; | 150 | struct ata_pcmcia_info *info; |
151 | tuple_t tuple; | 151 | tuple_t tuple; |
152 | struct { | 152 | struct { |
@@ -290,24 +290,24 @@ next_entry: | |||
290 | * Having done the PCMCIA plumbing the ATA side is relatively | 290 | * Having done the PCMCIA plumbing the ATA side is relatively |
291 | * sane. | 291 | * sane. |
292 | */ | 292 | */ |
293 | 293 | ret = -ENOMEM; | |
294 | memset(&ae, 0, sizeof(struct ata_probe_ent)); | 294 | host = ata_host_alloc(&pdev->dev, 1); |
295 | INIT_LIST_HEAD(&ae.node); | 295 | if (!host) |
296 | ae.dev = &pdev->dev; | 296 | goto failed; |
297 | ae.port_ops = &pcmcia_port_ops; | 297 | ap = host->ports[0]; |
298 | ae.sht = &pcmcia_sht; | 298 | |
299 | ae.n_ports = 1; | 299 | ap->ops = &pcmcia_port_ops; |
300 | ae.pio_mask = 1; /* ISA so PIO 0 cycles */ | 300 | ap->pio_mask = 1; /* ISA so PIO 0 cycles */ |
301 | ae.irq = pdev->irq.AssignedIRQ; | 301 | ap->flags |= ATA_FLAG_SLAVE_POSS; |
302 | ae.irq_flags = IRQF_SHARED; | 302 | ap->ioaddr.cmd_addr = io_addr; |
303 | ae.port_flags = ATA_FLAG_SLAVE_POSS | ATA_FLAG_SRST; | 303 | ap->ioaddr.altstatus_addr = ctl_addr; |
304 | ae.port[0].cmd_addr = io_addr; | 304 | ap->ioaddr.ctl_addr = ctl_addr; |
305 | ae.port[0].altstatus_addr = ctl_addr; | 305 | ata_std_ports(&ap->ioaddr); |
306 | ae.port[0].ctl_addr = ctl_addr; | 306 | |
307 | ata_std_ports(&ae.port[0]); | 307 | /* activate */ |
308 | 308 | ret = ata_host_activate(host, pdev->irq.AssignedIRQ, ata_interrupt, | |
309 | ret = -ENODEV; | 309 | IRQF_SHARED, &pcmcia_sht); |
310 | if (ata_device_add(&ae) == 0) | 310 | if (ret) |
311 | goto failed; | 311 | goto failed; |
312 | 312 | ||
313 | info->ndev = 1; | 313 | info->ndev = 1; |