Lines Matching refs:ahc
253 ahc_print_path(struct ahc_softc *ahc, struct scb *scb) in ahc_print_path() argument
256 ahc->platform_data->host->host_no, in ahc_print_path()
257 scb != NULL ? SCB_GET_CHANNEL(ahc, scb) : 'X', in ahc_print_path()
258 scb != NULL ? SCB_GET_TARGET(ahc, scb) : -1, in ahc_print_path()
364 static void ahc_linux_queue_cmd_complete(struct ahc_softc *ahc,
366 static void ahc_linux_freeze_simq(struct ahc_softc *ahc);
367 static void ahc_linux_release_simq(struct ahc_softc *ahc);
369 static void ahc_linux_initialize_scsi_bus(struct ahc_softc *ahc);
370 static u_int ahc_linux_user_tagdepth(struct ahc_softc *ahc,
399 ahc_inb(struct ahc_softc * ahc, long port) in ahc_inb() argument
403 if (ahc->tag == BUS_SPACE_MEMIO) { in ahc_inb()
404 x = readb(ahc->bsh.maddr + port); in ahc_inb()
406 x = inb(ahc->bsh.ioport + port); in ahc_inb()
413 ahc_outb(struct ahc_softc * ahc, long port, uint8_t val) in ahc_outb() argument
415 if (ahc->tag == BUS_SPACE_MEMIO) { in ahc_outb()
416 writeb(val, ahc->bsh.maddr + port); in ahc_outb()
418 outb(val, ahc->bsh.ioport + port); in ahc_outb()
424 ahc_outsb(struct ahc_softc * ahc, long port, uint8_t *array, int count) in ahc_outsb() argument
434 ahc_outb(ahc, port, *array++); in ahc_outsb()
438 ahc_insb(struct ahc_softc * ahc, long port, uint8_t *array, int count) in ahc_insb() argument
448 *array++ = ahc_inb(ahc, port); in ahc_insb()
454 static int ahc_linux_map_seg(struct ahc_softc *ahc, struct scb *scb,
459 ahc_linux_unmap_scb(struct ahc_softc *ahc, struct scb *scb) in ahc_linux_unmap_scb() argument
464 ahc_sync_sglist(ahc, scb, BUS_DMASYNC_POSTWRITE); in ahc_linux_unmap_scb()
470 ahc_linux_map_seg(struct ahc_softc *ahc, struct scb *scb, in ahc_linux_map_seg() argument
484 && (ahc->flags & AHC_39BIT_ADDRESSING) != 0) in ahc_linux_map_seg()
500 struct ahc_softc *ahc; in ahc_linux_info() local
503 ahc = *(struct ahc_softc **)host->hostdata; in ahc_linux_info()
507 strcat(bp, ahc->description); in ahc_linux_info()
510 ahc_controller_info(ahc, ahc_info); in ahc_linux_info()
523 struct ahc_softc *ahc; in ahc_linux_queue_lck() local
528 ahc = *(struct ahc_softc **)cmd->device->host->hostdata; in ahc_linux_queue_lck()
530 ahc_lock(ahc, &flags); in ahc_linux_queue_lck()
531 if (ahc->platform_data->qfrozen == 0) { in ahc_linux_queue_lck()
534 rtn = ahc_linux_run_command(ahc, dev, cmd); in ahc_linux_queue_lck()
536 ahc_unlock(ahc, &flags); in ahc_linux_queue_lck()
546 struct ahc_softc *ahc = in DEF_SCSI_QCMD() local
554 return &ahc->platform_data->starget[target_offset]; in DEF_SCSI_QCMD()
560 struct ahc_softc *ahc = in ahc_linux_target_alloc() local
562 struct seeprom_config *sc = ahc->seep_config; in ahc_linux_target_alloc()
570 unsigned int our_id = ahc->our_id; in ahc_linux_target_alloc()
578 our_id = ahc->our_id_b; in ahc_linux_target_alloc()
580 ahc_lock(ahc, &flags); in ahc_linux_target_alloc()
591 if (ahc->flags & AHC_NEWEEPROM_FMT) { in ahc_linux_target_alloc()
603 if ((ahc->features & AHC_ULTRA2) != 0) { in ahc_linux_target_alloc()
614 ahc_find_period(ahc, scsirate, maxsync); in ahc_linux_target_alloc()
616 tinfo = ahc_fetch_transinfo(ahc, channel, ahc->our_id, in ahc_linux_target_alloc()
622 ahc_set_syncrate(ahc, &devinfo, NULL, 0, 0, 0, in ahc_linux_target_alloc()
624 ahc_set_width(ahc, &devinfo, MSG_EXT_WDTR_BUS_8_BIT, in ahc_linux_target_alloc()
626 ahc_unlock(ahc, &flags); in ahc_linux_target_alloc()
642 struct ahc_softc *ahc = in ahc_linux_slave_alloc() local
648 printk("%s: Slave Alloc %d\n", ahc_name(ahc), sdev->id); in ahc_linux_slave_alloc()
674 struct ahc_softc *ahc; in ahc_linux_slave_configure() local
676 ahc = *((struct ahc_softc **)sdev->host->hostdata); in ahc_linux_slave_configure()
704 struct ahc_softc *ahc; in ahc_linux_biosparam() local
707 ahc = *((struct ahc_softc **)sdev->host->hostdata); in ahc_linux_biosparam()
725 extended = (ahc->flags & AHC_EXTENDED_TRANS_A) != 0; in ahc_linux_biosparam()
727 extended = (ahc->flags & AHC_EXTENDED_TRANS_B) != 0; in ahc_linux_biosparam()
774 struct ahc_softc *ahc; in ahc_linux_bus_reset() local
778 ahc = *(struct ahc_softc **)cmd->device->host->hostdata; in ahc_linux_bus_reset()
780 ahc_lock(ahc, &flags); in ahc_linux_bus_reset()
781 found = ahc_reset_channel(ahc, scmd_channel(cmd) + 'A', in ahc_linux_bus_reset()
783 ahc_unlock(ahc, &flags); in ahc_linux_bus_reset()
787 "%d SCBs aborted.\n", ahc_name(ahc), found); in ahc_linux_bus_reset()
819 #define BUILD_SCSIID(ahc, cmd) \ argument
821 | (((cmd)->device->channel == 0) ? (ahc)->our_id : (ahc)->our_id_b) \
826 ahc_dma_tag_create(struct ahc_softc *ahc, bus_dma_tag_t parent, in ahc_dma_tag_create() argument
854 ahc_dma_tag_destroy(struct ahc_softc *ahc, bus_dma_tag_t dmat) in ahc_dma_tag_destroy() argument
860 ahc_dmamem_alloc(struct ahc_softc *ahc, bus_dma_tag_t dmat, void** vaddr, in ahc_dmamem_alloc() argument
864 *vaddr = dma_alloc_coherent(ahc->dev, dmat->maxsize, mapp, GFP_ATOMIC); in ahc_dmamem_alloc()
871 ahc_dmamem_free(struct ahc_softc *ahc, bus_dma_tag_t dmat, in ahc_dmamem_free() argument
874 dma_free_coherent(ahc->dev, dmat->maxsize, vaddr, map); in ahc_dmamem_free()
878 ahc_dmamap_load(struct ahc_softc *ahc, bus_dma_tag_t dmat, bus_dmamap_t map, in ahc_dmamap_load() argument
895 ahc_dmamap_destroy(struct ahc_softc *ahc, bus_dma_tag_t dmat, bus_dmamap_t map) in ahc_dmamap_destroy() argument
900 ahc_dmamap_unload(struct ahc_softc *ahc, bus_dma_tag_t dmat, bus_dmamap_t map) in ahc_dmamap_unload() argument
1086 ahc_linux_register_host(struct ahc_softc *ahc, struct scsi_host_template *template) in ahc_linux_register_host() argument
1094 template->name = ahc->description; in ahc_linux_register_host()
1099 *((struct ahc_softc **)host->hostdata) = ahc; in ahc_linux_register_host()
1100 ahc->platform_data->host = host; in ahc_linux_register_host()
1104 host->this_id = ahc->our_id; in ahc_linux_register_host()
1105 host->irq = ahc->platform_data->irq; in ahc_linux_register_host()
1106 host->max_id = (ahc->features & AHC_WIDE) ? 16 : 8; in ahc_linux_register_host()
1108 host->max_channel = (ahc->features & AHC_TWIN) ? 1 : 0; in ahc_linux_register_host()
1110 ahc_lock(ahc, &s); in ahc_linux_register_host()
1111 ahc_set_unit(ahc, ahc_linux_unit++); in ahc_linux_register_host()
1112 ahc_unlock(ahc, &s); in ahc_linux_register_host()
1117 ahc_set_name(ahc, new_name); in ahc_linux_register_host()
1119 host->unique_id = ahc->unit; in ahc_linux_register_host()
1120 ahc_linux_initialize_scsi_bus(ahc); in ahc_linux_register_host()
1121 ahc_intr_enable(ahc, TRUE); in ahc_linux_register_host()
1125 retval = scsi_add_host(host, ahc->dev); in ahc_linux_register_host()
1142 ahc_linux_initialize_scsi_bus(struct ahc_softc *ahc) in ahc_linux_initialize_scsi_bus() argument
1151 ahc_lock(ahc, &s); in ahc_linux_initialize_scsi_bus()
1154 ahc->flags &= ~(AHC_RESET_BUS_A|AHC_RESET_BUS_B); in ahc_linux_initialize_scsi_bus()
1156 if ((ahc->flags & AHC_RESET_BUS_A) != 0) in ahc_linux_initialize_scsi_bus()
1157 ahc_reset_channel(ahc, 'A', /*initiate_reset*/TRUE); in ahc_linux_initialize_scsi_bus()
1159 numtarg = (ahc->features & AHC_WIDE) ? 16 : 8; in ahc_linux_initialize_scsi_bus()
1161 if ((ahc->features & AHC_TWIN) != 0) { in ahc_linux_initialize_scsi_bus()
1163 if ((ahc->flags & AHC_RESET_BUS_B) != 0) { in ahc_linux_initialize_scsi_bus()
1164 ahc_reset_channel(ahc, 'B', /*initiate_reset*/TRUE); in ahc_linux_initialize_scsi_bus()
1185 our_id = ahc->our_id; in ahc_linux_initialize_scsi_bus()
1187 if (i > 7 && (ahc->features & AHC_TWIN) != 0) { in ahc_linux_initialize_scsi_bus()
1189 our_id = ahc->our_id_b; in ahc_linux_initialize_scsi_bus()
1192 tinfo = ahc_fetch_transinfo(ahc, channel, our_id, in ahc_linux_initialize_scsi_bus()
1196 ahc_update_neg_request(ahc, &devinfo, tstate, in ahc_linux_initialize_scsi_bus()
1199 ahc_unlock(ahc, &s); in ahc_linux_initialize_scsi_bus()
1201 if ((ahc->flags & (AHC_RESET_BUS_A|AHC_RESET_BUS_B)) != 0) { in ahc_linux_initialize_scsi_bus()
1202 ahc_linux_freeze_simq(ahc); in ahc_linux_initialize_scsi_bus()
1204 ahc_linux_release_simq(ahc); in ahc_linux_initialize_scsi_bus()
1209 ahc_platform_alloc(struct ahc_softc *ahc, void *platform_arg) in ahc_platform_alloc() argument
1212 ahc->platform_data = in ahc_platform_alloc()
1214 if (ahc->platform_data == NULL) in ahc_platform_alloc()
1216 ahc->platform_data->irq = AHC_LINUX_NOIRQ; in ahc_platform_alloc()
1217 ahc_lockinit(ahc); in ahc_platform_alloc()
1218 ahc->seltime = (aic7xxx_seltime & 0x3) << 4; in ahc_platform_alloc()
1219 ahc->seltime_b = (aic7xxx_seltime & 0x3) << 4; in ahc_platform_alloc()
1221 ahc->flags |= AHC_DISABLE_PCI_PERR; in ahc_platform_alloc()
1227 ahc_platform_free(struct ahc_softc *ahc) in ahc_platform_free() argument
1232 if (ahc->platform_data != NULL) { in ahc_platform_free()
1235 starget = ahc->platform_data->starget[i]; in ahc_platform_free()
1237 ahc->platform_data->starget[i] = NULL; in ahc_platform_free()
1241 if (ahc->platform_data->irq != AHC_LINUX_NOIRQ) in ahc_platform_free()
1242 free_irq(ahc->platform_data->irq, ahc); in ahc_platform_free()
1243 if (ahc->tag == BUS_SPACE_PIO in ahc_platform_free()
1244 && ahc->bsh.ioport != 0) in ahc_platform_free()
1245 release_region(ahc->bsh.ioport, 256); in ahc_platform_free()
1246 if (ahc->tag == BUS_SPACE_MEMIO in ahc_platform_free()
1247 && ahc->bsh.maddr != NULL) { in ahc_platform_free()
1248 iounmap(ahc->bsh.maddr); in ahc_platform_free()
1249 release_mem_region(ahc->platform_data->mem_busaddr, in ahc_platform_free()
1253 if (ahc->platform_data->host) in ahc_platform_free()
1254 scsi_host_put(ahc->platform_data->host); in ahc_platform_free()
1256 kfree(ahc->platform_data); in ahc_platform_free()
1261 ahc_platform_freeze_devq(struct ahc_softc *ahc, struct scb *scb) in ahc_platform_freeze_devq() argument
1263 ahc_platform_abort_scbs(ahc, SCB_GET_TARGET(ahc, scb), in ahc_platform_freeze_devq()
1264 SCB_GET_CHANNEL(ahc, scb), in ahc_platform_freeze_devq()
1270 ahc_platform_set_tags(struct ahc_softc *ahc, struct scsi_device *sdev, in ahc_platform_set_tags() argument
1305 usertags = ahc_linux_user_tagdepth(ahc, devinfo); in ahc_platform_set_tags()
1350 ahc_platform_abort_scbs(struct ahc_softc *ahc, int target, char channel, in ahc_platform_abort_scbs() argument
1357 ahc_linux_user_tagdepth(struct ahc_softc *ahc, struct ahc_devinfo *devinfo) in ahc_linux_user_tagdepth() argument
1363 if ((ahc->user_discenable & devinfo->target_mask) != 0) { in ahc_linux_user_tagdepth()
1364 if (ahc->unit >= ARRAY_SIZE(aic7xxx_tag_info)) { in ahc_linux_user_tagdepth()
1378 tag_info = &aic7xxx_tag_info[ahc->unit]; in ahc_linux_user_tagdepth()
1395 struct ahc_softc *ahc = *((struct ahc_softc **)sdev->host->hostdata); in ahc_linux_device_queue_depth() local
1399 ? ahc->our_id : ahc->our_id_b, in ahc_linux_device_queue_depth()
1403 tags = ahc_linux_user_tagdepth(ahc, &devinfo); in ahc_linux_device_queue_depth()
1406 ahc_platform_set_tags(ahc, sdev, &devinfo, AHC_QUEUE_TAGGED); in ahc_linux_device_queue_depth()
1407 ahc_send_async(ahc, devinfo.channel, devinfo.target, in ahc_linux_device_queue_depth()
1409 ahc_print_devinfo(ahc, &devinfo); in ahc_linux_device_queue_depth()
1412 ahc_platform_set_tags(ahc, sdev, &devinfo, AHC_QUEUE_NONE); in ahc_linux_device_queue_depth()
1413 ahc_send_async(ahc, devinfo.channel, devinfo.target, in ahc_linux_device_queue_depth()
1419 ahc_linux_run_command(struct ahc_softc *ahc, struct ahc_linux_device *dev, in ahc_linux_run_command() argument
1434 if (ahc->platform_data->qfrozen != 0) in ahc_linux_run_command()
1444 && (ahc->features & AHC_SCB_BTT) == 0) { in ahc_linux_run_command()
1448 untagged_q = &(ahc->untagged_queues[target_offset]); in ahc_linux_run_command()
1462 scb = ahc_get_scb(ahc); in ahc_linux_run_command()
1477 hscb->scsiid = BUILD_SCSIID(ahc, cmd); in ahc_linux_run_command()
1479 mask = SCB_GET_TARGET_MASK(ahc, scb); in ahc_linux_run_command()
1480 tinfo = ahc_fetch_transinfo(ahc, SCB_GET_CHANNEL(ahc, scb), in ahc_linux_run_command()
1482 SCB_GET_TARGET(ahc, scb), &tstate); in ahc_linux_run_command()
1488 if ((ahc->user_discenable & mask) != 0) in ahc_linux_run_command()
1537 consumed = ahc_linux_map_seg(ahc, scb, in ahc_linux_run_command()
1564 LIST_INSERT_HEAD(&ahc->pending_scbs, scb, pending_links); in ahc_linux_run_command()
1576 ahc_queue_scb(ahc, scb); in ahc_linux_run_command()
1586 struct ahc_softc *ahc; in ahc_linux_isr() local
1590 ahc = (struct ahc_softc *) dev_id; in ahc_linux_isr()
1591 ahc_lock(ahc, &flags); in ahc_linux_isr()
1592 ours = ahc_intr(ahc); in ahc_linux_isr()
1593 ahc_unlock(ahc, &flags); in ahc_linux_isr()
1598 ahc_platform_flushwork(struct ahc_softc *ahc) in ahc_platform_flushwork() argument
1604 ahc_send_async(struct ahc_softc *ahc, char channel, in ahc_send_async() argument
1619 tinfo = ahc_fetch_transinfo(ahc, channel, in ahc_send_async()
1620 channel == 'A' ? ahc->our_id in ahc_send_async()
1621 : ahc->our_id_b, in ahc_send_async()
1642 starget = ahc->platform_data->starget[target_offset]; in ahc_send_async()
1671 scsi_report_device_reset(ahc->platform_data->host, in ahc_send_async()
1676 if (ahc->platform_data->host != NULL) { in ahc_send_async()
1677 scsi_report_bus_reset(ahc->platform_data->host, in ahc_send_async()
1690 ahc_done(struct ahc_softc *ahc, struct scb *scb) in ahc_done() argument
1700 target_offset = SCB_GET_TARGET_OFFSET(ahc, scb); in ahc_done()
1701 untagged_q = &(ahc->untagged_queues[target_offset]); in ahc_done()
1711 ahc_dump_card_state(ahc); in ahc_done()
1722 ahc_linux_unmap_scb(ahc, scb); in ahc_done()
1739 ahc_print_path(ahc, scb); in ahc_done()
1757 ahc_print_path(ahc, scb); in ahc_done()
1762 ahc_print_path(ahc, scb); in ahc_done()
1773 ahc_linux_handle_scsi_status(ahc, cmd->device, scb); in ahc_done()
1801 if (ahc->platform_data->eh_done) in ahc_done()
1802 complete(ahc->platform_data->eh_done); in ahc_done()
1805 ahc_free_scb(ahc, scb); in ahc_done()
1806 ahc_linux_queue_cmd_complete(ahc, cmd); in ahc_done()
1810 ahc_linux_handle_scsi_status(struct ahc_softc *ahc, in ahc_linux_handle_scsi_status() argument
1817 ahc->our_id, in ahc_linux_handle_scsi_status()
1852 ahc_get_sense_buf(ahc, scb), sense_size); in ahc_linux_handle_scsi_status()
1909 ahc_print_path(ahc, scb); in ahc_linux_handle_scsi_status()
1919 ahc_platform_set_tags(ahc, sdev, &devinfo, in ahc_linux_handle_scsi_status()
1930 ahc_platform_set_tags(ahc, sdev, &devinfo, in ahc_linux_handle_scsi_status()
1939 ahc_linux_queue_cmd_complete(struct ahc_softc *ahc, struct scsi_cmnd *cmd) in ahc_linux_queue_cmd_complete() argument
2009 ahc_linux_freeze_simq(struct ahc_softc *ahc) in ahc_linux_freeze_simq() argument
2013 ahc_lock(ahc, &s); in ahc_linux_freeze_simq()
2014 ahc->platform_data->qfrozen++; in ahc_linux_freeze_simq()
2015 if (ahc->platform_data->qfrozen == 1) { in ahc_linux_freeze_simq()
2016 scsi_block_requests(ahc->platform_data->host); in ahc_linux_freeze_simq()
2019 ahc_platform_abort_scbs(ahc, CAM_TARGET_WILDCARD, ALL_CHANNELS, in ahc_linux_freeze_simq()
2023 ahc_unlock(ahc, &s); in ahc_linux_freeze_simq()
2027 ahc_linux_release_simq(struct ahc_softc *ahc) in ahc_linux_release_simq() argument
2033 ahc_lock(ahc, &s); in ahc_linux_release_simq()
2034 if (ahc->platform_data->qfrozen > 0) in ahc_linux_release_simq()
2035 ahc->platform_data->qfrozen--; in ahc_linux_release_simq()
2036 if (ahc->platform_data->qfrozen == 0) in ahc_linux_release_simq()
2038 ahc_unlock(ahc, &s); in ahc_linux_release_simq()
2046 scsi_unblock_requests(ahc->platform_data->host); in ahc_linux_release_simq()
2052 struct ahc_softc *ahc; in ahc_linux_queue_recovery_cmd() local
2070 ahc = *(struct ahc_softc **)cmd->device->host->hostdata; in ahc_linux_queue_recovery_cmd()
2080 ahc_lock(ahc, &flags); in ahc_linux_queue_recovery_cmd()
2097 ahc_name(ahc), cmd->device->channel, cmd->device->id, in ahc_linux_queue_recovery_cmd()
2104 && ahc_search_untagged_queues(ahc, cmd, cmd->device->id, in ahc_linux_queue_recovery_cmd()
2109 ahc_name(ahc), cmd->device->channel, cmd->device->id, in ahc_linux_queue_recovery_cmd()
2118 LIST_FOREACH(pending_scb, &ahc->pending_scbs, pending_links) { in ahc_linux_queue_recovery_cmd()
2126 LIST_FOREACH(pending_scb, &ahc->pending_scbs, pending_links) { in ahc_linux_queue_recovery_cmd()
2127 if (ahc_match_scb(ahc, pending_scb, scmd_id(cmd), in ahc_linux_queue_recovery_cmd()
2153 was_paused = ahc_is_paused(ahc); in ahc_linux_queue_recovery_cmd()
2154 ahc_pause_and_flushwork(ahc); in ahc_linux_queue_recovery_cmd()
2163 ahc_name(ahc), was_paused ? "" : "not "); in ahc_linux_queue_recovery_cmd()
2164 ahc_dump_card_state(ahc); in ahc_linux_queue_recovery_cmd()
2168 if (ahc_search_qinfifo(ahc, cmd->device->id, in ahc_linux_queue_recovery_cmd()
2175 ahc_name(ahc), cmd->device->channel, in ahc_linux_queue_recovery_cmd()
2180 } else if (ahc_search_qinfifo(ahc, cmd->device->id, in ahc_linux_queue_recovery_cmd()
2189 if (disconnected && (ahc_inb(ahc, SEQ_FLAGS) & NOT_IDENTIFIED) == 0) { in ahc_linux_queue_recovery_cmd()
2192 bus_scb = ahc_lookup_scb(ahc, ahc_inb(ahc, SCB_TAG)); in ahc_linux_queue_recovery_cmd()
2196 && ahc_inb(ahc, SAVED_SCSIID) == pending_scb->hscb->scsiid in ahc_linux_queue_recovery_cmd()
2197 && ahc_inb(ahc, SAVED_LUN) == SCB_GET_LUN(pending_scb)) in ahc_linux_queue_recovery_cmd()
2209 last_phase = ahc_inb(ahc, LASTPHASE); in ahc_linux_queue_recovery_cmd()
2210 saved_scbptr = ahc_inb(ahc, SCBPTR); in ahc_linux_queue_recovery_cmd()
2211 active_scb_index = ahc_inb(ahc, SCB_TAG); in ahc_linux_queue_recovery_cmd()
2212 saved_scsiid = ahc_inb(ahc, SAVED_SCSIID); in ahc_linux_queue_recovery_cmd()
2216 && SCSIID_TARGET(ahc, saved_scsiid) == scmd_id(cmd)))) { in ahc_linux_queue_recovery_cmd()
2222 pending_scb = ahc_lookup_scb(ahc, active_scb_index); in ahc_linux_queue_recovery_cmd()
2224 ahc_outb(ahc, MSG_OUT, HOST_MSG); in ahc_linux_queue_recovery_cmd()
2225 ahc_outb(ahc, SCSISIGO, last_phase|ATNO); in ahc_linux_queue_recovery_cmd()
2256 ahc_search_disc_list(ahc, cmd->device->id, in ahc_linux_queue_recovery_cmd()
2270 if ((ahc->flags & AHC_PAGESCBS) == 0) { in ahc_linux_queue_recovery_cmd()
2271 ahc_outb(ahc, SCBPTR, pending_scb->hscb->tag); in ahc_linux_queue_recovery_cmd()
2272 ahc_outb(ahc, SCB_CONTROL, in ahc_linux_queue_recovery_cmd()
2273 ahc_inb(ahc, SCB_CONTROL)|MK_MESSAGE); in ahc_linux_queue_recovery_cmd()
2281 ahc_search_qinfifo(ahc, cmd->device->id, in ahc_linux_queue_recovery_cmd()
2286 ahc_qinfifo_requeue_tail(ahc, pending_scb); in ahc_linux_queue_recovery_cmd()
2287 ahc_outb(ahc, SCBPTR, saved_scbptr); in ahc_linux_queue_recovery_cmd()
2288 ahc_print_path(ahc, pending_scb); in ahc_linux_queue_recovery_cmd()
2307 ahc_unpause(ahc); in ahc_linux_queue_recovery_cmd()
2311 ahc->platform_data->eh_done = &done; in ahc_linux_queue_recovery_cmd()
2312 ahc_unlock(ahc, &flags); in ahc_linux_queue_recovery_cmd()
2316 ahc_lock(ahc, &flags); in ahc_linux_queue_recovery_cmd()
2317 ahc->platform_data->eh_done = NULL; in ahc_linux_queue_recovery_cmd()
2318 ahc_unlock(ahc, &flags); in ahc_linux_queue_recovery_cmd()
2325 ahc_unlock(ahc, &flags); in ahc_linux_queue_recovery_cmd()
2332 struct ahc_softc *ahc = *((struct ahc_softc **)shost->hostdata); in ahc_linux_set_width() local
2338 ahc_lock(ahc, &flags); in ahc_linux_set_width()
2339 ahc_set_width(ahc, &devinfo, width, AHC_TRANS_GOAL, FALSE); in ahc_linux_set_width()
2340 ahc_unlock(ahc, &flags); in ahc_linux_set_width()
2346 struct ahc_softc *ahc = *((struct ahc_softc **)shost->hostdata); in ahc_linux_set_period() local
2349 = ahc_fetch_transinfo(ahc, in ahc_linux_set_period()
2380 syncrate = ahc_find_syncrate(ahc, &period, &ppr_options, AHC_SYNCRATE_DT); in ahc_linux_set_period()
2381 ahc_lock(ahc, &flags); in ahc_linux_set_period()
2382 ahc_set_syncrate(ahc, &devinfo, syncrate, period, offset, in ahc_linux_set_period()
2384 ahc_unlock(ahc, &flags); in ahc_linux_set_period()
2390 struct ahc_softc *ahc = *((struct ahc_softc **)shost->hostdata); in ahc_linux_set_offset() local
2393 = ahc_fetch_transinfo(ahc, in ahc_linux_set_offset()
2405 syncrate = ahc_find_syncrate(ahc, &period, &ppr_options, AHC_SYNCRATE_DT); in ahc_linux_set_offset()
2409 ahc_lock(ahc, &flags); in ahc_linux_set_offset()
2410 ahc_set_syncrate(ahc, &devinfo, syncrate, period, offset, in ahc_linux_set_offset()
2412 ahc_unlock(ahc, &flags); in ahc_linux_set_offset()
2418 struct ahc_softc *ahc = *((struct ahc_softc **)shost->hostdata); in ahc_linux_set_dt() local
2421 = ahc_fetch_transinfo(ahc, in ahc_linux_set_dt()
2441 syncrate = ahc_find_syncrate(ahc, &period, &ppr_options,AHC_SYNCRATE_DT); in ahc_linux_set_dt()
2442 ahc_lock(ahc, &flags); in ahc_linux_set_dt()
2443 ahc_set_syncrate(ahc, &devinfo, syncrate, period, tinfo->goal.offset, in ahc_linux_set_dt()
2445 ahc_unlock(ahc, &flags); in ahc_linux_set_dt()
2456 struct ahc_softc *ahc = *((struct ahc_softc **)shost->hostdata);
2459 = ahc_fetch_transinfo(ahc,
2474 syncrate = ahc_find_syncrate(ahc, &period, &ppr_options, AHC_SYNCRATE_DT);
2475 ahc_lock(ahc, &flags);
2476 ahc_set_syncrate(ahc, &devinfo, syncrate, period, tinfo->goal.offset,
2478 ahc_unlock(ahc, &flags);
2484 struct ahc_softc *ahc = *((struct ahc_softc **)shost->hostdata);
2487 = ahc_fetch_transinfo(ahc,
2502 syncrate = ahc_find_syncrate(ahc, &period, &ppr_options, AHC_SYNCRATE_DT);
2503 ahc_lock(ahc, &flags);
2504 ahc_set_syncrate(ahc, &devinfo, syncrate, period, tinfo->goal.offset,
2506 ahc_unlock(ahc, &flags);
2512 struct ahc_softc *ahc = *(struct ahc_softc **)shost->hostdata; in ahc_linux_get_signalling() local
2516 if (!(ahc->features & AHC_ULTRA2)) { in ahc_linux_get_signalling()
2519 ahc->features & AHC_HVD ? in ahc_linux_get_signalling()
2525 ahc_lock(ahc, &flags); in ahc_linux_get_signalling()
2526 ahc_pause(ahc); in ahc_linux_get_signalling()
2527 mode = ahc_inb(ahc, SBLKCTL); in ahc_linux_get_signalling()
2528 ahc_unpause(ahc); in ahc_linux_get_signalling()
2529 ahc_unlock(ahc, &flags); in ahc_linux_get_signalling()