Code Monkey home page Code Monkey logo

100g-fpga-network-stack-core's Introduction

100 GbE TCP offload Engine

This repository implements from OSI layer 3 to above and is part of Limago. To generate the complete stack please refer to Limago

Prerequisites

Make sure that Vivado-HLS is in the PATH and you are running a supported version

  • Vivado-HLS 2018.2 to Vivado-HLS 2020.1

If you are not sure what version is running execute the following command:

vivado_hls -version

Getting Started

Execute make in the root folder, a new folder named synthesis_results will be created. After the folder creation the project will launch the Synthesis of the different IP-Cores. Be patient this may take around 10 minutes.

Explore the IP-Cores

You can check the synthetized project under synthesis_results. For instance, if you want to open the TOE

vivado_hls -p synthesis_results/TOE_hls_prj/

Citation

If you use the TCP/IP stack or the checksum computation in your project please cite one of the following papers and/or link to the github project:

@inproceedings{sutter2018fpga,
    title={{FPGA-based TCP/IP Checksum Offloading Engine for 100 Gbps Networks}},
    author={Sutter, Gustavo and Ruiz, Mario and L{\'o}pez-Buedo, Sergio and Alonso, Gustavo},
    booktitle={2018 International Conference on ReConFigurable Computing and FPGAs (ReConFig)},
    year={2018},
    organization={IEEE},
    doi={10.1109/RECONFIG.2018.8641729},
    ISSN={2640-0472},
    month={Dec},
}
@INPROCEEDINGS{ruiz2019tcp, 
    title={{Limago: an FPGA-based Open-source 100~GbE TCP/IP Stack}}, 
    author={Ruiz, Mario and Sidler, David and Sutter, Gustavo and Alonso, Gustavo and L{\'o}pez-Buedo, Sergio},
    booktitle={{2019 29th International Conference on Field Programmable Logic and Applications (FPL)}}, 
    year={2019},
    month={Sep},
    pages={286-292}, 
    organization={IEEE},
    doi={10.1109/FPL.2019.00053},
    ISSN={1946-147X}, 
}

License

This project is a collaboration between the Systems Group of ETH Zürich, Switzerland and HPCN Group of UAM, Spain. Furthermore, the starting point of this implementation is the Scalable 10Gbps TCP/IP Stack Architecture for Reconfigurable Hardware by Sidler, D et al. The original implementation can be found in their github.

For this project we keep the BSD 3-Clause License

BSD 3-Clause License

Copyright (c) 2019, 
HPCN Group, UAM Spain (hpcn-uam.es)
Systems Group, ETH Zurich (systems.ethz.ch)
All rights reserved.


Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice, this
  list of conditions and the following disclaimer.

* Redistributions in binary form must reproduce the above copyright notice,
  this list of conditions and the following disclaimer in the documentation
  and/or other materials provided with the distribution.

* Neither the name of the copyright holder nor the names of its
  contributors may be used to endorse or promote products derived from
  this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

100g-fpga-network-stack-core's People

Contributors

lisal2023 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

100g-fpga-network-stack-core's Issues

Simulation problem in Vitis HLS

Hi @mariodruiz,
I have encountered some errors of "undefined references" when performed C simulation on pure udp example (including udp.cpp, udp.hpp, udp_tb.cpp).

Makefile.rules:379: recipe for target 'csim.exe' failed
obj/udp_tb.o: In function `main':
/home/xilinx/udp_naive/solution1/csim/build/../../../../workspace/kerwinair/xup_vitis_network_example/NetLayers/100G-fpga-network-stack-core/hls/UDP/udp_tb.cpp:119: undefined reference to `pcap2stream(char*, bool, hls::stream<my_axis<512>, 0>&)'
/home/xilinx/udp_naive/solution1/csim/build/../../../../workspace/kerwinair/xup_vitis_network_example/NetLayers/100G-fpga-network-stack-core/hls/UDP/udp_tb.cpp:216: undefined reference to `stream2pcap(char*, bool, bool, hls::stream<my_axis<512>, 0>&, bool)'
obj/udp.o: In function `appGetMetaData(hls::stream<my_axis_udp<512>, 0>&, hls::stream<my_axis<512>, 0>&, hls::stream<ap_uint<16>, 0>&, hls::stream<ap_uint<16>, 0>&)':
/home/xilinx/udp_naive/solution1/csim/build/../../../../workspace/kerwinair/xup_vitis_network_example/NetLayers/100G-fpga-network-stack-core/hls/UDP/udp.cpp:261: undefined reference to `keep2len(ap_uint<64>)'
/home/xilinx/udp_naive/solution1/csim/build/../../../../workspace/kerwinair/xup_vitis_network_example/NetLayers/100G-fpga-network-stack-core/hls/UDP/udp.cpp:272: undefined reference to `keep2len(ap_uint<64>)'
collect2: error: ld returned 1 exit status
make: *** [csim.exe] Error 1
ERROR: [SIM 211-100] 'csim_design' failed: compilation error(s).

However #include "../TOE/testbench/pcap2stream.cpp" has been included in udp_tb.cpp, and #include "../TOE/common_utilities/common_utilities.hpp" has also been included in udp.hpp.

Simulating the project in HLS

@mariodruiz Hi,
I am trying to simulate the TOE on Vivado HLS and have run into few problems. I see the simulation requires at least 3 arguments; a 0 or 1 and 2 pcap files. I also can find 3 pcap files in the pcap directory. Can I use them as input pcap files? Should the output pcap file be an existing pcap file?
I, as a trial, tried using echo_replay.pcap and iperf3_fpga_as_client.pcap as input and output files respectively and got the following output on the console.

WINDOW_BITS 18	MAX_SESSIONS 64	BUFFER_SIZE 262144
POW: Error opening output file
: No such file or directory
runExperiment set 
IPERF request to establish a new connection socket 192.168.0.8:5001
IPERF2 Init timer at 11
tx_app_table  .ackd 0x301b0	.mempt 0x301b1
Error in mmap -1
Error in mmap: Bad file descriptor
Error opening the input file with name: /home/xilinx/Desktop/100G-fpga-network-stack-core/pcap (copy)/echo_replay.pcap
Setting event for retransmit event type 3	at 385
Setting event for retransmit event type 3	at 834
Setting event for retransmit event type 3	at 1411
Setting event for retransmit event type 3	at 2052
Connection could not be opened.
regSessionCount 0
WARNING: Hls::stream 'ipTxData' contains leftover data, which may result in RTL simulation hanging.
WARNING: Hls::stream 'slc_sessionIdFreeList' contains leftover data, which may result in RTL simulation hanging.
WARNING: Hls::stream 'portTable2txApp_free_port' contains leftover data, which may result in RTL simulation hanging.

Do I also need to have IPERF installed? And do I need a physical connection to the hardware?

ICMP myIpAddress port is not connected

I have encounter one issue that the myIpAddress port from ICMP server is not connected to the config input as shown in the following figure:

Screenshot from 2023-08-25 16-16-16

It seems that the generated interface has duplicated suffix of "_0" with Vitis HLS 2022.2. This problem makes the FPGA failed to response ICMP package.

To fix it, I follow the code of ARP server, and delete the pragma naming this port in icmp_server.cpp

I'm not sure my solution is acceptable. If yes, I will push my change and open one PR to merge it.

Thanks

U200:self loop test

Hello, author,

I only have one U200 accelerator card now. I want to connect the two optical ports of U200 through the optical fiber self ring to test the TCP performance. Can it be realized and what other configurations are needed

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.