Lines Matching refs:hwif

559 	ide_hwif_t *hwif	= drive->hwif;  in hpt3xx_udma_filter()  local
560 struct hpt_info *info = hpt3xx_get_info(hwif->dev); in hpt3xx_udma_filter()
561 u8 mask = hwif->ultra_mask; in hpt3xx_udma_filter()
598 ide_hwif_t *hwif = drive->hwif; in hpt3xx_mdma_filter() local
599 struct hpt_info *info = hpt3xx_get_info(hwif->dev); in hpt3xx_mdma_filter()
631 static void hpt3xx_set_mode(ide_hwif_t *hwif, ide_drive_t *drive) in hpt3xx_set_mode() argument
633 struct pci_dev *dev = to_pci_dev(hwif->dev); in hpt3xx_set_mode()
634 struct hpt_info *info = hpt3xx_get_info(hwif->dev); in hpt3xx_set_mode()
655 static void hpt3xx_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in hpt3xx_set_pio_mode() argument
658 hpt3xx_set_mode(hwif, drive); in hpt3xx_set_pio_mode()
663 ide_hwif_t *hwif = drive->hwif; in hpt3xx_maskproc() local
664 struct pci_dev *dev = to_pci_dev(hwif->dev); in hpt3xx_maskproc()
665 struct hpt_info *info = hpt3xx_get_info(hwif->dev); in hpt3xx_maskproc()
682 disable_irq(hwif->irq); in hpt3xx_maskproc()
684 enable_irq(hwif->irq); in hpt3xx_maskproc()
693 struct pci_dev *dev = to_pci_dev(drive->hwif->dev); in hpt366_dma_lost_irq()
708 ide_hwif_t *hwif = drive->hwif; in hpt370_clear_engine() local
709 struct pci_dev *dev = to_pci_dev(hwif->dev); in hpt370_clear_engine()
711 pci_write_config_byte(dev, hwif->select_data, 0x37); in hpt370_clear_engine()
717 ide_hwif_t *hwif = drive->hwif; in hpt370_irq_timeout() local
718 struct pci_dev *dev = to_pci_dev(hwif->dev); in hpt370_irq_timeout()
722 pci_read_config_word(dev, hwif->select_data + 2, &bfifo); in hpt370_irq_timeout()
726 dma_cmd = inb(hwif->dma_base + ATA_DMA_CMD); in hpt370_irq_timeout()
728 outb(dma_cmd & ~ATA_DMA_START, hwif->dma_base + ATA_DMA_CMD); in hpt370_irq_timeout()
742 ide_hwif_t *hwif = drive->hwif; in hpt370_dma_end() local
743 u8 dma_stat = inb(hwif->dma_base + ATA_DMA_STATUS); in hpt370_dma_end()
748 dma_stat = inb(hwif->dma_base + ATA_DMA_STATUS); in hpt370_dma_end()
758 ide_hwif_t *hwif = drive->hwif; in hpt374_dma_test_irq() local
759 struct pci_dev *dev = to_pci_dev(hwif->dev); in hpt374_dma_test_irq()
763 pci_read_config_word(dev, hwif->select_data + 2, &bfifo); in hpt374_dma_test_irq()
769 dma_stat = inb(hwif->dma_base + ATA_DMA_STATUS); in hpt374_dma_test_irq()
779 ide_hwif_t *hwif = drive->hwif; in hpt374_dma_end() local
780 struct pci_dev *dev = to_pci_dev(hwif->dev); in hpt374_dma_end()
781 u8 mcr = 0, mcr_addr = hwif->select_data; in hpt374_dma_end()
782 u8 bwsr = 0, mask = hwif->channel ? 0x02 : 0x01; in hpt374_dma_end()
799 static void hpt3xxn_set_clock(ide_hwif_t *hwif, u8 mode) in hpt3xxn_set_clock() argument
801 unsigned long base = hwif->extra_base; in hpt3xxn_set_clock()
841 hpt3xxn_set_clock(drive->hwif, rq_data_dir(rq) ? 0x21 : 0x23); in hpt3xxn_rw_disk()
1154 static u8 hpt3xx_cable_detect(ide_hwif_t *hwif) in hpt3xx_cable_detect() argument
1156 struct pci_dev *dev = to_pci_dev(hwif->dev); in hpt3xx_cable_detect()
1157 struct hpt_info *info = hpt3xx_get_info(hwif->dev); in hpt3xx_cable_detect()
1159 u8 scr1 = 0, ata66 = hwif->channel ? 0x01 : 0x02; in hpt3xx_cable_detect()
1172 u8 mcr_addr = hwif->select_data + 2; in hpt3xx_cable_detect()
1200 static void init_hwif_hpt366(ide_hwif_t *hwif) in init_hwif_hpt366() argument
1202 struct hpt_info *info = hpt3xx_get_info(hwif->dev); in init_hwif_hpt366()
1206 hwif->select_data = hwif->channel ? 0x54 : 0x50; in init_hwif_hpt366()
1219 hwif->host->host_flags |= IDE_HFLAG_SERIALIZE; in init_hwif_hpt366()
1220 hwif->rw_disk = &hpt3xxn_rw_disk; in init_hwif_hpt366()
1224 static int init_dma_hpt366(ide_hwif_t *hwif, in init_dma_hpt366() argument
1227 struct pci_dev *dev = to_pci_dev(hwif->dev); in init_dma_hpt366()
1228 unsigned long flags, base = ide_pci_dma_base(hwif, d); in init_dma_hpt366()
1234 hwif->dma_base = base; in init_dma_hpt366()
1236 if (ide_pci_check_simplex(hwif, d) < 0) in init_dma_hpt366()
1247 pci_read_config_byte(dev, hwif->channel ? 0x4b : 0x43, &masterdma); in init_dma_hpt366()
1248 pci_read_config_byte(dev, hwif->channel ? 0x4f : 0x47, &slavedma); in init_dma_hpt366()
1258 hwif->name, base, base + 7); in init_dma_hpt366()
1260 hwif->extra_base = base + (hwif->channel ? 8 : 16); in init_dma_hpt366()
1262 if (ide_allocate_dma_engine(hwif)) in init_dma_hpt366()