AM261x MCU+ SDK: enet_cpdma.h File Reference

| AM261x MCU+ SDK 26.00.00 |

Data Structures | Macros | Typedefs | Functions
enet_cpdma.h File Reference

## Introduction

This file contains the type definitions and helper macros for the Enet CPDMA data path (DMA) interface.

Go to the source code of this file.

## Data Structures
struct | EnetCpdma_PktTsInfo
| CPPI buffer timestamp info. More...
struct | EnetCpdma_SGListEntry
| Transmit Packet scatter gather list entry. More...
struct | EnetCpdma_SGList
| Transmit packet scatter list info. More...
struct | EnetCpdma_PktInfo
| Packet data structure. More...
struct | EnetCpdma_OpenTxChPrms
| Param struct for the TX channel open function. More...
struct | EnetCpdma_OpenRxChPrms
| Param struct for the RX channel open function. More...
struct | EnetCpdma_RxChInitPrms
| Global Param struct for the Rx channel open. More...
struct | EnetDma_Cfg
| Config structure for Enet CPDMA. More...
struct | EnetDma_initCfg
| Config structure for Enet CPDMA Data Path initialization. More...

## Macros
#define | ENET_CPDMA_CPSW_MAX_SG_LIST (4U)
#define | ENET_CPDMA_CSUM_START_BYTE_SHIFT (16U)
#define | ENET_CPDMA_CSUM_START_BYTE_MASK (((uint32_t) 0xFFU) << ENET_CPDMA_CSUM_START_BYTE_SHIFT)
#define | ENET_CPDMA_CSUM_RESULT_BYTE_SHIFT (24U)
#define | ENET_CPDMA_CSUM_RESULT_BYTE_MASK (((uint32_t) 0xFFU) << ENET_CPDMA_CSUM_RESULT_BYTE_SHIFT)
#define | ENET_CPDMA_CSUM_BYTE_COUNT_SHIFT (0U)
#define | ENET_CPDMA_CSUM_BYTE_COUNT_MASK (((uint32_t) 0x3FFU) << ENET_CPDMA_CSUM_BYTE_COUNT_SHIFT)
#define | ENET_CPDMA_GET_CSUM_RESULT_BYTE(chkSumInfo) ENET_FEXT(chkSumInfo, ENET_CPDMA_CSUM_RESULT_BYTE)
#define | ENET_CPDMA_GET_CSUM_START_BYTE(chkSumInfo) ENET_FEXT(chkSumInfo, ENET_CPDMA_CSUM_START_BYTE)
#define | ENET_CPDMA_GET_CSUM_BYTE_COUNT(chkSumInfo) ENET_FEXT(chkSumInfo, ENET_CPDMA_CSUM_BYTE_COUNT)
Enet CPDMA instance configuration
Configuration macros for Enet CPDMA module.
#define | ENET_CPDMA_CPSW_MAX_TX_CH (8U)
| Maximum number of CPSW TX DMA channels. More...
#define | ENET_CPDMA_CPSW_MAX_RX_CH (8U)
| Maximum number of CPSW RX DMA channels. More...

## Typedefs
typedef EnetQ | EnetDma_PktQ
| Packet queue. More...
typedef EnetCpdma_SGListEntry | EnetDma_SGListEntry
typedef EnetCpdma_OpenRxChPrms | EnetDma_OpenRxChPrms
| Param struct for the RX channel open function. We include this typedef as top level DMA APIs use EnetDma_OpenRxChPrms struct. More...
Enet DMA driver opaque handles
Enet DMA configuration structure. Opaque handle typedefs for Enet DMA driver objects.
typedef void(* | EnetDma_PktNotifyCb) (void *cbArg)
| Function pointer type for packet notify call back. More...

## Functions
void | EnetCpdma_initRxChParams (EnetCpdma_OpenRxChPrms *pRxChPrms)
| Initialize RX channel open parameters. More...
EnetDma_RxChHandle | EnetCpdma_openRxCh (EnetDma_Handle hDma, const EnetCpdma_OpenRxChPrms *pRxChPrms)
| Enet DMA open RX channel. More...
int32_t | EnetCpdma_closeRxCh (EnetDma_RxChHandle hRxCh, EnetDma_PktQ *fq, EnetDma_PktQ *cq)
| Enet DMA close RX channel. More...
void | EnetCpdma_initTxChParams (EnetCpdma_OpenTxChPrms *pTxChPrms)
| Initialize TX channel open parameters. More...
EnetDma_TxChHandle | EnetCpdma_openTxCh (EnetDma_Handle hDma, const EnetCpdma_OpenTxChPrms *pTxChPrms)
| Enet DMA open TX channel. More...
int32_t | EnetCpdma_closeTxCh (EnetDma_TxChHandle hTxCh, EnetDma_PktQ *fq, EnetDma_PktQ *cq)
| Enet DMA close TX channel. More...
EnetDma_Handle | EnetCpdma_open (Enet_Type enetType, uint32_t instId, const EnetDma_Cfg *dmaCfg, uint32_t appCoreId)
| Set default data path parameters. More...
EnetDma_Handle | EnetCpdma_restoreCtxt (Enet_Type enetType, uint32_t instId, uint32_t appCoreId)
| Open DMA with default data path parameters. More...
int32_t | EnetCpdma_close (EnetDma_Handle hEnetDma)
| Close Enet DMA (data path). More...
int32_t | EnetCpdma_saveCtxt (EnetDma_Handle hEnetDma)
| Saves and closes Enet DMA (data path). More...
int32_t | EnetCpdma_rxThreshIsr (EnetDma_Handle hEnetDma)
| ENET CPDMA Rx Threshold interrupt service routine. More...
int32_t | EnetCpdma_rxIsr (EnetDma_Handle hEnetDma)
| ENET CPDMA Rx interrupt service routine. More...
int32_t | EnetCpdma_txIsr (EnetDma_Handle hEnetDma)
| ENET CPDMA Tx interrupt service routine. More...
int32_t | EnetCpdma_miscIsrGetStatus (EnetDma_Handle hEnetDma, uint32_t *pStatusMask)
| ENET CPDMA Miscellaneous interrupt service routine. More...
int32_t | EnetCpdma_ackMiscIsr (EnetDma_Handle hEnetDma)
void | EnetCpdma_initParams (EnetDma_Cfg *pDmaConfig)
| Initialize CPDMA config params. More...