![]() |
MCUXpresso SDK API Reference Manual
Rev 2.16.000
NXP Semiconductors
|
Group for Station Interface(SI) API and data structure. data structures are prefixed with netc_si. APIs are prefixed with NETC_SI.
Data Structures | |
struct | netc_hw_enetc_si_config_t |
Station Interface configuration. More... | |
struct | netc_si_l2mf_config_t |
L2 Mac Filter Configuration for SI. More... | |
struct | netc_si_l2vf_config_t |
L2 VLAN Filter Configuration for SI. More... | |
struct | netc_si_discard_statistic_t |
SI frame drop statistic struct. More... | |
struct | netc_si_traffic_statistic_t |
SI traffic statistic struct. More... | |
struct | netc_si_config_t |
SI Configuration. More... | |
union | netc_tx_bd_t |
Transmit Buffer Descriptor format. More... | |
union | netc_rx_bd_t |
Receive Buffer Descriptor format. More... | |
struct | netc_tx_bdr_config_t |
Configuration for the SI Tx Buffer Descriptor Ring Configuration. More... | |
struct | netc_tx_bdr_t |
Transmit BD ring handler data structure. More... | |
struct | netc_rx_bdr_config_t |
Configuration for the SI Rx Buffer Descriptor Ring Configuration. More... | |
struct | netc_rx_bdr_t |
Receive BD ring handler data structure. More... | |
struct | netc_bdr_config_t |
Configuration for the buffer descriptors ring. More... | |
struct | netc_psi_rx_msg_t |
PSI receive message information. More... | |
struct | netc_vsi_msg_tx_status_t |
VSI message transmit status. More... | |
Macros | |
#define | NETC_VLAN_PCP_DEI_VALUE(pcp, dei) (((uint8_t)((pcp)&0x7U) << 1U) | ((dei)&0x1U)) |
Macro to cover VLAN PCP, DEI value to internal used pcpDei value. More... | |
Enumerations | |
enum | netc_hw_enetc_si_vlan_type { kNETC_ENETC_StanCVlan = 0x1U, kNETC_ENETC_StanSVlan = 0x2U, kNETC_ENETC_CustomVlan1 = 0x4U, kNETC_ENETC_CustomVlan2 = 0x8U } |
VLAN Ethertypes. More... | |
enum | netc_hw_enetc_si_rxr_group { kNETC_SiBDRGroupOne = 0U, kNETC_SiBDRGroupTwo } |
SI receive BD ring group index. More... | |
enum | netc_tx_bdr_flags_t |
Status/Interrupts flags for the TX BDR. More... | |
enum | netc_rx_bdr_flags_t |
Status/Interrupts flags for the RX BDR. More... | |
enum | netc_psi_msg_flags_t { kNETC_PsiRxMsgFromVsi1Flag = 0x2, kNETC_PsiRxMsgFromVsi2Flag = 0x4, kNETC_PsiFLRFromVsi1Flag = 0x20000 } |
PSI message interrupt type. More... | |
enum | netc_vsi_msg_flags_t { kNETC_VsiMsgTxFlag = 0x1, kNETC_VsiMsgRxFlag = 0x1 << 1U } |
VSI message interrupt flags. More... | |
enum | netc_vsi_number_t |
VSI number bit map, VSI1 starts from bit1. | |
struct netc_hw_enetc_si_config_t |
Data Fields | |
uint32_t | bandWeight: 4 |
Station interface traffic class bandwidth weight. | |
uint32_t | vlanCtrl: 4 |
VLAN Ethertypes can be inserted by the SI driver, set with OR of netc_hw_enetc_si_vlan_type. More... | |
uint32_t | antiSpoofEnable: 1 |
Anti-spoofing enable. | |
uint32_t | vlanInsertEnable: 1 |
Software SI-based VLAN Insertion enable, avtive when enSIBaseVlan is true. | |
uint32_t | vlanExtractEnable: 1 |
SI-based VLAN removed from frame enable, avtive when enSIBaseVlan is true. | |
uint32_t | sourcePruneEnable: 1 |
Source pruning enable. | |
uint32_t | rxRingUse: 7 |
Number of Rx Rings to be used, when enable Rx ring group, this equal to the sum of all Rx group rings. More... | |
uint32_t | txRingUse: 7 |
Number of Tx Rings to be used, note that when SI is Switch management ENETC SI, the number not include Tx ring 0. More... | |
uint32_t | valnToIpvEnable: 1 |
Enable the VLAN PCP/DEI value (use NETC_VLAN_PCP_DEI_VALUE marco) to internal priority value mapping. More... | |
uint32_t | rxBdrGroupNum: 2 |
Rx BD ring group number, range in 0 ~ 2. More... | |
uint32_t | ringPerBdrGroup: 3 |
The ring number in every Rx BD ring group, range in 1 ~ 8, active when rxBdrGroupNum not equal zero. More... | |
netc_hw_enetc_si_rxr_group | defaultRxBdrGroup |
The selected Rx BD ring group, active when rxBdrGroupNum not equal zero. More... | |
uint8_t | vlanToIpvMap [16] |
Frame VLAN pcp|dei to IPV mapping, active when valnToIpvEnable is true. More... | |
uint8_t | ipvToRingMap [8] |
BD ring used within the default Rx BD ring group for IPV n, active when rxBdrGroupNum not equal zero. More... | |
uint8_t | vsiTcToTC [8] |
Maps the VSI traffic class to transmit traffic class, done after the ENETC txPrio to TC mapping, only available for VSI. More... | |
bool | enSIBaseVlan |
Enable use SI-based VLAN information. More... | |
netc_enetc_vlan_tag_t | siBaseVlan |
SI-based VLAN information, active when enSIBaseVlan is true. More... | |
uint32_t netc_hw_enetc_si_config_t::vlanCtrl |
uint32_t netc_hw_enetc_si_config_t::rxRingUse |
uint32_t netc_hw_enetc_si_config_t::txRingUse |
uint32_t netc_hw_enetc_si_config_t::valnToIpvEnable |
uint32_t netc_hw_enetc_si_config_t::rxBdrGroupNum |
uint32_t netc_hw_enetc_si_config_t::ringPerBdrGroup |
netc_hw_enetc_si_rxr_group netc_hw_enetc_si_config_t::defaultRxBdrGroup |
uint8_t netc_hw_enetc_si_config_t::vlanToIpvMap[16] |
uint8_t netc_hw_enetc_si_config_t::ipvToRingMap[8] |
uint8_t netc_hw_enetc_si_config_t::vsiTcToTC[8] |
bool netc_hw_enetc_si_config_t::enSIBaseVlan |
netc_enetc_vlan_tag_t netc_hw_enetc_si_config_t::siBaseVlan |
struct netc_si_l2mf_config_t |
Data Fields | |
bool | macUCPromis |
Enable/Disable MAC unicast promiscuous. More... | |
bool | macMCPromis |
Enable/Disable MAC multicast promiscuous. More... | |
bool | rejectUC |
Reject Unicast. More... | |
bool | rejectMC |
Reject Multicast. More... | |
bool | rejectBC |
Reject Broadcast. More... | |
bool netc_si_l2mf_config_t::macUCPromis |
bool netc_si_l2mf_config_t::macMCPromis |
bool netc_si_l2mf_config_t::rejectUC |
bool netc_si_l2mf_config_t::rejectMC |
bool netc_si_l2mf_config_t::rejectBC |
struct netc_si_l2vf_config_t |
Data Fields | |
bool | acceptUntagged |
Accept/Reject untagged frame. More... | |
bool | enPromis |
Enable/Disable VLAN promiscuous. More... | |
bool | useOuterVlanTag |
Use outer/inner VLAN tag for filtering. More... | |
bool netc_si_l2vf_config_t::acceptUntagged |
bool netc_si_l2vf_config_t::enPromis |
bool netc_si_l2vf_config_t::useOuterVlanTag |
struct netc_si_discard_statistic_t |
Data Fields | |
uint32_t | programError |
Due to programming error ( non-existing BD ring or non-existing group, or SI disabled or BD ring disabled). More... | |
uint32_t | busError |
Due to system bus error. More... | |
uint32_t | lackBD [14] |
Due to lack of Rx BDs available. More... | |
uint32_t netc_si_discard_statistic_t::programError |
uint32_t netc_si_discard_statistic_t::busError |
uint32_t netc_si_discard_statistic_t::lackBD[14] |
struct netc_si_traffic_statistic_t |
struct netc_si_config_t |
Data Fields | |
uint32_t | tcBWWeight |
SI traffic class bandwidth weight. More... | |
uint32_t netc_si_config_t::tcBWWeight |
union netc_tx_bd_t |
A union type cover the BD used as Standard/Extended/WriteBack format.
uint64_t netc_tx_bd_t::addr |
Little Endian.
uint16_t netc_tx_bd_t::bufLen |
uint16_t netc_tx_bd_t::frameLen |
uint32_t netc_tx_bd_t::flags |
uint32_t netc_tx_bd_t::enableInterrupt |
uint32_t netc_tx_bd_t::isExtended |
uint32_t netc_tx_bd_t::isFinal |
uint32_t netc_tx_bd_t::timestamp |
Timestamp write back.
uint32_t netc_tx_bd_t::__pad0__ |
/ Transmit timestamp identifier, only active on Switch management ENETC.
uint16_t netc_tx_bd_t::tpid |
uint16_t netc_tx_bd_t::vid |
uint16_t netc_tx_bd_t::dei |
uint16_t netc_tx_bd_t::pcp |
uint8_t netc_tx_bd_t::eFlags |
uint8_t netc_tx_bd_t::isFinal |
uint32_t netc_tx_bd_t::status |
uint32_t netc_tx_bd_t::written |
union netc_rx_bd_t |
uint64_t netc_rx_bd_t::addr |
uint16_t netc_rx_bd_t::internetChecksum |
uint16_t netc_rx_bd_t::parserSummary |
uint32_t netc_rx_bd_t::srcPort |
uint32_t netc_rx_bd_t::rssHash |
uint32_t netc_rx_bd_t::rssHashSwt |
uint16_t netc_rx_bd_t::bufLen |
uint16_t netc_rx_bd_t::vid |
uint16_t netc_rx_bd_t::dei |
uint16_t netc_rx_bd_t::pcp |
uint8_t netc_rx_bd_t::tpid |
uint8_t netc_rx_bd_t::hr |
uint8_t netc_rx_bd_t::flags |
uint8_t netc_rx_bd_t::error |
uint8_t netc_rx_bd_t::isReady |
uint8_t netc_rx_bd_t::isFinal |
uint32_t netc_rx_bd_t::timestamp |
Switch response timestamp.
uint16_t netc_rx_bd_t::txtsid |
uint32_t netc_rx_bd_t::hr |
uint32_t netc_rx_bd_t::isReady |
uint32_t netc_rx_bd_t::isFinal |
struct netc_tx_bdr_config_t |
Data Fields | |
uint32_t | len |
Size of BD ring which shall be multiple of 8 BD. More... | |
netc_tx_bd_t * | bdArray |
BDR base address which shall be 128 bytes aligned. More... | |
netc_tx_frame_info_t * | dirtyArray |
Tx cleanup ring. More... | |
bool | enIntr |
Enable/Disable completion interrupt. More... | |
bool | enThresIntr |
Enable/Disable threshold interrupt. More... | |
bool | enCoalIntr |
Enable/Disable interrupt coalescing. More... | |
uint32_t | intrThreshold |
Interrupt coalescing packet threshold. More... | |
uint32_t | intrTimerThres |
Interrupt coalescing timer threshold, specified in NETC clock cycles. More... | |
uint8_t | msixEntryIdx |
MSIX entry index of Tx ring interrupt. More... | |
bool | isVlanInsert |
Enable/Disable VLAN insert offload. More... | |
bool | isUserCRC |
Enable/Disable user provided the CRC32 - FCS at end of frame. More... | |
uint8_t | wrrWeight |
Weight used for arbitration when rings have same priority. More... | |
uint8_t | priority |
Priority of the Tx BDR. More... | |
uint32_t netc_tx_bdr_config_t::len |
netc_tx_bd_t* netc_tx_bdr_config_t::bdArray |
netc_tx_frame_info_t* netc_tx_bdr_config_t::dirtyArray |
bool netc_tx_bdr_config_t::enIntr |
bool netc_tx_bdr_config_t::enThresIntr |
bool netc_tx_bdr_config_t::enCoalIntr |
uint32_t netc_tx_bdr_config_t::intrThreshold |
uint32_t netc_tx_bdr_config_t::intrTimerThres |
uint8_t netc_tx_bdr_config_t::msixEntryIdx |
bool netc_tx_bdr_config_t::isVlanInsert |
bool netc_tx_bdr_config_t::isUserCRC |
uint8_t netc_tx_bdr_config_t::wrrWeight |
uint8_t netc_tx_bdr_config_t::priority |
struct netc_tx_bdr_t |
Data Fields | |
netc_tx_bd_t * | bdBase |
Tx BDR base address. More... | |
netc_tx_frame_info_t * | dirtyBase |
Tx cleanup ring base address. More... | |
uint16_t | producerIndex |
Current index for transmit. More... | |
uint16_t | cleanIndex |
Current index for tx cleaning. More... | |
uint32_t | len |
Length of this BD ring. More... | |
netc_tx_bd_t* netc_tx_bdr_t::bdBase |
netc_tx_frame_info_t* netc_tx_bdr_t::dirtyBase |
uint16_t netc_tx_bdr_t::producerIndex |
uint16_t netc_tx_bdr_t::cleanIndex |
uint32_t netc_tx_bdr_t::len |
struct netc_rx_bdr_config_t |
Data Fields | |
bool | extendDescEn |
False - Use 16Bytes standard BD. More... | |
netc_rx_bd_t * | bdArray |
BD ring base address which shall be 128 bytes aligned. More... | |
uint32_t | len |
BD ring length in the unit of 16Bytes standard BD. More... | |
uint64_t * | buffAddrArray |
Rx buffers array with BD length(half of BD length if use exteneded BD). More... | |
uint16_t | buffSize |
Size of all Rx buffers in this BD ring. More... | |
bool | enThresIntr |
Enable/Disable threshold interrupt. More... | |
bool | enCoalIntr |
Enable/Disable interrupt coalescing. More... | |
uint32_t | intrThreshold |
Interrupt coalescing packet threshold. More... | |
uint32_t | intrTimerThres |
Interrupt coalescing timer threshold, specified in NETC clock cycles. More... | |
uint8_t | msixEntryIdx |
MSIX entry index of Rx ring interrupt. More... | |
bool | disVlanPresent |
Disable/Enable VLAN in BD. More... | |
bool | enVlanExtract |
Enable/Disable VLAN extract. More... | |
bool | isKeepCRC |
Whether user provided the CRC32 - FCS at end of frame. More... | |
bool | congestionMode |
False - lossy. More... | |
bool | enHeaderAlign |
Enable/disable +2B alignment to frame. More... | |
bool netc_rx_bdr_config_t::extendDescEn |
True - Use 32Bytes extended BD.
netc_rx_bd_t* netc_rx_bdr_config_t::bdArray |
uint32_t netc_rx_bdr_config_t::len |
Shall be multiple of 8/16 for standard/exteneded BD.
uint64_t* netc_rx_bdr_config_t::buffAddrArray |
uint16_t netc_rx_bdr_config_t::buffSize |
bool netc_rx_bdr_config_t::enThresIntr |
bool netc_rx_bdr_config_t::enCoalIntr |
uint32_t netc_rx_bdr_config_t::intrThreshold |
uint32_t netc_rx_bdr_config_t::intrTimerThres |
uint8_t netc_rx_bdr_config_t::msixEntryIdx |
bool netc_rx_bdr_config_t::disVlanPresent |
bool netc_rx_bdr_config_t::enVlanExtract |
bool netc_rx_bdr_config_t::isKeepCRC |
bool netc_rx_bdr_config_t::congestionMode |
True - lossless.
bool netc_rx_bdr_config_t::enHeaderAlign |
struct netc_rx_bdr_t |
Data Fields | |
netc_rx_bd_t * | bdBase |
Rx BDR base address. More... | |
bool | extendDesc |
Use extended buffer descriptor. More... | |
uint16_t | index |
Current index for read. More... | |
uint32_t | len |
Length of this BD ring, unit of 16Bytes standard BD. More... | |
uint64_t * | buffArray |
Rx buffers array of this ring. More... | |
uint32_t | buffSize |
Rx buffers size for all BDs in this ring. More... | |
netc_rx_bd_t* netc_rx_bdr_t::bdBase |
bool netc_rx_bdr_t::extendDesc |
uint16_t netc_rx_bdr_t::index |
uint32_t netc_rx_bdr_t::len |
uint64_t* netc_rx_bdr_t::buffArray |
uint32_t netc_rx_bdr_t::buffSize |
struct netc_bdr_config_t |
Data Fields | |
netc_rx_bdr_config_t * | rxBdrConfig |
Receive buffer ring configuration array. More... | |
netc_tx_bdr_config_t * | txBdrConfig |
Transmit buffer ring configuration array. More... | |
netc_rx_bdr_config_t* netc_bdr_config_t::rxBdrConfig |
netc_tx_bdr_config_t* netc_bdr_config_t::txBdrConfig |
struct netc_psi_rx_msg_t |
struct netc_vsi_msg_tx_status_t |
Data Fields | |
bool | txBusy |
The VSI Tx busy flag, become idle when the PSI receive and clear the related status. More... | |
bool | isTxErr |
Tx error flag. More... | |
uint16_t | msgCode |
The error code or user-defined content. More... | |
bool netc_vsi_msg_tx_status_t::txBusy |
bool netc_vsi_msg_tx_status_t::isTxErr |
uint16_t netc_vsi_msg_tx_status_t::msgCode |
#define NETC_VLAN_PCP_DEI_VALUE | ( | pcp, | |
dei | |||
) | (((uint8_t)((pcp)&0x7U) << 1U) | ((dei)&0x1U)) |
enum netc_tx_bdr_flags_t |
Each flag get its own bit thus it support bit AND/OR operation.
enum netc_rx_bdr_flags_t |
Each flag get its own bit thus it support bit AND/OR operation.
enum netc_psi_msg_flags_t |
enum netc_vsi_msg_flags_t |