Lines Matching full:xp

162 	struct ps3cdrom_xfer *xp;  in ps3cdrom_attach()  local
208 xp = &sc->sc_xfer[i]; in ps3cdrom_attach()
209 xp->x_sc = sc; in ps3cdrom_attach()
212 &xp->x_dmamap); in ps3cdrom_attach()
219 TAILQ_INSERT_TAIL(&sc->sc_free_xferq, xp, x_queue); in ps3cdrom_attach()
287 while ((xp = TAILQ_FIRST(&sc->sc_free_xferq))) { in ps3cdrom_attach()
288 TAILQ_REMOVE(&sc->sc_free_xferq, xp, x_queue); in ps3cdrom_attach()
289 bus_dmamap_destroy(sc->sc_dmatag, xp->x_dmamap); in ps3cdrom_attach()
340 struct ps3cdrom_xfer *xp; in ps3cdrom_action() local
363 xp = TAILQ_FIRST(&sc->sc_free_xferq); in ps3cdrom_action()
365 KASSERT(xp != NULL, ("no free transfers")); in ps3cdrom_action()
367 xp->x_ccb = ccb; in ps3cdrom_action()
369 TAILQ_REMOVE(&sc->sc_free_xferq, xp, x_queue); in ps3cdrom_action()
371 err = bus_dmamap_load_ccb(sc->sc_dmatag, xp->x_dmamap, in ps3cdrom_action()
372 ccb, ps3cdrom_transfer, xp, 0); in ps3cdrom_action()
377 xp->x_ccb = NULL; in ps3cdrom_action()
378 TAILQ_INSERT_TAIL(&sc->sc_free_xferq, xp, x_queue); in ps3cdrom_action()
470 struct ps3cdrom_xfer *xp; in ps3cdrom_intr() local
482 TAILQ_FOREACH(xp, &sc->sc_active_xferq, x_queue) { in ps3cdrom_intr()
483 if (xp->x_tag == tag) in ps3cdrom_intr()
487 if (xp) { in ps3cdrom_intr()
488 ccb = xp->x_ccb; in ps3cdrom_intr()
528 bus_dmamap_sync(sc->sc_dmatag, xp->x_dmamap, in ps3cdrom_intr()
531 bus_dmamap_unload(sc->sc_dmatag, xp->x_dmamap); in ps3cdrom_intr()
533 xp->x_ccb = NULL; in ps3cdrom_intr()
534 TAILQ_REMOVE(&sc->sc_active_xferq, xp, x_queue); in ps3cdrom_intr()
535 TAILQ_INSERT_TAIL(&sc->sc_free_xferq, xp, x_queue); in ps3cdrom_intr()
549 struct ps3cdrom_xfer *xp = (struct ps3cdrom_xfer *) arg; in ps3cdrom_transfer() local
550 struct ps3cdrom_softc *sc = xp->x_sc; in ps3cdrom_transfer()
553 union ccb *ccb = xp->x_ccb; in ps3cdrom_transfer()
567 xp->x_ccb = NULL; in ps3cdrom_transfer()
568 TAILQ_INSERT_TAIL(&sc->sc_free_xferq, xp, x_queue); in ps3cdrom_transfer()
591 &xp->x_tag); in ps3cdrom_transfer()
592 bus_dmamap_sync(sc->sc_dmatag, xp->x_dmamap, in ps3cdrom_transfer()
601 bus_dmamap_sync(sc->sc_dmatag, xp->x_dmamap, in ps3cdrom_transfer()
605 segs[0].ds_addr, &xp->x_tag); in ps3cdrom_transfer()
633 bus_dmamap_sync(sc->sc_dmatag, xp->x_dmamap, in ps3cdrom_transfer()
639 &xp->x_tag); in ps3cdrom_transfer()
649 bus_dmamap_unload(sc->sc_dmatag, xp->x_dmamap); in ps3cdrom_transfer()
651 xp->x_ccb = NULL; in ps3cdrom_transfer()
652 TAILQ_INSERT_TAIL(&sc->sc_free_xferq, xp, x_queue); in ps3cdrom_transfer()
671 xp->x_tag)); in ps3cdrom_transfer()
673 TAILQ_INSERT_TAIL(&sc->sc_active_xferq, xp, x_queue); in ps3cdrom_transfer()