Lines Matching refs:aha1542

281 	struct aha1542_hostdata *aha1542 = shost_priv(sh);  in aha1542_interrupt()  local
287 struct mailbox *mb = aha1542->mb; in aha1542_interrupt()
288 struct ccb *ccb = aha1542->ccb; in aha1542_interrupt()
329 mbi = aha1542->aha1542_last_mbi_used + 1; in aha1542_interrupt()
339 } while (mbi != aha1542->aha1542_last_mbi_used); in aha1542_interrupt()
349 mbo = (scsi2int(mb[mbi].ccbptr) - (unsigned long)aha1542->ccb_handle) / sizeof(struct ccb); in aha1542_interrupt()
352 aha1542->aha1542_last_mbi_used = mbi; in aha1542_interrupt()
367 tmp_cmd = aha1542->int_cmds[mbo]; in aha1542_interrupt()
406 aha1542->int_cmds[mbo] = NULL; /* This effectively frees up the mailbox slot, as in aha1542_interrupt()
417 struct aha1542_hostdata *aha1542 = shost_priv(sh); in aha1542_queuecommand() local
424 struct mailbox *mb = aha1542->mb; in aha1542_queuecommand()
425 struct ccb *ccb = aha1542->ccb; in aha1542_queuecommand()
464 mbo = aha1542->aha1542_last_mbo_used + 1; in aha1542_queuecommand()
469 if (mb[mbo].status == 0 && aha1542->int_cmds[mbo] == NULL) in aha1542_queuecommand()
474 } while (mbo != aha1542->aha1542_last_mbo_used); in aha1542_queuecommand()
476 if (mb[mbo].status || aha1542->int_cmds[mbo]) in aha1542_queuecommand()
479 aha1542->int_cmds[mbo] = cmd; /* This will effectively prevent someone else from in aha1542_queuecommand()
483 aha1542->aha1542_last_mbo_used = mbo; in aha1542_queuecommand()
490 any2scsi(mb[mbo].ccbptr, aha1542->ccb_handle + mbo * sizeof(*ccb)); in aha1542_queuecommand()
528 struct aha1542_hostdata *aha1542 = shost_priv(sh); in setup_mailboxes() local
533 aha1542->mb[i].status = 0; in setup_mailboxes()
534 any2scsi(aha1542->mb[i].ccbptr, in setup_mailboxes()
535 aha1542->ccb_handle + i * sizeof(struct ccb)); in setup_mailboxes()
536 aha1542->mb[AHA1542_MAILBOXES + i].status = 0; in setup_mailboxes()
539 any2scsi(mb_cmd + 2, aha1542->mb_handle); in setup_mailboxes()
651 struct aha1542_hostdata *aha1542 = shost_priv(sh); in aha1542_query() local
664 aha1542->bios_translation = BIOS_TRANSLATION_6432; /* Default case */ in aha1542_query()
683 aha1542->bios_translation = aha1542_mbenable(sh); in aha1542_query()
744 struct aha1542_hostdata *aha1542; in aha1542_hw_init() local
756 aha1542 = shost_priv(sh); in aha1542_hw_init()
761 aha1542->aha1542_last_mbi_used = 2 * AHA1542_MAILBOXES - 1; in aha1542_hw_init()
762 aha1542->aha1542_last_mbo_used = AHA1542_MAILBOXES - 1; in aha1542_hw_init()
777 if (aha1542->bios_translation == BIOS_TRANSLATION_25563) in aha1542_hw_init()
783 aha1542->mb = dma_alloc_coherent(pdev, in aha1542_hw_init()
785 &aha1542->mb_handle, GFP_KERNEL); in aha1542_hw_init()
786 if (!aha1542->mb) in aha1542_hw_init()
789 aha1542->ccb = dma_alloc_coherent(pdev, in aha1542_hw_init()
791 &aha1542->ccb_handle, GFP_KERNEL); in aha1542_hw_init()
792 if (!aha1542->ccb) in aha1542_hw_init()
826 aha1542->ccb, aha1542->ccb_handle); in aha1542_hw_init()
829 aha1542->mb, aha1542->mb_handle); in aha1542_hw_init()
840 struct aha1542_hostdata *aha1542 = shost_priv(sh); in aha1542_release() local
847 aha1542->ccb, aha1542->ccb_handle); in aha1542_release()
849 aha1542->mb, aha1542->mb_handle); in aha1542_release()
866 struct aha1542_hostdata *aha1542 = shost_priv(sh); in aha1542_dev_reset() local
868 struct mailbox *mb = aha1542->mb; in aha1542_dev_reset()
872 struct ccb *ccb = aha1542->ccb; in aha1542_dev_reset()
875 mbo = aha1542->aha1542_last_mbo_used + 1; in aha1542_dev_reset()
880 if (mb[mbo].status == 0 && aha1542->int_cmds[mbo] == NULL) in aha1542_dev_reset()
885 } while (mbo != aha1542->aha1542_last_mbo_used); in aha1542_dev_reset()
887 if (mb[mbo].status || aha1542->int_cmds[mbo]) in aha1542_dev_reset()
890 aha1542->int_cmds[mbo] = cmd; /* This will effectively in aha1542_dev_reset()
895 aha1542->aha1542_last_mbo_used = mbo; in aha1542_dev_reset()
898 any2scsi(mb[mbo].ccbptr, aha1542->ccb_handle + mbo * sizeof(*ccb)); in aha1542_dev_reset()
925 struct aha1542_hostdata *aha1542 = shost_priv(sh); in aha1542_reset() local
960 if (aha1542->int_cmds[i] != NULL) { in aha1542_reset()
962 tmp_cmd = aha1542->int_cmds[i]; in aha1542_reset()
974 aha1542->int_cmds[i] = NULL; in aha1542_reset()
975 aha1542->mb[i].status = 0; in aha1542_reset()
996 struct aha1542_hostdata *aha1542 = shost_priv(sdev->host); in aha1542_biosparam() local
999 aha1542->bios_translation == BIOS_TRANSLATION_25563) { in aha1542_biosparam()