1 ------------------------------------------------------------------------------- 2 -- File : TenGigEthGtx7.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 Gtx7 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_gtx7 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 77 component TenGigEthGtx7Core
93 reset_counter_done :
in ;
98 sim_speedup_control :
in ;
99 xgmii_txd :
in (
63 downto 0);
100 xgmii_txc :
in (
7 downto 0);
101 xgmii_rxd :
out (
63 downto 0);
102 xgmii_rxc :
out (
7 downto 0);
103 configuration_vector :
in (
535 downto 0);
104 status_vector :
out (
447 downto 0);
105 core_status :
out (
7 downto 0);
114 drp_daddr_o :
out (
15 downto 0);
115 drp_di_o :
out (
15 downto 0);
117 drp_drpdo_o :
out (
15 downto 0);
120 drp_daddr_i :
in (
15 downto 0);
121 drp_di_i :
in (
15 downto 0);
123 drp_drpdo_i :
in (
15 downto 0);
125 pma_pmd_type :
in (
2 downto 0));
203 dataOut
(0) => status.sigDet,
204 dataOut
(1) => status.txFault,
205 dataOut
(2) => status.txUsrRdy
);
223 -- Ethernet Interface 229 -- XGMII PHY Interface 238 U_TenGigEthGtx7Core : TenGigEthGtx7Core
241 rxrecclk_out =>
open,
249 gttxreset => status.gtTxRst,
250 gtrxreset => status.gtRxRst,
252 reset_counter_done => status.rstCntDone,
253 -- Quad PLL Interface 254 qplllock => status.qplllock,
267 -- Configuration and Status 268 sim_speedup_control => '0',
270 status_vector =>
open,
271 core_status => status.core_status,
272 tx_resetdone => status.txRstdone,
273 rx_resetdone => status.rxRstdone,
274 signal_detect => status.sigDet,
275 tx_fault => status.txFault,
276 tx_disable => status.txDisable,
277 pma_pmd_type => config.pma_pmd_type,
279 -- Note: If no arbitration is required on the GT DRP ports 280 -- then connect REQ to GNT and connect other signals i <= o; 288 drp_drpdo_o =>
drpDo,
294 drp_drpdo_i =>
drpDo);
296 ------------------------------------- 297 -- 10GBASE-R's Reset Module 298 ------------------------------------- 318 ------------------------------- 319 -- Configuration Vector Mapping 320 ------------------------------- 321 configurationVector(
0) <= config.pma_loopback;
322 configurationVector(
15) <= config.pma_reset;
323 configurationVector(
110) <= config.pcs_loopback;
324 configurationVector(
111) <= config.pcs_reset;
325 configurationVector(
399 downto 384) <= x"4C4B"; -- timer_ctrl =
0x4C4B (
default)
327 ---------------------- 328 -- Core Status Mapping 329 ---------------------- 332 -------------------------------- 333 -- Configuration/Status Register 334 -------------------------------- 341 -- Local Configurations 346 -- AXI-Lite Register Interface 351 -- Configuration and Status Interface AxiLiteWriteMasterType mAxiWriteMaster
in axiReadMasterAxiLiteReadMasterType
EN_AXI_REG_Gboolean := false
out axiLiteReadSlaveAxiLiteReadSlaveType
out xgmiiTxdslv( 63 downto 0)
out dmaIbMasterAxiStreamMasterType
in xgmiiRxcslv( 7 downto 0) :=( others => '0')
out mAxiReadMasterAxiLiteReadMasterType
slv( 15 downto 0) drpAddr
in ibMacPrimMasterAxiStreamMasterType
out axiReadSlaveAxiLiteReadSlaveType
slv( 7 downto 0) core_status
EN_AXI_REG_Gboolean := false
out xgmiiTxcslv( 7 downto 0)
AxiLiteReadMasterType mAxiReadMaster
in mAxiWriteSlaveAxiLiteWriteSlaveType
AxiStreamMasterType macRxAxisMaster
in obMacPrimSlaveAxiStreamSlaveType
out sAxiWriteSlaveAxiLiteWriteSlaveType
in dmaIbSlaveAxiStreamSlaveType
AxiLiteWriteSlaveType mAxiWriteSlave
in axiLiteWriteMasterAxiLiteWriteMasterType := AXI_LITE_WRITE_MASTER_INIT_C
in sAxiReadMasterAxiLiteReadMasterType
slv( 1 downto 0) := "10" AXI_RESP_SLVERR_C
in sAxiWriteMasterAxiLiteWriteMasterType
out obMacPrimMasterAxiStreamMasterType
slv( 535 downto 0) :=( others => '0') configurationVector
in xgmiiRxdslv( 63 downto 0) :=( others => '0')
out axiWriteSlaveAxiLiteWriteSlaveType
out ibMacPrimSlaveAxiStreamSlaveType
in dmaObMasterAxiStreamMasterType
out sAxiReadSlaveAxiLiteReadSlaveType
AXI_ERROR_RESP_Gslv( 1 downto 0) := AXI_RESP_SLVERR_C
PRIM_CONFIG_GAxiStreamConfigType := EMAC_AXIS_CONFIG_C
AXIS_CONFIG_GAxiStreamConfigType := AXI_STREAM_CONFIG_INIT_C
AxiStreamCtrlType macRxAxisCtrl
in axiWriteMasterAxiLiteWriteMasterType
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
out axiLiteWriteSlaveAxiLiteWriteSlaveType
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
AXI_ERROR_RESP_Gslv( 1 downto 0) := AXI_RESP_SLVERR_C
in mAxiReadSlaveAxiLiteReadSlaveType
out dmaObSlaveAxiStreamSlaveType
AxiLiteReadSlaveType mAxiReadSlave
in localMacslv( 47 downto 0) := MAC_ADDR_INIT_C
in ethConfigEthMacConfigType
out ethStatusEthMacStatusType
AxiStreamMasterType macTxAxisMaster
in axiLiteReadMasterAxiLiteReadMasterType := AXI_LITE_READ_MASTER_INIT_C
out mAxiWriteMasterAxiLiteWriteMasterType
AxiStreamSlaveType macTxAxisSlave