Lines Matching defs:dwc
12 static void idma32_initialize_chan(struct dw_dma_chan *dwc)
21 cfghi |= IDMA32C_CFGH_DST_PER(dwc->dws.dst_id & 0xf);
22 cfghi |= IDMA32C_CFGH_SRC_PER(dwc->dws.src_id & 0xf);
25 cfghi |= IDMA32C_CFGH_DST_PER_EXT(dwc->dws.dst_id >> 4 & 0x3);
26 cfghi |= IDMA32C_CFGH_SRC_PER_EXT(dwc->dws.src_id >> 4 & 0x3);
28 channel_writel(dwc, CFG_LO, cfglo);
29 channel_writel(dwc, CFG_HI, cfghi);
32 static void idma32_suspend_chan(struct dw_dma_chan *dwc, bool drain)
34 u32 cfglo = channel_readl(dwc, CFG_LO);
39 channel_writel(dwc, CFG_LO, cfglo | DWC_CFGL_CH_SUSP);
42 static void idma32_resume_chan(struct dw_dma_chan *dwc, bool drain)
44 u32 cfglo = channel_readl(dwc, CFG_LO);
49 channel_writel(dwc, CFG_LO, cfglo & ~DWC_CFGL_CH_SUSP);
52 static u32 idma32_bytes2block(struct dw_dma_chan *dwc,
57 if (bytes > dwc->block_size) {
58 block = dwc->block_size;
59 *len = dwc->block_size;
68 static size_t idma32_block2bytes(struct dw_dma_chan *dwc, u32 block, u32 width)
73 static u32 idma32_prepare_ctllo(struct dw_dma_chan *dwc)
75 struct dma_slave_config *sconfig = &dwc->dma_sconfig;
76 u8 smsize = (dwc->direction == DMA_DEV_TO_MEM) ? sconfig->src_maxburst : 0;
77 u8 dmsize = (dwc->direction == DMA_MEM_TO_DEV) ? sconfig->dst_maxburst : 0;
83 static void idma32_encode_maxburst(struct dw_dma_chan *dwc, u32 *maxburst)