32#define DMAMUX_CxCR(dmamux_base, dma_channel) MMIO32((dmamux_base) + 0x04 * ((dma_channel) - 1))
33#define DMAMUX1_CxCR(dma_channel) DMAMUX_CxCR(DMAMUX1, (dma_channel))
34#define DMAMUX2_CxCR(dma_channel) DMAMUX_CxCR(DMAMUX2, (dma_channel))
36#define DMAMUX_CSR(dmamux_base) MMIO32((dmamux_base) + 0x80)
37#define DMAMUX1_CSR DMAMUX_CSR(DMAMUX1)
38#define DMAMUX2_CSR DMAMUX_CSR(DMAMUX2)
40#define DMAMUX_CFR(dmamux_base) MMIO32((dmamux_base) + 0x84)
41#define DMAMUX1_CFR DMAMUX_CFR(DMAMUX1)
42#define DMAMUX2_CFR DMAMUX_CFR(DMAMUX2)
44#define DMAMUX_RGxCR(dmamux_base, rg_channel) MMIO32((dmamux_base) + 0x100 + 0x04 * ((rg_channel) - 1))
45#define DMAMUX1_RGxCR(rg_channel) DMAMUX_RGxCR(DMAMUX1, (rg_channel))
46#define DMAMUX2_RGxCR(rg_channel) DMAMUX_RGxCR(DMAMUX2, (rg_channel))
48#define DMAMUX_RGSR(dmamux_base) MMIO32((dmamux_base) + 0x140)
49#define DMAMUX1_RGSR DMAMUX_RSGR(DMAMUX1)
50#define DMAMUX2_RGSR DMAMUX_RSGR(DMAMUX2)
52#define DMAMUX_RGCFR(dmamux_base) MMIO32((dmamux_base) + 0x144)
53#define DMAMUX1_RGCFR DMAMUX_RGCFR(DMAMUX1)
54#define DMAMUX2_RGCFR DMAMUX_RGCFR(DMAMUX2)
60#define DMAMUX_CxCR_SYNC_ID_SHIFT 24
61#define DMAMUX_CxCR_SYNC_ID_MASK 0x1f
64#define DMAMUX_CxCR_NBREQ_SHIFT 19
65#define DMAMUX_CxCR_NBREQ_MASK 0x1f
67#define DMAMUX_CxCR_SPOL_SHIFT 17
68#define DMAMUX_CxCR_SPOL_MASK 0x03
72#define DMAMUX_CxCR_SPOL_NO_EVENT 0
73#define DMAMUX_CxCR_SPOL_RISING_EDGE 1
74#define DMAMUX_CxCR_SPOL_FALLING_EDEG 2
75#define DMAMUX_CxCR_SPOL_BOTH_EDGES 3
79#define DMAMUX_CxCR_SE (1 << 16)
82#define DMAMUX_CxCR_EGE (1 << 9)
85#define DMAMUX_CxCR_SOIE (1 << 8)
88#define DMAMUX_CxCR_DMAREQ_ID_SHIFT 0
89#define DMAMUX_CxCR_DMAREQ_ID_MASK 0xff
97#define DMAMUX_CSR_SOF(dma_channel) (1 << ((dma_channel) - 1))
105#define DMAMUX_CFR_CSOF(dma_channel) (1 << ((dma_channel) - 1))
113#define DMAMUX_RGxCR_GNBREQ_SHIFT 19
114#define DMAMUX_RGxCR_GNBREQ_MASK 0x1f
116#define DMAMUX_RGxCR_GPOL_SHIFT 17
117#define DMAMUX_RGxCR_GPOL_MASK 0x03
121#define DMAMUX_RGxCR_GPOL_NO_EVENT 0
122#define DMAMUX_RGxCR_GPOL_RISING_EDGE 1
123#define DMAMUX_RGxCR_GPOL_FALLING_EDEG 2
124#define DMAMUX_RGxCR_GPOL_BOTH_EDGES 3
128#define DMAMUX_RGxCR_GE (1 << 16)
131#define DMAMUX_RGxCR_OIE (1 << 8)
134#define DMAMUX_RGxCR_SIG_ID_SHIFT 0
135#define DMAMUX_RGxCR_SIG_ID_MASK 0x1f
143#define DMAMUX_RGSR_OF(rg_channel) (1 << ((rg_channel) - 1))
151#define DMAMUX_RGCFR_COF(rg_channel) (1 << ((rg_channel) - 1))
159#define DMAMUX_RG_CHANNEL1 1
160#define DMAMUX_RG_CHANNEL2 2
161#define DMAMUX_RG_CHANNEL3 3
162#define DMAMUX_RG_CHANNEL4 4
void dmamux_set_request_generator_trigger(uint32_t dmamux, uint8_t rg_channel, uint8_t sig_id)
DMAMUX Set Request Generator Input Trigger Signal.
void dmamux_set_dma_request_sync_input(uint32_t dmamux, uint8_t channel, uint8_t sync_id)
DMAMUX Set DMA Request Synchronization Input.
void dmamux_disable_dma_request_sync_overrun_interrupt(uint32_t dmamux, uint8_t channel)
DMAMUX Disable DMA Request Overrun Interrupt.
void dmamux_enable_dma_request_sync(uint32_t dmamux, uint8_t channel)
DMAMUX Enable DMA Request Synchronization.
void dmamux_disable_request_generator_trigger_overrun_interrupt(uint32_t dmamux, uint8_t rg_channel)
DMAMUX Disable Request Generator Trigger Overrun Interrupt.
void dmamux_enable_request_generator_trigger_overrun_interrupt(uint32_t dmamux, uint8_t rg_channel)
DMAMUX Enable Request Generator Trigger Overrun Interrupt.
void dmamux_enable_dma_request_sync_overrun_interrupt(uint32_t dmamux, uint8_t channel)
DMAMUX Enable DMA Request Overrun Interrupt.
uint32_t dmamux_get_dma_request_sync_overrun(uint32_t dmamux, uint8_t channel)
DMAMUX Get DMA Request Synchronization Overrun Interrupt Flag.
void dmamux_disable_request_generator(uint32_t dmamux, uint8_t rg_channel)
DMAMUX Disable Request Generator Channel.
void dmamux_clear_request_generator_trigger_overrun_interrupt(uint32_t dmamux, uint8_t rg_channel)
DMAMUX Clear Request Generator Trigger Overrun Interrupt Flag.
void dmamux_reset_dma_channel(uint32_t dmamux, uint8_t channel)
DMAMUX Reset DMA Channel.
void dmamux_enable_dma_request_event_generation(uint32_t dmamux, uint8_t channel)
DMAMUX Enable DMA Request Event Generation.
void dmamux_clear_dma_request_sync_overrun(uint32_t dmamux, uint8_t channel)
DMAMUX Clear DMA Request Synchronization Overrun Interrupt Flag.
void dmamux_set_dma_channel_request(uint32_t dmamux, uint8_t channel, uint8_t request_id)
DMAMUX Set DMA Channel Request.
uint8_t dmamux_get_dma_channel_request(uint32_t dmamux, uint8_t channel)
DMAMUX Get DMA Channel Request Selection.
uint32_t dmamux_get_request_generator_trigger_overrun_interrupt(uint32_t dmamux, uint8_t rg_channel)
DMAMUX Get Request Generator Trigger Overrun Interrupt Flag.
void dmamux_set_request_generator_trigger_gnbreq(uint32_t dmamux, uint8_t rg_channel, uint8_t gnbreq)
DMAMUX Set Request Generator Trigger GNBREQ.
void dmamux_set_dma_request_sync_nbreq(uint32_t dmamux, uint8_t channel, uint8_t nbreq)
DMAMUX Set DMA Request NBREQ To Forward.
void dmamux_disable_dma_request_sync(uint32_t dmamux, uint8_t channel)
DMAMUX Disable DMA Request Synchronization.
void dmamux_enable_request_generator(uint32_t dmamux, uint8_t rg_channel)
DMAMUX Enable Request Generator Channel.
void dmamux_set_dma_request_sync_pol(uint32_t dmamux, uint8_t channel, uint8_t polarity)
DMAMUX Set DMA Request Synchronization Event Polarity.
void dmamux_reset_request_generator_channel(uint32_t dmamux, uint8_t rg_channel)
DMAMUX Reset Request Generator Channel.
void dmamux_disable_dma_request_event_generation(uint32_t dmamux, uint8_t channel)
DMAMUX Disable DMA Request Event Generation.
void dmamux_set_request_generator_trigger_pol(uint32_t dmamux, uint8_t rg_channel, uint8_t polarity)
DMAMUX Set Request Generator Trigger Polarity.