Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 2 Jun 2020 22:49:18 +0530
From:      Ankur Kothiwal <ankur@freebsd.org>
To:        freebsd-hackers@freebsd.org, soc-status@freebsd.org
Cc:        rstone@freebsd.org, hrs@freebsd.org
Subject:   [GSoC'20 Introduction] eBPF XDP Hook
Message-ID:  <CA%2BQRpiGHhgg1C%2BJaZu7mgF3fo2haBe%2Bm_ZYNkZxF3pFvM2rGKQ@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hello everyone,
Project: Implement eBPF XDP for FreeBSD by extending VirtIO ethernet
driver if_vtnet
The goal of this project is to extend an existing FreeBSD network
driver ,VirtIO if_vtnet to be able to call into an eBPF program when
processing a newly received packet. The driver will perform the basic
actions of XDP like PASS, DROP, TX or REDIRECT  the packet as
specified by the program. The project will also implement new map type
and other eBPF helper functions.The aim of this project is to add new
probe sites into the kernel that will call eBPF functions

Mentors: Ryan Stone <rstone@> and Hiroki Sato <hrs@>

Approach for the project:
The project aims to extend the NIC driver =E2=80=9Cif_vtnet=E2=80=9D to sup=
port XDP.
The approach is to write a XDP hook as a pfil (packet filter) hook
(https://svnweb.freebsd.org/changeset/base/356613) in the
vtnet_rxq_eof() function which is the function that deals with
receiving the packets from the driver. This approach will help the XDP
hook to work on any driver that supports pfil (like mlx5en).
The function will take XDP actions (like PASS, DROP etc) on the packet
which will further be processed by the eBPF program.

Project GSoC Wiki: https://wiki.freebsd.org/SummerOfCodeIdeas#eBPF_XDP_Hook=
s
Github Repo for the code:
https://github.com/rysto32/freebsd/tree/ebpf-import

FreeBSD Wiki
Student: https://wiki.freebsd.org/AnkurKothiwal
Project: https://wiki.freebsd.org/SummerOfCode2020Projects/eBPFXDPHooks

Thank you for giving your time to read. Please feel free to share your
feedback and suggestion.

Thanks and Regards
Ankur Kothiwal



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CA%2BQRpiGHhgg1C%2BJaZu7mgF3fo2haBe%2Bm_ZYNkZxF3pFvM2rGKQ>