|
int32_t | Udma_proxyAlloc (Udma_DrvHandle drvHandle, Udma_ProxyHandle proxyHandle, uint16_t proxyNum) |
| UDMA proxy allocation API. More...
|
|
int32_t | Udma_proxyFree (Udma_ProxyHandle proxyHandle) |
| UDMA free proxy. More...
|
|
int32_t | Udma_proxyConfig (Udma_ProxyHandle proxyHandle, const Udma_ProxyCfg *proxyCfg) |
| UDMA proxy config API. More...
|
|
static void | Udma_proxyQueue (Udma_ProxyHandle proxyHandle, uint64_t phyDescMem) |
| UDMA queue descriptor to a proxy which is pre-configured to queue to a ring. More...
|
|
static void | Udma_proxyDequeue (Udma_ProxyHandle proxyHandle, uint64_t *phyDescMem) |
| UDMA dequeue descriptor from a proxy which is pre-configured to dequeue from a ring. More...
|
|
static void | Udma_proxyWrite64 (uintptr_t proxyAddr, uint64_t data) |
| API to write 64-bit data to proxy. More...
|
|
static void | Udma_proxyRead64 (uintptr_t proxyAddr, uint64_t *data) |
| API to read 64-bit data from proxy. More...
|
|
This is UDMA driver proxy related configuration parameters and API
◆ UDMA_PROXY_INVALID
#define UDMA_PROXY_INVALID ((uint16_t) 0xFFFFU) |
Macro used to specify that proxy ID is invalid.
◆ UDMA_PROXY_ANY
#define UDMA_PROXY_ANY ((uint16_t) 0xFFFEU) |
Macro used to specify any available free proxy while requesting one. Used in the API Udma_proxyAlloc.
◆ Udma_proxyAlloc()
int32_t Udma_proxyAlloc |
( |
Udma_DrvHandle |
drvHandle, |
|
|
Udma_ProxyHandle |
proxyHandle, |
|
|
uint16_t |
proxyNum |
|
) |
| |
UDMA proxy allocation API.
Note: In case of devices like AM64x where there is no proxy, this API is not supported and will return error.
Requirement: DOX_REQ_TAG(PDK-4156)
- Parameters
-
drvHandle | [IN] UDMA driver handle pointer passed during Udma_init |
proxyHandle | [IN/OUT] UDMA proxy handle. The caller need to allocate memory for this object and pass this pointer to all further APIs. The caller should not change any parameters as this is owned and maintained by the driver. |
proxyNum | [IN] Proxy number. If set to UDMA_PROXY_ANY, will allocate from free proxy pool. Else will try to allocate the mentioned proxy itself. |
- Returns
- Udma_ErrorCodes
◆ Udma_proxyFree()
int32_t Udma_proxyFree |
( |
Udma_ProxyHandle |
proxyHandle | ) |
|
UDMA free proxy.
Freeup the proxy resources.
Note: In case of devices like AM64x where there is no proxy, this API is not supported and will return error.
Requirement: DOX_REQ_TAG(PDK-4156)
- Parameters
-
proxyHandle | [IN] UDMA proxy handle. This parameter can't be NULL. |
- Returns
- Udma_ErrorCodes
◆ Udma_proxyConfig()
int32_t Udma_proxyConfig |
( |
Udma_ProxyHandle |
proxyHandle, |
|
|
const Udma_ProxyCfg * |
proxyCfg |
|
) |
| |
UDMA proxy config API.
This API should be called before performing any proxy operation. This same API can be used to reconfigure the proxy if the ring number changes or the ring (queue/dequeue) operation changes. If there is no change, the proxy queue/dequeue API can be called without the need to reconfigure the proxy (Thus saving CPU cycles)
Note: In case of devices like AM64x where there is no proxy, this API is not supported and will return error.
Requirement: DOX_REQ_TAG(PDK-4156)
- Parameters
-
proxyHandle | [IN] UDMA proxy handle. This parameter can't be NULL. |
proxyCfg | [IN] UDMA proxy configuration. This parameter can't be NULL. For queue operation the mode parameter should be set to CSL_PROXY_QUEUE_ACCESS_MODE_TAIL For dequeue operation the mode parameter should be set to CSL_PROXY_QUEUE_ACCESS_MODE_HEAD |
- Returns
- Udma_ErrorCodes
◆ Udma_proxyQueue()
static void Udma_proxyQueue |
( |
Udma_ProxyHandle |
proxyHandle, |
|
|
uint64_t |
phyDescMem |
|
) |
| |
|
inlinestatic |
UDMA queue descriptor to a proxy which is pre-configured to queue to a ring.
Caution: This API doesn't do any error check for performance reasons The user should ensure that the proxy is configured to perform a dequeue or queue operation to a ring. Caution: User should also ensure that the corresponding ring is not full. Performing a proxy queue operation to an already full ring will result in ring error (overflow).
Requirement: DOX_REQ_TAG(PDK-4156)
- Parameters
-
proxyHandle | [IN] UDMA proxy handle. This parameter can't be NULL. |
phyDescMem | [IN] Descriptor memory physical pointer to push to the ring. |
◆ Udma_proxyDequeue()
static void Udma_proxyDequeue |
( |
Udma_ProxyHandle |
proxyHandle, |
|
|
uint64_t * |
phyDescMem |
|
) |
| |
|
inlinestatic |
UDMA dequeue descriptor from a proxy which is pre-configured to dequeue from a ring.
Caution: This API doesn't do any error check for performance reasons The user should ensure that the proxy is configured to perform a dequeue or queue operation to a ring. Caution: User should also ensure that the corresponding ring is not empty. Performing a proxy dequeue operation to an empty ring will result in ring error (underflow).
Requirement: DOX_REQ_TAG(PDK-4156)
- Parameters
-
proxyHandle | [IN] UDMA proxy handle. This parameter can't be NULL. |
phyDescMem | [OUT] Descriptor memory physical pointer read from the ring. This will be NULL if there is nothing to pop from the ring. |
◆ Udma_proxyWrite64()
static void Udma_proxyWrite64 |
( |
uintptr_t |
proxyAddr, |
|
|
uint64_t |
data |
|
) |
| |
|
inlinestatic |
API to write 64-bit data to proxy.
Requirement: DOX_REQ_TAG(PDK-4156)
- Parameters
-
proxyAddr | [IN] Proxy data address (pre-calculated for a 64-bit write). |
data | [IN] 64-bit data to write. |
◆ Udma_proxyRead64()
static void Udma_proxyRead64 |
( |
uintptr_t |
proxyAddr, |
|
|
uint64_t * |
data |
|
) |
| |
|
inlinestatic |
API to read 64-bit data from proxy.
Requirement: DOX_REQ_TAG(PDK-4156)
- Parameters
-
proxyAddr | [IN] Proxy data address (pre-calculated for a 64-bit read). |
data | [OUT] Pointer to 64-bit word where the data is read to. |
◆ proxyMode
uint32_t Udma_ProxyCfg::proxyMode |
Initial queue access mode (see CSL_ProxyQueueAccessMode)
◆ elemSize
uint32_t Udma_ProxyCfg::elemSize |
◆ ringNum
uint16_t Udma_ProxyCfg::ringNum |
Ring number in the target to use for the proxy thread
◆ drvHandle
Udma_DrvHandle Udma_ProxyHandle::drvHandle |
Pointer to global driver handle.
◆ proxyNum
uint16_t Udma_ProxyHandle::proxyNum |
◆ proxyAddr
uintptr_t Udma_ProxyHandle::proxyAddr |
Proxy address for push/pop ring operation through proxy
◆ proxyInitDone
uint32_t Udma_ProxyHandle::proxyInitDone |
Flag to set the proxy object is init.