Lines Matching refs:channel
51 dbdma_channel_t *channel = (dbdma_channel_t *)(chan); in dbdma_phys_callback() local
53 channel->sc_slots_pa = segs[0].ds_addr; in dbdma_phys_callback()
54 dbdma_write_reg(channel, CHAN_CMDPTR, channel->sc_slots_pa); in dbdma_phys_callback()
62 dbdma_channel_t *channel; in dbdma_allocate_channel() local
64 channel = *chan = malloc(sizeof(struct dbdma_channel), M_DBDMA, in dbdma_allocate_channel()
67 channel->sc_regs = dbdma_regs; in dbdma_allocate_channel()
68 channel->sc_off = offset; in dbdma_allocate_channel()
69 dbdma_stop(channel); in dbdma_allocate_channel()
71 channel->sc_slots_pa = 0; in dbdma_allocate_channel()
75 NULL, &(channel->sc_dmatag)); in dbdma_allocate_channel()
77 error = bus_dmamem_alloc(channel->sc_dmatag, in dbdma_allocate_channel()
78 (void **)&channel->sc_slots, BUS_DMA_WAITOK | BUS_DMA_ZERO, in dbdma_allocate_channel()
79 &channel->sc_dmamap); in dbdma_allocate_channel()
81 error = bus_dmamap_load(channel->sc_dmatag, channel->sc_dmamap, in dbdma_allocate_channel()
82 channel->sc_slots, PAGE_SIZE, dbdma_phys_callback, channel, 0); in dbdma_allocate_channel()
84 dbdma_write_reg(channel, CHAN_CMDPTR_HI, 0); in dbdma_allocate_channel()
86 channel->sc_nslots = slots; in dbdma_allocate_channel()