Lines Matching defs:iopb

107  * XYC_GO: start iopb ADDR (DVMA addr in a u_long) on XYC
397 * init iorq to iopb pointers, and non-zero fields in the
398 * iopb which never change.
403 xyc->reqs[lcv].iopb = &xyc->iopbase[lcv];
1144 xyc_rqtopb(struct xy_iorq *iorq, struct xy_iopb *iopb, int cmd, int subfun)
1151 iopb->ien = (XY_STATE(iorq->mode) == XY_SUB_POLL) ? 0 : 1;
1152 iopb->com = cmd;
1153 iopb->errno = 0;
1154 iopb->errs = 0;
1155 iopb->done = 0;
1157 iopb->unit = iorq->xy->xy_drive;
1158 iopb->dt = iorq->xy->drive_type;
1160 iopb->unit = 0;
1161 iopb->dt = 0;
1165 iopb->sect = iopb->head = iopb->cyl = 0;
1167 iopb->sect = block % iorq->xy->nsect;
1169 iopb->head = block % iorq->xy->nhead;
1171 iopb->cyl = block;
1173 iopb->scnt = iorq->sectcnt;
1175 iopb->dataa = 0;
1176 iopb->datar = 0;
1179 iopb->dataa = (dp & 0xffff);
1180 iopb->datar = ((dp & 0xff0000) >> 16);
1182 iopb->subfn = subfun;
1211 struct xy_iopb *iopb = xycsc->ciopb;
1227 printf("%s: stole control iopb\n", device_xname(xycsc->sc_dev));
1230 /* init iorq/iopb */
1238 xyc_rqtopb(iorq, iopb, cmd, subfn);
1256 struct xy_iopb *iopb;
1261 iopb = iorq->iopb;
1308 /* init iorq and load iopb from it */
1313 xyc_rqtopb(iorq, iopb, (bp->b_flags & B_READ) ? XYCMD_RD : XYCMD_WR, 0);
1341 * iopb structure. the hardware understands the iopb structure.
1342 * every command must go through an iopb. a 450 handles one iopb at a
1344 * can handle chains, but is appears to be buggy...] iopb are allocated
1345 * in DVMA space at boot up time. each disk gets one iopb, and the
1347 * the iopb is busy? for i/o type [1], the buffers are queued at the
1358 struct xy_iopb *iopb;
1377 while (iorq->iopb->done == 0) {
1394 iopb = xyc_chain(xycsc, iorq); /* build chain */
1395 if (iopb == NULL) { /* nothing doing? */
1400 iopbaddr = dvma_kvtopa(iopb, xycsc->bustype);
1410 while (iorq->iopb->done == 0) {
1433 struct xy_iopb *iopb, *prev_iopb;
1453 iorq->iopb->chen = 0;
1454 return iorq->iopb;
1473 iopb = xycsc->xy_chain[chain]->iopb;
1474 iopb->chen = 0;
1476 prev_iopb = xycsc->xy_chain[chain-1]->iopb;
1479 dvma_kvtopa(iopb, xycsc->bustype);
1487 return iorq ? iorq->iopb : NULL;
1508 while (iorq->iopb->done == 0) {
1531 if (iorq->iopb->done == 0)
1553 * we steal iopb[XYC_CTLIOPB] for this, but we put it back when we are done.
1702 struct xy_iopb *iopb;
1723 * get iopb that is done, loop down the chain
1738 iopb = iorq->iopb;
1739 if (iopb->done == 0)
1742 comm = iopb->com;
1743 errs = iopb->errs;
1746 iorq->errno = iopb->errno;
1753 xyc_error(xycsc, iorq, iopb, comm) == XY_ERR_AOK)
1760 xyc_perror(iorq, iopb, 0);
1782 iorq->lasterror = iorq->errno = iopb->errno = 0;
1783 iopb->errs = iopb->done = 0;
1785 iopb->scnt = iorq->sectcnt;
1786 iopb->cyl =
1788 iopb->head =
1791 iopb->sect = iorq->blockno % XYFM_BPS;
1793 iopb->dataa = (addr & 0xffff);
1794 iopb->datar = ((addr & 0xff0000) >> 16);
1842 xyc_perror(struct xy_iorq *iorq, struct xy_iopb *iopb, int still_trying)
1850 if (iopb->com == XYCMD_RD || iopb->com == XYCMD_WR)
1852 (iopb->com == XYCMD_RD) ? "read" : "write",
1853 iopb->cyl, iopb->head, iopb->sect);
1867 * return AOK if resubmitted, return FAIL if this iopb is done
1870 xyc_error(struct xyc_softc *xycsc, struct xy_iorq *iorq, struct xy_iopb *iopb,
1889 advance = iorq->sectcnt - iopb->scnt;
1897 iopb->errno = iopb->done = iopb->errs = 0;
1898 iopb->scnt = 1;
1899 iopb->cyl = (iorq->xy->ncyl + iorq->xy->acyl) - 2;
1903 iopb->head = i / iorq->xy->nhead;
1904 iopb->sect = i % iorq->xy->nhead;
1915 xyc_perror(iorq, iopb, 1); /* inform of error state
1922 iorq->errno = iopb->errno = iopb->done = iopb->errs = 0;