Lines Matching refs:hwif
25 static void pdc202xx_set_mode(ide_hwif_t *hwif, ide_drive_t *drive) in pdc202xx_set_mode() argument
27 struct pci_dev *dev = to_pci_dev(hwif->dev); in pdc202xx_set_mode()
80 static void pdc202xx_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in pdc202xx_set_pio_mode() argument
83 pdc202xx_set_mode(hwif, drive); in pdc202xx_set_pio_mode()
86 static int pdc202xx_test_irq(ide_hwif_t *hwif) in pdc202xx_test_irq() argument
88 struct pci_dev *dev = to_pci_dev(hwif->dev); in pdc202xx_test_irq()
92 if (hwif->channel) { in pdc202xx_test_irq()
107 static u8 pdc2026x_cable_detect(ide_hwif_t *hwif) in pdc2026x_cable_detect() argument
109 struct pci_dev *dev = to_pci_dev(hwif->dev); in pdc2026x_cable_detect()
110 u16 CIS, mask = hwif->channel ? (1 << 11) : (1 << 10); in pdc2026x_cable_detect()
126 static void pdc_old_enable_66MHz_clock(ide_hwif_t *hwif) in pdc_old_enable_66MHz_clock() argument
128 unsigned long clock_reg = hwif->extra_base + 0x01; in pdc_old_enable_66MHz_clock()
131 outb(clock | (hwif->channel ? 0x08 : 0x02), clock_reg); in pdc_old_enable_66MHz_clock()
134 static void pdc_old_disable_66MHz_clock(ide_hwif_t *hwif) in pdc_old_disable_66MHz_clock() argument
136 unsigned long clock_reg = hwif->extra_base + 0x01; in pdc_old_disable_66MHz_clock()
139 outb(clock & ~(hwif->channel ? 0x08 : 0x02), clock_reg); in pdc_old_disable_66MHz_clock()
142 static void pdc2026x_init_hwif(ide_hwif_t *hwif) in pdc2026x_init_hwif() argument
144 pdc_old_disable_66MHz_clock(hwif); in pdc2026x_init_hwif()
150 pdc_old_enable_66MHz_clock(drive->hwif); in pdc202xx_dma_start()
152 ide_hwif_t *hwif = drive->hwif; in pdc202xx_dma_start() local
153 struct request *rq = hwif->rq; in pdc202xx_dma_start()
154 unsigned long high_16 = hwif->extra_base - 16; in pdc202xx_dma_start()
155 unsigned long atapi_reg = high_16 + (hwif->channel ? 0x24 : 0x20); in pdc202xx_dma_start()
159 outb(clock | (hwif->channel ? 0x08 : 0x02), high_16 + 0x11); in pdc202xx_dma_start()
172 ide_hwif_t *hwif = drive->hwif; in pdc202xx_dma_end() local
173 unsigned long high_16 = hwif->extra_base - 16; in pdc202xx_dma_end()
174 unsigned long atapi_reg = high_16 + (hwif->channel ? 0x24 : 0x20); in pdc202xx_dma_end()
179 outb(clock & ~(hwif->channel ? 0x08:0x02), high_16 + 0x11); in pdc202xx_dma_end()
182 pdc_old_disable_66MHz_clock(drive->hwif); in pdc202xx_dma_end()