Lines Matching +full:mode +full:- +full:recovery
1 // SPDX-License-Identifier: GPL-2.0-or-later
8 * PIO mode and smarter silicon.
11 * drive for the right PIO mode. We must also ignore all the blacklists
40 int recovery; member
52 * cs5520_set_timings - program PIO timings
56 * Program the PIO mode timings for the controller according to the pio
62 struct pci_dev *pdev = to_pci_dev(ap->host->dev); in cs5520_set_timings()
63 int slave = adev->devno; in cs5520_set_timings()
65 pio -= XFER_PIO_0; in cs5520_set_timings()
68 pci_write_config_byte(pdev, 0x62 + ap->port_no, in cs5520_set_timings()
69 (cs5520_pio_clocks[pio].recovery << 4) | in cs5520_set_timings()
73 pci_write_config_byte(pdev, 0x64 + 4*ap->port_no + slave, in cs5520_set_timings()
74 (cs5520_pio_clocks[pio].recovery << 4) | in cs5520_set_timings()
77 pci_write_config_byte(pdev, 0x66 + 4*ap->port_no + slave, in cs5520_set_timings()
78 (cs5520_pio_clocks[pio].recovery << 4) | in cs5520_set_timings()
83 * cs5520_set_piomode - program PIO timings
87 * Program the PIO mode timings for the controller according to the pio
93 cs5520_set_timings(ap, adev, adev->pio_mode); in cs5520_set_piomode()
133 return -ENODEV; in cs5520_init_one()
142 dev_warn(&pdev->dev, "DMA mode disabled. Enabling.\n"); in cs5520_init_one()
146 pi.mwdma_mask = id->driver_data; in cs5520_init_one()
148 host = ata_host_alloc_pinfo(&pdev->dev, ppi, 2); in cs5520_init_one()
150 return -ENOMEM; in cs5520_init_one()
155 return -ENODEV; in cs5520_init_one()
158 if (dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32))) { in cs5520_init_one()
160 return -ENODEV; in cs5520_init_one()
164 iomap[0] = devm_ioport_map(&pdev->dev, cmd_port[0], 8); in cs5520_init_one()
165 iomap[1] = devm_ioport_map(&pdev->dev, ctl_port[0], 1); in cs5520_init_one()
166 iomap[2] = devm_ioport_map(&pdev->dev, cmd_port[1], 8); in cs5520_init_one()
167 iomap[3] = devm_ioport_map(&pdev->dev, ctl_port[1], 1); in cs5520_init_one()
171 return -ENOMEM; in cs5520_init_one()
173 ioaddr = &host->ports[0]->ioaddr; in cs5520_init_one()
174 ioaddr->cmd_addr = iomap[0]; in cs5520_init_one()
175 ioaddr->ctl_addr = iomap[1]; in cs5520_init_one()
176 ioaddr->altstatus_addr = iomap[1]; in cs5520_init_one()
177 ioaddr->bmdma_addr = iomap[4]; in cs5520_init_one()
180 ata_port_desc(host->ports[0], in cs5520_init_one()
182 ata_port_pbar_desc(host->ports[0], 4, 0, "bmdma"); in cs5520_init_one()
184 ioaddr = &host->ports[1]->ioaddr; in cs5520_init_one()
185 ioaddr->cmd_addr = iomap[2]; in cs5520_init_one()
186 ioaddr->ctl_addr = iomap[3]; in cs5520_init_one()
187 ioaddr->altstatus_addr = iomap[3]; in cs5520_init_one()
188 ioaddr->bmdma_addr = iomap[4] + 8; in cs5520_init_one()
191 ata_port_desc(host->ports[1], in cs5520_init_one()
193 ata_port_pbar_desc(host->ports[1], 4, 8, "bmdma"); in cs5520_init_one()
203 struct ata_port *ap = host->ports[i]; in cs5520_init_one()
208 rc = devm_request_irq(&pdev->dev, irq[ap->port_no], in cs5520_init_one()
221 * cs5520_reinit_one - device resume
225 * to restore DMA mode support on BIOSen which disabled it
247 * cs5520_pci_device_suspend - device suspend
294 MODULE_DESCRIPTION("low-level driver for Cyrix CS5510/5520");