From c4304bf8c0c56f5abff9613f5977f3914038b748 Mon Sep 17 00:00:00 2001 From: Alex Forencich Date: Tue, 8 Apr 2025 22:12:52 -0700 Subject: [PATCH] example: Update 1G MAC instances in example designs Signed-off-by: Alex Forencich --- example/Arty/fpga/rtl/fpga_core.sv | 13 ++++++- example/HTG940/fpga/rtl/fpga_core.sv | 13 ++++++- example/KC705/fpga/rtl/fpga_core.sv | 50 +++++++++++++++++++++++--- example/KCU105/fpga/rtl/fpga_core.sv | 39 +++++++++++++++++++-- example/KR260/fpga/rtl/fpga_core.sv | 39 +++++++++++++++++++-- example/VCU108/fpga/rtl/fpga_core.sv | 13 ++++++- example/VCU118/fpga/rtl/fpga_core.sv | 13 ++++++- example/ZCU102/fpga/rtl/fpga_core.sv | 52 +++++++++++++++++++++++++--- example/ZCU106/fpga/rtl/fpga_core.sv | 26 ++++++++++++-- 9 files changed, 238 insertions(+), 20 deletions(-) diff --git a/example/Arty/fpga/rtl/fpga_core.sv b/example/Arty/fpga/rtl/fpga_core.sv index 0f0a480..f9139af 100644 --- a/example/Arty/fpga/rtl/fpga_core.sv +++ b/example/Arty/fpga/rtl/fpga_core.sv @@ -117,6 +117,7 @@ uart_inst ( taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_stat(); taxi_eth_mac_mii_fifo #( .SIM(SIM), @@ -124,6 +125,7 @@ taxi_eth_mac_mii_fifo #( .FAMILY(FAMILY), .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -157,6 +159,13 @@ eth_mac_inst ( .mii_tx_en(phy_tx_en), .mii_tx_er(), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_stat), + /* * Status */ @@ -173,8 +182,10 @@ eth_mac_inst ( /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); diff --git a/example/HTG940/fpga/rtl/fpga_core.sv b/example/HTG940/fpga/rtl/fpga_core.sv index 07f5223..8659e38 100644 --- a/example/HTG940/fpga/rtl/fpga_core.sv +++ b/example/HTG940/fpga/rtl/fpga_core.sv @@ -108,6 +108,7 @@ uart_inst ( // BASE-T PHY taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_stat(); taxi_eth_mac_1g_rgmii_fifo #( .SIM(SIM), @@ -116,6 +117,7 @@ taxi_eth_mac_1g_rgmii_fifo #( .USE_CLK90(USE_CLK90), .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -149,6 +151,13 @@ eth_mac_inst ( .rgmii_txd(phy_rgmii_txd), .rgmii_tx_ctl(phy_rgmii_tx_ctl), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_stat), + /* * Status */ @@ -166,8 +175,10 @@ eth_mac_inst ( /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); diff --git a/example/KC705/fpga/rtl/fpga_core.sv b/example/KC705/fpga/rtl/fpga_core.sv index d30bc6e..0ee53e2 100644 --- a/example/KC705/fpga/rtl/fpga_core.sv +++ b/example/KC705/fpga/rtl/fpga_core.sv @@ -150,6 +150,7 @@ assign phy_reset_n = !rst; taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_stat(); if (BASET_PHY_TYPE == "GMII") begin : baset_mac_gmii @@ -159,6 +160,7 @@ if (BASET_PHY_TYPE == "GMII") begin : baset_mac_gmii .FAMILY(FAMILY), .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -194,6 +196,13 @@ if (BASET_PHY_TYPE == "GMII") begin : baset_mac_gmii .gmii_tx_en(phy_gmii_tx_en), .gmii_tx_er(phy_gmii_tx_er), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_stat), + /* * Status */ @@ -211,8 +220,10 @@ if (BASET_PHY_TYPE == "GMII") begin : baset_mac_gmii /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); @@ -233,6 +244,7 @@ end else if (BASET_PHY_TYPE == "RGMII") begin : baset_mac_rgmii .USE_CLK90(USE_CLK90), .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -266,6 +278,13 @@ end else if (BASET_PHY_TYPE == "RGMII") begin : baset_mac_rgmii .rgmii_txd(phy_rgmii_txd), .rgmii_tx_ctl(phy_rgmii_tx_ctl), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_stat), + /* * Status */ @@ -283,8 +302,10 @@ end else if (BASET_PHY_TYPE == "RGMII") begin : baset_mac_rgmii /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); @@ -302,6 +323,7 @@ end else if (BASET_PHY_TYPE == "SGMII") begin : baset_mac_sgmii taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -344,6 +366,13 @@ end else if (BASET_PHY_TYPE == "SGMII") begin : baset_mac_sgmii .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_stat), + /* * Status */ @@ -360,8 +389,10 @@ end else if (BASET_PHY_TYPE == "SGMII") begin : baset_mac_sgmii /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); @@ -381,10 +412,12 @@ assign sfp_tx_disable_b = 1'b1; taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp_stat(); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -427,6 +460,13 @@ eth_mac_inst ( .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_sfp_stat), + /* * Status */ @@ -443,8 +483,10 @@ eth_mac_inst ( /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); diff --git a/example/KCU105/fpga/rtl/fpga_core.sv b/example/KCU105/fpga/rtl/fpga_core.sv index d21511c..5c52cb1 100644 --- a/example/KCU105/fpga/rtl/fpga_core.sv +++ b/example/KCU105/fpga/rtl/fpga_core.sv @@ -148,10 +148,12 @@ assign phy_reset_n = !rst; taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_stat(); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -194,6 +196,13 @@ eth_mac_inst ( .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_stat), + /* * Status */ @@ -210,8 +219,10 @@ eth_mac_inst ( /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); @@ -222,13 +233,16 @@ if (SFP_RATE == 0) begin : sfp_mac taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp0_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp0_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp0_stat(); taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp1_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp1_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp1_stat(); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -271,6 +285,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_sfp0_stat), + /* * Status */ @@ -287,14 +308,17 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -337,6 +361,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_sfp1_stat), + /* * Status */ @@ -353,8 +384,10 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); diff --git a/example/KR260/fpga/rtl/fpga_core.sv b/example/KR260/fpga/rtl/fpga_core.sv index 4008de1..d5ff94c 100644 --- a/example/KR260/fpga/rtl/fpga_core.sv +++ b/example/KR260/fpga/rtl/fpga_core.sv @@ -101,9 +101,11 @@ assign phy3_reset_n = !rst; taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_phy2_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_phy2_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_phy2_stat(); taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_phy3_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_phy3_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_phy3_stat(); taxi_eth_mac_1g_rgmii_fifo #( .SIM(SIM), @@ -112,6 +114,7 @@ taxi_eth_mac_1g_rgmii_fifo #( .USE_CLK90(USE_CLK90), .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -145,6 +148,13 @@ phy2_eth_mac_inst ( .rgmii_txd(phy2_rgmii_txd), .rgmii_tx_ctl(phy2_rgmii_tx_ctl), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_phy2_stat), + /* * Status */ @@ -162,8 +172,10 @@ phy2_eth_mac_inst ( /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); @@ -174,6 +186,7 @@ taxi_eth_mac_1g_rgmii_fifo #( .USE_CLK90(USE_CLK90), .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -207,6 +220,13 @@ phy3_eth_mac_inst ( .rgmii_txd(phy3_rgmii_txd), .rgmii_tx_ctl(phy3_rgmii_tx_ctl), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_phy3_stat), + /* * Status */ @@ -224,8 +244,10 @@ phy3_eth_mac_inst ( /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); @@ -236,10 +258,12 @@ if (SFP_RATE == 0) begin : sfp_mac taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp_stat(); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -282,6 +306,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_sfp_stat), + /* * Status */ @@ -298,8 +329,10 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); diff --git a/example/VCU108/fpga/rtl/fpga_core.sv b/example/VCU108/fpga/rtl/fpga_core.sv index feb1429..f3c51ba 100644 --- a/example/VCU108/fpga/rtl/fpga_core.sv +++ b/example/VCU108/fpga/rtl/fpga_core.sv @@ -130,10 +130,12 @@ assign phy_reset_n = !rst; taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_stat(); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -176,6 +178,13 @@ eth_mac_inst ( .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk), + .stat_rst(rst), + .m_axis_stat(axis_stat), + /* * Status */ @@ -192,8 +201,10 @@ eth_mac_inst ( /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); diff --git a/example/VCU118/fpga/rtl/fpga_core.sv b/example/VCU118/fpga/rtl/fpga_core.sv index 0becb49..4fc7fa5 100644 --- a/example/VCU118/fpga/rtl/fpga_core.sv +++ b/example/VCU118/fpga/rtl/fpga_core.sv @@ -150,10 +150,12 @@ assign phy_reset_n = !rst_125mhz; taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_tx_cpl(); +taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_stat(); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -196,6 +198,13 @@ eth_mac_inst ( .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk_125mhz), + .stat_rst(rst_125mhz), + .m_axis_stat(axis_stat), + /* * Status */ @@ -212,8 +221,10 @@ eth_mac_inst ( /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); diff --git a/example/ZCU102/fpga/rtl/fpga_core.sv b/example/ZCU102/fpga/rtl/fpga_core.sv index 578136c..c1c1837 100644 --- a/example/ZCU102/fpga/rtl/fpga_core.sv +++ b/example/ZCU102/fpga/rtl/fpga_core.sv @@ -155,19 +155,24 @@ if (SFP_RATE == 0) begin : sfp_mac taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp0_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp0_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp0_stat(); taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp1_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp1_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp1_stat(); taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp2_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp2_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp2_stat(); taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp3_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp3_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp3_stat(); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -210,6 +215,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk_125mhz), + .stat_rst(rst_125mhz), + .m_axis_stat(axis_sfp0_stat), + /* * Status */ @@ -226,14 +238,17 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -276,6 +291,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk_125mhz), + .stat_rst(rst_125mhz), + .m_axis_stat(axis_sfp1_stat), + /* * Status */ @@ -292,14 +314,17 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -342,6 +367,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk_125mhz), + .stat_rst(rst_125mhz), + .m_axis_stat(axis_sfp2_stat), + /* * Status */ @@ -358,14 +390,17 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -408,6 +443,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk_125mhz), + .stat_rst(rst_125mhz), + .m_axis_stat(axis_sfp3_stat), + /* * Status */ @@ -424,8 +466,10 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); diff --git a/example/ZCU106/fpga/rtl/fpga_core.sv b/example/ZCU106/fpga/rtl/fpga_core.sv index 42d96a5..00a04a6 100644 --- a/example/ZCU106/fpga/rtl/fpga_core.sv +++ b/example/ZCU106/fpga/rtl/fpga_core.sv @@ -135,13 +135,16 @@ if (SFP_RATE == 0) begin : sfp_mac taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp0_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp0_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp0_stat(); taxi_axis_if #(.DATA_W(8), .ID_W(8)) axis_sfp1_eth(); taxi_axis_if #(.DATA_W(96), .KEEP_W(1), .ID_W(8)) axis_sfp1_tx_cpl(); + taxi_axis_if #(.DATA_W(16), .KEEP_W(1), .KEEP_EN(0), .LAST_EN(0), .USER_EN(1), .USER_W(1), .ID_EN(1), .ID_W(8)) axis_sfp1_stat(); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -184,6 +187,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk_125mhz), + .stat_rst(rst_125mhz), + .m_axis_stat(axis_sfp0_stat), + /* * Status */ @@ -200,14 +210,17 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) ); taxi_eth_mac_1g_fifo #( .PADDING_EN(1), .MIN_FRAME_LEN(64), + .STAT_EN(1'b0), .TX_FIFO_DEPTH(16384), .TX_FRAME_FIFO(1), .RX_FIFO_DEPTH(16384), @@ -250,6 +263,13 @@ if (SFP_RATE == 0) begin : sfp_mac .rx_mii_select(1'b0), .tx_mii_select(1'b0), + /* + * Statistics + */ + .stat_clk(clk_125mhz), + .stat_rst(rst_125mhz), + .m_axis_stat(axis_sfp1_stat), + /* * Status */ @@ -266,8 +286,10 @@ if (SFP_RATE == 0) begin : sfp_mac /* * Configuration */ - .cfg_ifg(8'd12), + .cfg_tx_max_pkt_len(16'd9218), + .cfg_tx_ifg(8'd12), .cfg_tx_enable(1'b1), + .cfg_rx_max_pkt_len(16'd9218), .cfg_rx_enable(1'b1) );