SAM Direct Memory Access Controller Driver.
Copyright (c) 2014-2020 Microchip Technology Inc. and its subsidiaries.
Data Structures | |
struct | dma_descriptor_config |
DMA transfer descriptor configuration. More... | |
struct | dma_events_config |
Configurations for DMA events. More... | |
struct | dma_resource |
Structure for DMA transfer resource. More... | |
struct | dma_resource_config |
DMA configurations for transfer. More... | |
Macros | |
#define | DMA_INVALID_CHANNEL 0xff |
DMA invalid channel number. More... | |
Typedefs | |
typedef void(* | dma_callback_t )(struct dma_resource *const resource) |
Type definition for a DMA resource callback function. More... | |
Functions | |
void | dma_abort_job (struct dma_resource *resource) |
Abort a DMA transfer. More... | |
enum status_code | dma_add_descriptor (struct dma_resource *resource, DmacDescriptor *descriptor) |
Add a DMA transfer descriptor to a DMA resource. More... | |
enum status_code | dma_allocate (struct dma_resource *resource, struct dma_resource_config *config) |
Allocate a DMA with configurations. More... | |
void | dma_descriptor_create (DmacDescriptor *descriptor, struct dma_descriptor_config *config) |
Create a DMA transfer descriptor with configurations. More... | |
static void | dma_descriptor_get_config_defaults (struct dma_descriptor_config *config) |
Initializes DMA transfer configuration with predefined default values. More... | |
static void | dma_disable_callback (struct dma_resource *resource, enum dma_callback_type type) |
Disable a callback function for a dedicated DMA resource. More... | |
static void | dma_enable_callback (struct dma_resource *resource, enum dma_callback_type type) |
Enable a callback function for a dedicated DMA resource. More... | |
enum status_code | dma_free (struct dma_resource *resource) |
Free an allocated DMA resource. More... | |
void | dma_get_config_defaults (struct dma_resource_config *config) |
Initializes config with predefined default values. More... | |
static enum status_code | dma_get_job_status (struct dma_resource *resource) |
Get DMA resource status. More... | |
static bool | dma_is_busy (struct dma_resource *resource) |
Check if the given DMA resource is busy. More... | |
static void | dma_register_callback (struct dma_resource *resource, dma_callback_t callback, enum dma_callback_type type) |
Register a callback function for a dedicated DMA resource. More... | |
static void | dma_reset_descriptor (struct dma_resource *resource) |
Reset DMA descriptor. More... | |
void | dma_resume_job (struct dma_resource *resource) |
Resume a suspended DMA transfer. More... | |
enum status_code | dma_start_transfer_job (struct dma_resource *resource) |
Start a DMA transfer. More... | |
void | dma_suspend_job (struct dma_resource *resource) |
Suspend a DMA transfer. More... | |
static void | dma_trigger_transfer (struct dma_resource *resource) |
Will set a software trigger for resource. More... | |
static void | dma_unregister_callback (struct dma_resource *resource, enum dma_callback_type type) |
Unregister a callback function for a dedicated DMA resource. More... | |
static void | dma_update_descriptor (struct dma_resource *resource, DmacDescriptor *descriptor) |
Update DMA descriptor. More... | |
Variables | |
DmacDescriptor | descriptor_section [CONF_MAX_USED_CHANNEL_NUM] |
ExInitial description section. More... | |
uint8_t | g_chan_interrupt_flag [CONF_MAX_USED_CHANNEL_NUM] |