On 05/09/2018 06:09 PM, Ferruh Yigit wrote: > On 5/4/2018 1:45 PM, Konstantin Ananyev wrote: >> Introduce new testpmd commands to load/unload RX/TX BPF-based filters. >> >> Signed-off-by: Konstantin Ananyev <konstantin.anan...@intel.com> >> --- >> app/test-pmd/bpf_sup.h | 25 ++++++++ >> app/test-pmd/cmdline.c | 149 >> +++++++++++++++++++++++++++++++++++++++++++++++ >> app/test-pmd/meson.build | 2 +- >> 3 files changed, 175 insertions(+), 1 deletion(-) >> create mode 100644 app/test-pmd/bpf_sup.h >> >> diff --git a/app/test-pmd/bpf_sup.h b/app/test-pmd/bpf_sup.h >> new file mode 100644 >> index 000000000..35f91a07f >> --- /dev/null >> +++ b/app/test-pmd/bpf_sup.h >> @@ -0,0 +1,25 @@ >> +/* SPDX-License-Identifier: BSD-3-Clause >> + * Copyright(c) 2010-2017 Intel Corporation >> + */ >> + >> +#ifndef _BPF_SUP_H_ >> +#define _BPF_SUP_H_ >> + >> +#include <stdio.h> >> +#include <rte_mbuf.h> >> +#include <rte_bpf_ethdev.h> > > This makes testpmd depends to librte_bpf unconditionally. What do you think > using RTE_LIBRTE_BPF macro to make it possible to disable bpf library? >
+1 > <...> > >> @@ -16695,6 +16842,8 @@ cmdline_parse_ctx_t main_ctx[] = { >> (cmdline_parse_inst_t *)&cmd_set_port_tm_node_parent, >> (cmdline_parse_inst_t *)&cmd_port_tm_hierarchy_commit, >> (cmdline_parse_inst_t *)&cmd_cfg_tunnel_udp_port, >> + (cmdline_parse_inst_t *)&cmd_operate_bpf_ld_parse, >> + (cmdline_parse_inst_t *)&cmd_operate_bpf_unld_parse, > > It can be better to move testpmd_funcs.rst updates in doc patch into this > patch, > it helps confirming the both doc and patch. >