S32 SDK
edma_driver.c File Reference
#include "edma_driver.h"
#include "clock_manager.h"
#include "interrupt_manager.h"

Go to the source code of this file.

Functions

static status_t EDMA_DRV_RequestChannel (uint8_t requestedChannel, dma_request_source_t source, edma_chn_state_t *chn)
 
static void EDMA_DRV_ClearIntStatus (uint8_t channel)
 
static void EDMA_DRV_ClearSoftwareTCD (edma_software_tcd_t *stcd)
 
status_t EDMA_DRV_Init (edma_state_t *edmaState, const edma_user_config_t *userConfig, edma_chn_state_t *const chnStateArray[], const edma_channel_config_t *const chnConfigArray[], uint8_t chnCount)
 Initializes the eDMA module. More...
 
status_t EDMA_DRV_Deinit (void)
 De-initializes the eDMA module. More...
 
status_t EDMA_DRV_ChannelInit (edma_chn_state_t *edmaChannelState, const edma_channel_config_t *edmaChannelConfig)
 Initializes an eDMA channel. More...
 
status_t EDMA_DRV_InstallCallback (uint8_t channel, edma_callback_t callback, void *parameter)
 Registers the callback function and the parameter for eDMA channel. More...
 
status_t EDMA_DRV_ReleaseChannel (uint8_t channel)
 Releases an eDMA channel. More...
 
void EDMA_DRV_IRQHandler (uint8_t channel)
 
void EDMA_DRV_ErrorIRQHandler (void)
 
status_t EDMA_DRV_ConfigSingleBlockTransfer (uint8_t channel, edma_transfer_type_t type, uint32_t srcAddr, uint32_t destAddr, edma_transfer_size_t transferSize, uint32_t dataBufferSize)
 Configures a simple single block data transfer with DMA. More...
 
status_t EDMA_DRV_ConfigLoopTransfer (uint8_t channel, const edma_transfer_config_t *transferConfig)
 Configures the DMA transfer in loop mode. More...
 
status_t EDMA_DRV_ConfigScatterGatherTransfer (uint8_t channel, edma_software_tcd_t *stcd, edma_transfer_size_t transferSize, uint32_t bytesOnEachRequest, const edma_scatter_gather_list_t *srcList, const edma_scatter_gather_list_t *destList, uint8_t tcdCount)
 Configures the DMA transfer in a scatter-gather mode. More...
 
status_t EDMA_DRV_StartChannel (uint8_t channel)
 Starts an eDMA channel. More...
 
status_t EDMA_DRV_StopChannel (uint8_t channel)
 Stops the eDMA channel. More...
 
void EDMA_DRV_PushConfigToSTCD (const edma_transfer_config_t *config, edma_software_tcd_t *stcd)
 Copies the channel configuration to the software TCD structure. More...
 
void EDMA_DRV_PushConfigToReg (uint8_t channel, const edma_transfer_config_t *tcd)
 Copies the channel configuration to the TCD registers. More...
 
edma_chn_status_t EDMA_DRV_GetChannelStatus (uint8_t channel)
 Gets the eDMA channel status. More...
 

Variables

static edma_state_ts_edma = NULL
 EDMA global structure to maintain eDMA state. More...
 

Function Documentation

static void EDMA_DRV_ClearIntStatus ( uint8_t  channel)
static

Definition at line 398 of file edma_driver.c.

static void EDMA_DRV_ClearSoftwareTCD ( edma_software_tcd_t stcd)
static

Definition at line 411 of file edma_driver.c.

void EDMA_DRV_ErrorIRQHandler ( void  )

Definition at line 448 of file edma_driver.c.

void EDMA_DRV_IRQHandler ( uint8_t  channel)

Definition at line 428 of file edma_driver.c.

static status_t EDMA_DRV_RequestChannel ( uint8_t  requestedChannel,
dma_request_source_t  source,
edma_chn_state_t chn 
)
static

Definition at line 306 of file edma_driver.c.

Variable Documentation

edma_state_t* s_edma = NULL
static

EDMA global structure to maintain eDMA state.

Definition at line 68 of file edma_driver.c.