1 ------------------------------------------------------------------------------- 2 -- File : TenGigEthGth7.vhd 3 -- Company : SLAC National Accelerator Laboratory 4 -- Created : 2015-02-12 5 -- Last update: 2016-09-29 6 ------------------------------------------------------------------------------- 7 -- Description: 10GBASE-R Ethernet for Gth7 8 ------------------------------------------------------------------------------- 9 -- This file is part of 'SLAC Firmware Standard Library'. 10 -- It is subject to the license terms in the LICENSE.txt file found in the 11 -- top-level directory of this distribution and at: 12 -- https://confluence.slac.stanford.edu/display/ppareg/LICENSE.html. 13 -- No part of 'SLAC Firmware Standard Library', including this file, 14 -- may be copied, modified, propagated, or distributed except according to 15 -- the terms contained in the LICENSE.txt file. 16 ------------------------------------------------------------------------------- 19 use ieee.std_logic_1164.
all;
28 --! @ingroup ethernet_TenGigEthCore_gth7 32 -- AXI-Lite Configurations 35 -- AXI Streaming Configurations 38 -- Local Configurations 39 localMac :
in slv(
47 downto 0) := MAC_ADDR_INIT_C;
40 -- Streaming DMA Interface 47 -- Slave AXI-Lite Interface 152 dataOut
(0) => status.sigDet,
153 dataOut
(1) => status.txFault,
154 dataOut
(2) => status.txUsrRdy
);
172 -- Ethernet Interface 178 -- XGMII PHY Interface 187 U_TenGigEthGth7Core :
entity work.TenGigEthGth7Core
190 rxrecclk_out =>
open,
198 gttxreset => status.gtTxRst,
199 gtrxreset => status.gtRxRst,
201 reset_counter_done => status.rstCntDone,
202 -- Quad PLL Interface 203 qplllock => status.qplllock,
216 -- Configuration and Status 217 sim_speedup_control => '0',
219 status_vector =>
open,
220 core_status => status.core_status,
221 tx_resetdone => status.txRstdone,
222 rx_resetdone => status.rxRstdone,
223 signal_detect => status.sigDet,
224 tx_fault => status.txFault,
225 tx_disable => status.txDisable,
226 pma_pmd_type => config.pma_pmd_type,
228 -- Note: If no arbitration is required on the GT DRP ports 229 -- then connect REQ to GNT and connect other signals i <= o; 237 drp_drpdo_o =>
drpDo,
243 drp_drpdo_i =>
drpDo);
245 ------------------------------------- 246 -- 10GBASE-R's Reset Module 247 ------------------------------------- 267 ------------------------------- 268 -- Configuration Vector Mapping 269 ------------------------------- 270 configurationVector(
0) <= config.pma_loopback;
271 configurationVector(
15) <= config.pma_reset;
272 configurationVector(
110) <= config.pcs_loopback;
273 configurationVector(
111) <= config.pcs_reset;
274 configurationVector(
399 downto 384) <= x"4C4B"; -- timer_ctrl =
0x4C4B (
default)
276 ---------------------- 277 -- Core Status Mapping 278 ---------------------- 281 -------------------------------- 282 -- Configuration/Status Register 283 -------------------------------- 290 -- Local Configurations 295 -- AXI-Lite Register Interface 300 -- Configuration and Status Interface in axiReadMasterAxiLiteReadMasterType
out dmaObSlaveAxiStreamSlaveType
EN_AXI_REG_Gboolean := false
in localMacslv( 47 downto 0) := MAC_ADDR_INIT_C
in axiLiteWriteMasterAxiLiteWriteMasterType := AXI_LITE_WRITE_MASTER_INIT_C
slv( 535 downto 0) :=( others => '0') configurationVector
out xgmiiTxdslv( 63 downto 0)
AxiStreamSlaveType macTxAxisSlave
AxiLiteWriteMasterType mAxiWriteMaster
in dmaIbSlaveAxiStreamSlaveType
in xgmiiRxcslv( 7 downto 0) :=( others => '0')
out mAxiReadMasterAxiLiteReadMasterType
in axiLiteReadMasterAxiLiteReadMasterType := AXI_LITE_READ_MASTER_INIT_C
in ibMacPrimMasterAxiStreamMasterType
out axiReadSlaveAxiLiteReadSlaveType
slv( 7 downto 0) core_status
out xgmiiTxcslv( 7 downto 0)
in mAxiWriteSlaveAxiLiteWriteSlaveType
in obMacPrimSlaveAxiStreamSlaveType
out sAxiWriteSlaveAxiLiteWriteSlaveType
AxiLiteReadSlaveType mAxiReadSlave
out axiLiteWriteSlaveAxiLiteWriteSlaveType
in dmaObMasterAxiStreamMasterType
in sAxiReadMasterAxiLiteReadMasterType
slv( 1 downto 0) := "10" AXI_RESP_SLVERR_C
in sAxiWriteMasterAxiLiteWriteMasterType
out obMacPrimMasterAxiStreamMasterType
AxiStreamMasterType macRxAxisMaster
in xgmiiRxdslv( 63 downto 0) :=( others => '0')
AxiLiteReadMasterType mAxiReadMaster
AxiLiteWriteSlaveType mAxiWriteSlave
AXI_ERROR_RESP_Gslv( 1 downto 0) := AXI_RESP_SLVERR_C
out axiWriteSlaveAxiLiteWriteSlaveType
out ibMacPrimSlaveAxiStreamSlaveType
AxiStreamCtrlType macRxAxisCtrl
EN_AXI_REG_Gboolean := false
out sAxiReadSlaveAxiLiteReadSlaveType
AXI_ERROR_RESP_Gslv( 1 downto 0) := AXI_RESP_SLVERR_C
PRIM_CONFIG_GAxiStreamConfigType := EMAC_AXIS_CONFIG_C
out axiLiteReadSlaveAxiLiteReadSlaveType
in axiWriteMasterAxiLiteWriteMasterType
slv( 15 downto 0) drpAddr
PHY_TYPE_Gstring := "XGMII"
AxiLiteReadMasterType :=(araddr =>( others => '0'),arprot =>( others => '0'),arvalid => '0',rready => '1') AXI_LITE_READ_MASTER_INIT_C
AxiStreamConfigType :=(TSTRB_EN_C => false,TDATA_BYTES_C => 16,TDEST_BITS_C => 4,TID_BITS_C => 0,TKEEP_MODE_C => TKEEP_NORMAL_C,TUSER_BITS_C => 4,TUSER_MODE_C => TUSER_NORMAL_C) AXI_STREAM_CONFIG_INIT_C
out configTenGigEthConfig
in localMacslv( 47 downto 0) := MAC_ADDR_INIT_C
AxiLiteWriteMasterType :=(awaddr =>( others => '0'),awprot =>( others => '0'),awvalid => '0',wdata =>( others => '0'),wstrb =>( others => '1'),wvalid => '0',bready => '1') AXI_LITE_WRITE_MASTER_INIT_C
in mAxiReadSlaveAxiLiteReadSlaveType
in ethConfigEthMacConfigType
AXIS_CONFIG_GAxiStreamConfigType := AXI_STREAM_CONFIG_INIT_C
out ethStatusEthMacStatusType
AxiStreamMasterType macTxAxisMaster
out mAxiWriteMasterAxiLiteWriteMasterType
out dmaIbMasterAxiStreamMasterType