All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alexei Starovoitov <ast@fb.com>
To: "Wangnan (F)" <wangnan0@huawei.com>,
	"David S . Miller" <davem@davemloft.net>
Cc: Daniel Borkmann <daniel@iogearbox.net>,
	Martin KaFai Lau <kafai@fb.com>, <netdev@vger.kernel.org>,
	<kernel-team@fb.com>
Subject: Re: [PATCH net-next 1/6] bpf: introduce BPF_PROG_TEST_RUN command
Date: Thu, 30 Mar 2017 20:24:57 -0700	[thread overview]
Message-ID: <35b22fbd-546b-779b-9dc0-1f9a914e33cf@fb.com> (raw)
In-Reply-To: <67b19080-26f9-67ac-d7fa-e621a90c54bb@huawei.com>

On 3/30/17 8:12 PM, Wangnan (F) wrote:
>
>
> On 2017/3/31 10:57, Alexei Starovoitov wrote:
>> On 3/30/17 7:53 PM, Wangnan (F) wrote:
>>> I suggest using a CONFIG option to enable/disable code in
>>> test_run.o to reduce attack plane.
>>
>> attack plane? what attack do you see and how config helps?
>>
>
> I think all testing features are not required to be compiled
> for a production system. A feature which should never be used
> looks dangerous to me.

It is required on production system, since xdp testing and
xdp production has to use the same kernel. We cannot
keep rebooting the server back and forth to test and then to run.
It's not testing the kernel features, it's testing bpf programs
which are technically user space components.

> I suggest adding a CONFIG option like CONFIG_BPF_PROGRAM_TEST_RUN
> to control whether the kernel should be compiled with this feature
> or not. We can enable by default, and give people a chance to
> turn it off. At least in my company people tends to turn all
> unneeded features off. If you don't provide a config option they
> will make one by themselves.

Using this logic huawei should be turning off xdp as well.
Sorry we're not going stub xdp facility out of the core
and the drivers just because you don't use it.

  reply	other threads:[~2017-03-31  3:25 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-31  1:31 [PATCH net-next 0/6] bpf: program testing framework Alexei Starovoitov
2017-03-31  1:31 ` [PATCH net-next 1/6] bpf: introduce BPF_PROG_TEST_RUN command Alexei Starovoitov
2017-03-31  2:53   ` Wangnan (F)
2017-03-31  2:57     ` Alexei Starovoitov
2017-03-31  3:12       ` Wangnan (F)
2017-03-31  3:24         ` Alexei Starovoitov [this message]
2017-03-31  3:37           ` Wangnan (F)
2017-03-31  1:31 ` [PATCH net-next 2/6] tools/lib/bpf: add support for " Alexei Starovoitov
2017-03-31  3:15   ` Wangnan (F)
2017-03-31  3:26     ` Alexei Starovoitov
2017-03-31  1:31 ` [PATCH net-next 3/6] selftests/bpf: add a test for overlapping packet range checks Alexei Starovoitov
2017-03-31  1:31 ` [PATCH net-next 4/6] tools/lib/bpf: expose bpf_program__set_type() Alexei Starovoitov
2017-03-31  2:33   ` Wangnan (F)
2017-03-31  2:37     ` Alexei Starovoitov
2017-03-31  2:48       ` Wangnan (F)
2017-03-31  2:56         ` Alexei Starovoitov
2017-03-31  1:31 ` [PATCH net-next 5/6] selftests/bpf: add a test for basic XDP functionality Alexei Starovoitov
2017-03-31  1:31 ` [PATCH net-next 6/6] selftests/bpf: add l4 load balancer test based on sched_cls Alexei Starovoitov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=35b22fbd-546b-779b-9dc0-1f9a914e33cf@fb.com \
    --to=ast@fb.com \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=kafai@fb.com \
    --cc=kernel-team@fb.com \
    --cc=netdev@vger.kernel.org \
    --cc=wangnan0@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.