SURF  1.0
EthMacPkg Package Reference
Package Body >> EthMacPkg

Functions

Slv16Array   EthPortArrayBigEndian ( portNum: in PositiveArray , portSize: in positive )

Procedures

  GetEthMacCsum(
udpDet: in sl
last: in sl
hdr: in Slv8Array ( 19 downto 0 )
tKeep: in slv ( 15 downto 0 )
tData: in slv ( 127 downto 0 )
len: in slv ( 15 downto 0 )
ibcsum: in slv ( 15 downto 0 )
r: in EthMacCsumAccumArray ( 1 downto 0 )
v: inout EthMacCsumAccumArray ( 1 downto 0 )
ipValid: inout sl
ipCsum: inout slv ( 15 downto 0 )
valid: inout sl
csum: inout slv ( 15 downto 0 )
)

Libraries

ieee 

Use Clauses

std_logic_1164 
std_logic_unsigned 
std_logic_arith 
StdRtlPkg  Package <StdRtlPkg>
AxiStreamPkg  Package <AxiStreamPkg>

Constants

EMAC_ADDR_INIT_C  slv ( 47 downto 0 ) := x " 020300564400 "
ARP_TYPE_C  slv ( 15 downto 0 ) := x " 0608 "
IPV4_TYPE_C  slv ( 15 downto 0 ) := x " 0008 "
VLAN_TYPE_C  slv ( 15 downto 0 ) := x " 0081 "
UDP_C  slv ( 7 downto 0 ) := x " 11 "
TCP_C  slv ( 7 downto 0 ) := x " 06 "
ICMP_C  slv ( 7 downto 0 ) := x " 01 "
DHCP_CPORT  slv ( 15 downto 0 ) := x " 4400 "
DHCP_SPORT  slv ( 15 downto 0 ) := x " 4300 "
EMAC_FRAG_BIT_C  integer := 0
EMAC_SOF_BIT_C  integer := 1
EMAC_EOFE_BIT_C  integer := 0
EMAC_IPERR_BIT_C  integer := 1
EMAC_TCPERR_BIT_C  integer := 2
EMAC_UDPERR_BIT_C  integer := 3
EMAC_AXIS_CONFIG_C  AxiStreamConfigType := ( TSTRB_EN_C = > false , TDATA_BYTES_C = > 16 , TDEST_BITS_C = > 8 , TID_BITS_C = > 0 , TKEEP_MODE_C = > TKEEP_COMP_C , TUSER_BITS_C = > 4 , TUSER_MODE_C = > TUSER_FIRST_LAST_C )
ETH_MAC_CONFIG_INIT_C  EthMacConfigType := ( macAddress = > EMAC_ADDR_INIT_C , filtEnable = > ' 1 ' , pauseEnable = > ' 1 ' , pauseTime = > x " 00FF " , ipCsumEn = > ' 1 ' , tcpCsumEn = > ' 1 ' , udpCsumEn = > ' 1 ' , dropOnPause = > ' 0 ' )
ETH_MAC_STATUS_INIT_C  EthMacStatusType := ( rxFifoDropCnt = > ' 0 ' , rxPauseCnt = > ' 0 ' , txPauseCnt = > ' 0 ' , rxCountEn = > ' 0 ' , rxOverFlow = > ' 0 ' , rxCrcErrorCnt = > ' 0 ' , txCountEn = > ' 0 ' , txUnderRunCnt = > ' 0 ' , txNotReadyCnt = > ' 0 ' )
EMAC_CSUM_PIPELINE_C  natural := 3
ETH_MAC_CSUM_ACCUM_INIT_C  EthMacCsumAccumType := ( step = > ( others = > ' 0 ' ) , sum1 = > ( others = > ( others = > ' 0 ' ) ) , sum3 = > ( others = > ' 0 ' ) , sum5 = > ( others = > ' 0 ' ) )

Types

EthMacConfigArray array ( natural range <> ) of EthMacConfigType
EthMacStatusArray array ( natural range <> ) of EthMacStatusType
EthMacCsumAccumArray array ( natural range <> ) of EthMacCsumAccumType

Records

EthMacConfigType  
macAddress  slv ( 47 downto 0 )
filtEnable  sl
pauseEnable  sl
pauseTime  slv ( 15 downto 0 )
ipCsumEn  sl
tcpCsumEn  sl
udpCsumEn  sl
dropOnPause  sl
EthMacStatusType  
rxFifoDropCnt  sl
rxPauseCnt  sl
txPauseCnt  sl
rxCountEn  sl
rxOverFlow  sl
rxCrcErrorCnt  sl
txCountEn  sl
txUnderRunCnt  sl
txNotReadyCnt  sl
EthMacCsumAccumType  
step  slv ( EMAC_CSUM_PIPELINE_C downto 0 )
sum1  Slv32Array ( 1 downto 0 )
sum3  slv ( 31 downto 0 )
sum5  slv ( 15 downto 0 )

Detailed Description

Definition at line 26 of file EthMacPkg.vhd.

Member Function Documentation

◆ EthPortArrayBigEndian()

Slv16Array EthPortArrayBigEndian (   portNum in PositiveArray ,
  portSize in positive  
)
Function

Definition at line 127 of file EthMacPkg.vhd.

◆ GetEthMacCsum()

GetEthMacCsum (   udpDet in sl ,
  last in sl ,
  hdr in Slv8Array ( 19 downto 0 ) ,
  tKeep in slv ( 15 downto 0 ) ,
  tData in slv ( 127 downto 0 ) ,
  len in slv ( 15 downto 0 ) ,
  ibcsum in slv ( 15 downto 0 ) ,
  r in EthMacCsumAccumArray ( 1 downto 0 ) ,
  v inout EthMacCsumAccumArray ( 1 downto 0 ) ,
  ipValid inout sl ,
  ipCsum inout slv ( 15 downto 0 ) ,
  valid inout sl ,
  csum inout slv ( 15 downto 0 )  
)
Procedure

Definition at line 129 of file EthMacPkg.vhd.

Member Data Documentation

◆ ieee

ieee
Library

Definition at line 18 of file EthMacPkg.vhd.

◆ std_logic_1164

std_logic_1164
Package

Definition at line 19 of file EthMacPkg.vhd.

◆ std_logic_unsigned

Definition at line 20 of file EthMacPkg.vhd.

◆ std_logic_arith

std_logic_arith
Package

Definition at line 21 of file EthMacPkg.vhd.

◆ StdRtlPkg

StdRtlPkg
Package

Definition at line 23 of file EthMacPkg.vhd.

◆ AxiStreamPkg

AxiStreamPkg
Package

Definition at line 24 of file EthMacPkg.vhd.

◆ EMAC_ADDR_INIT_C

EMAC_ADDR_INIT_C slv ( 47 downto 0 ) := x " 020300564400 "
Constant

Definition at line 31 of file EthMacPkg.vhd.

◆ ARP_TYPE_C

ARP_TYPE_C slv ( 15 downto 0 ) := x " 0608 "
Constant

Definition at line 34 of file EthMacPkg.vhd.

◆ IPV4_TYPE_C

IPV4_TYPE_C slv ( 15 downto 0 ) := x " 0008 "
Constant

Definition at line 35 of file EthMacPkg.vhd.

◆ VLAN_TYPE_C

VLAN_TYPE_C slv ( 15 downto 0 ) := x " 0081 "
Constant

Definition at line 36 of file EthMacPkg.vhd.

◆ UDP_C

UDP_C slv ( 7 downto 0 ) := x " 11 "
Constant

Definition at line 39 of file EthMacPkg.vhd.

◆ TCP_C

TCP_C slv ( 7 downto 0 ) := x " 06 "
Constant

Definition at line 40 of file EthMacPkg.vhd.

◆ ICMP_C

ICMP_C slv ( 7 downto 0 ) := x " 01 "
Constant

Definition at line 41 of file EthMacPkg.vhd.

◆ DHCP_CPORT

DHCP_CPORT slv ( 15 downto 0 ) := x " 4400 "
Constant

Definition at line 44 of file EthMacPkg.vhd.

◆ DHCP_SPORT

DHCP_SPORT slv ( 15 downto 0 ) := x " 4300 "
Constant

Definition at line 45 of file EthMacPkg.vhd.

◆ EMAC_FRAG_BIT_C

EMAC_FRAG_BIT_C integer := 0
Constant

Definition at line 48 of file EthMacPkg.vhd.

◆ EMAC_SOF_BIT_C

EMAC_SOF_BIT_C integer := 1
Constant

Definition at line 49 of file EthMacPkg.vhd.

◆ EMAC_EOFE_BIT_C

EMAC_EOFE_BIT_C integer := 0
Constant

Definition at line 52 of file EthMacPkg.vhd.

◆ EMAC_IPERR_BIT_C

EMAC_IPERR_BIT_C integer := 1
Constant

Definition at line 53 of file EthMacPkg.vhd.

◆ EMAC_TCPERR_BIT_C

EMAC_TCPERR_BIT_C integer := 2
Constant

Definition at line 54 of file EthMacPkg.vhd.

◆ EMAC_UDPERR_BIT_C

EMAC_UDPERR_BIT_C integer := 3
Constant

Definition at line 55 of file EthMacPkg.vhd.

◆ EMAC_AXIS_CONFIG_C

EMAC_AXIS_CONFIG_C AxiStreamConfigType := ( TSTRB_EN_C = > false , TDATA_BYTES_C = > 16 , TDEST_BITS_C = > 8 , TID_BITS_C = > 0 , TKEEP_MODE_C = > TKEEP_COMP_C , TUSER_BITS_C = > 4 , TUSER_MODE_C = > TUSER_FIRST_LAST_C )
Constant

Definition at line 58 of file EthMacPkg.vhd.

◆ EthMacConfigType

Definition at line 68 of file EthMacPkg.vhd.

◆ macAddress

macAddress slv ( 47 downto 0 )
Record

Definition at line 69 of file EthMacPkg.vhd.

◆ filtEnable

filtEnable sl
Record

Definition at line 70 of file EthMacPkg.vhd.

◆ pauseEnable

pauseEnable sl
Record

Definition at line 71 of file EthMacPkg.vhd.

◆ pauseTime

pauseTime slv ( 15 downto 0 )
Record

Definition at line 72 of file EthMacPkg.vhd.

◆ ipCsumEn

ipCsumEn sl
Record

Definition at line 73 of file EthMacPkg.vhd.

◆ tcpCsumEn

tcpCsumEn sl
Record

Definition at line 74 of file EthMacPkg.vhd.

◆ udpCsumEn

udpCsumEn sl
Record

Definition at line 75 of file EthMacPkg.vhd.

◆ dropOnPause

dropOnPause sl
Record

Definition at line 76 of file EthMacPkg.vhd.

◆ ETH_MAC_CONFIG_INIT_C

ETH_MAC_CONFIG_INIT_C EthMacConfigType := ( macAddress = > EMAC_ADDR_INIT_C , filtEnable = > ' 1 ' , pauseEnable = > ' 1 ' , pauseTime = > x " 00FF " , ipCsumEn = > ' 1 ' , tcpCsumEn = > ' 1 ' , udpCsumEn = > ' 1 ' , dropOnPause = > ' 0 ' )
Constant

Definition at line 78 of file EthMacPkg.vhd.

◆ EthMacConfigArray

EthMacConfigArray array ( natural range <> ) of EthMacConfigType
Type

Definition at line 87 of file EthMacPkg.vhd.

◆ EthMacStatusType

Definition at line 90 of file EthMacPkg.vhd.

◆ rxFifoDropCnt

rxFifoDropCnt sl
Record

Definition at line 91 of file EthMacPkg.vhd.

◆ rxPauseCnt

rxPauseCnt sl
Record

Definition at line 92 of file EthMacPkg.vhd.

◆ txPauseCnt

txPauseCnt sl
Record

Definition at line 93 of file EthMacPkg.vhd.

◆ rxCountEn

rxCountEn sl
Record

Definition at line 94 of file EthMacPkg.vhd.

◆ rxOverFlow

rxOverFlow sl
Record

Definition at line 95 of file EthMacPkg.vhd.

◆ rxCrcErrorCnt

rxCrcErrorCnt sl
Record

Definition at line 96 of file EthMacPkg.vhd.

◆ txCountEn

txCountEn sl
Record

Definition at line 97 of file EthMacPkg.vhd.

◆ txUnderRunCnt

txUnderRunCnt sl
Record

Definition at line 98 of file EthMacPkg.vhd.

◆ txNotReadyCnt

txNotReadyCnt sl
Record

Definition at line 99 of file EthMacPkg.vhd.

◆ ETH_MAC_STATUS_INIT_C

ETH_MAC_STATUS_INIT_C EthMacStatusType := ( rxFifoDropCnt = > ' 0 ' , rxPauseCnt = > ' 0 ' , txPauseCnt = > ' 0 ' , rxCountEn = > ' 0 ' , rxOverFlow = > ' 0 ' , rxCrcErrorCnt = > ' 0 ' , txCountEn = > ' 0 ' , txUnderRunCnt = > ' 0 ' , txNotReadyCnt = > ' 0 ' )
Constant

Definition at line 101 of file EthMacPkg.vhd.

◆ EthMacStatusArray

EthMacStatusArray array ( natural range <> ) of EthMacStatusType
Type

Definition at line 111 of file EthMacPkg.vhd.

◆ EMAC_CSUM_PIPELINE_C

EMAC_CSUM_PIPELINE_C natural := 3
Constant

Definition at line 113 of file EthMacPkg.vhd.

◆ EthMacCsumAccumType

Definition at line 114 of file EthMacPkg.vhd.

◆ step

step slv ( EMAC_CSUM_PIPELINE_C downto 0 )
Record

Definition at line 115 of file EthMacPkg.vhd.

◆ sum1

sum1 Slv32Array ( 1 downto 0 )
Record

Definition at line 116 of file EthMacPkg.vhd.

◆ sum3

sum3 slv ( 31 downto 0 )
Record

Definition at line 117 of file EthMacPkg.vhd.

◆ sum5

sum5 slv ( 15 downto 0 )
Record

Definition at line 118 of file EthMacPkg.vhd.

◆ ETH_MAC_CSUM_ACCUM_INIT_C

ETH_MAC_CSUM_ACCUM_INIT_C EthMacCsumAccumType := ( step = > ( others = > ' 0 ' ) , sum1 = > ( others = > ( others = > ' 0 ' ) ) , sum3 = > ( others = > ' 0 ' ) , sum5 = > ( others = > ' 0 ' ) )
Constant

Definition at line 120 of file EthMacPkg.vhd.

◆ EthMacCsumAccumArray

EthMacCsumAccumArray array ( natural range <> ) of EthMacCsumAccumType
Type

Definition at line 125 of file EthMacPkg.vhd.


The documentation for this class was generated from the following file: