From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [RFC 2/2] net/tap: add eBPF instructions Date: Thu, 30 Nov 2017 18:05:22 +0100 Message-ID: <33612859.oYs3VmdAvV@xps> References: <1512028870-13597-1-git-send-email-ophirmu@mellanox.com> <1512028870-13597-2-git-send-email-ophirmu@mellanox.com> <20171130085408.0c7d68c2@xeon-e3> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev@dpdk.org, Ophir Munk , Olga Shern , Pascal Mazon To: Stephen Hemminger Return-path: Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by dpdk.org (Postfix) with ESMTP id 6B8BE567E for ; Thu, 30 Nov 2017 18:05:24 +0100 (CET) In-Reply-To: <20171130085408.0c7d68c2@xeon-e3> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 30/11/2017 17:54, Stephen Hemminger: > Loading BPF is a could solution to doing dynamic flow matching. > It needs to be done differently to be accepted. > > Putting raw machine instructions in source code is as bad as binary > blobs. You need to provide original source of program and then have > build instructions to create any needed code. The source program is provided in this patch: tap_bpf_program.c It is pre-compiled to avoid requiring too many dependencies when building DPDK. > There licensing concerns here as well. Any BPF program inserted > in the kernel must be GPL. So you need to provide source. > > Given the license overlap you should also document that in the rte_flow_tap.rst > file. > > The program that loads the program can be BSD, it just needs to pick > up the BPF firmware file from a compiled ELF image. The program that loads BPF is the TAP PMD itself.