dma: mmp_pdma: add filter function
PXA peripherals need to obtain specific DMA request ids which will eventually be stored in the DRCMR register. Currently, clients are expected to store that number inside the slave config block as slave_id, which is unfortunately incompatible with the way DMA resources are handled in DT environments. This patch adds a filter function which stores the filter parameter passed in by of-dma.c into the channel's drcmr register. For backward compatability, cfg->slave_id is still used if set to a non-zero value. Signed-off-by: Daniel Mack <zonque@gmail.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
This commit is contained in:
15
include/linux/dma/mmp-pdma.h
Normal file
15
include/linux/dma/mmp-pdma.h
Normal file
@@ -0,0 +1,15 @@
|
||||
#ifndef _MMP_PDMA_H_
|
||||
#define _MMP_PDMA_H_
|
||||
|
||||
struct dma_chan;
|
||||
|
||||
#ifdef CONFIG_MMP_PDMA
|
||||
bool mmp_pdma_filter_fn(struct dma_chan *chan, void *param);
|
||||
#else
|
||||
static inline bool mmp_pdma_filter_fn(struct dma_chan *chan, void *param)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _MMP_PDMA_H_ */
|
Reference in New Issue
Block a user