Zephyr Project API 4.0.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
dma_silabs_ldma.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2025 Silicon Laboratories Inc.
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
7#ifndef ZEPHYR_INCLUDE_DRIVERS_DMA_SILABS_LDMA_H_
8#define ZEPHYR_INCLUDE_DRIVERS_DMA_SILABS_LDMA_H_
9
10#include <zephyr/drivers/dma.h>
11
12#define SILABS_LDMA_SOURCE_MASK GENMASK(21, 16)
13#define SILABS_LDMA_SIG_MASK GENMASK(3, 0)
14
15#define SILABS_DMA_SLOT_SOURCE_MASK GENMASK(7, 3)
16#define SILABS_DMA_SLOT_SIG_MASK GENMASK(2, 0)
17
18#define SILABS_LDMA_REQSEL_TO_SLOT(signal) \
19 FIELD_PREP(SILABS_DMA_SLOT_SOURCE_MASK, FIELD_GET(SILABS_LDMA_SOURCE_MASK, signal)) | \
20 FIELD_PREP(SILABS_DMA_SLOT_SIG_MASK, FIELD_GET(SILABS_LDMA_SIG_MASK, signal))
21
22#define SILABS_LDMA_SLOT_TO_REQSEL(slot) \
23 FIELD_PREP(SILABS_LDMA_SOURCE_MASK, FIELD_GET(SILABS_DMA_SLOT_SOURCE_MASK, slot)) | \
24 FIELD_PREP(SILABS_LDMA_SIG_MASK, FIELD_GET(SILABS_DMA_SLOT_SIG_MASK, slot))
25
43int silabs_ldma_append_block(const struct device *dev, uint32_t channel,
44 struct dma_config *config);
45
46#endif /* ZEPHYR_INCLUDE_DRIVERS_DMA_SILABS_LDMA_H_*/
int silabs_ldma_append_block(const struct device *dev, uint32_t channel, struct dma_config *config)
Append a new block to the current channel.
Public APIs for the DMA drivers.
__UINT32_TYPE__ uint32_t
Definition stdint.h:90
Runtime device structure (in ROM) per driver instance.
Definition device.h:453
DMA configuration structure.
Definition dma.h:197