Sridhar Samudrala writes:
> int xdp_do_redirect(struct net_device *dev, struct xdp_buff *xdp,
> struct bpf_prog *xdp_prog)
> {
> struct bpf_redirect_info *ri = this_cpu_ptr(&bpf_redirect_info);
> struct bpf_map *map = READ_ONCE(ri->map);
> + struct xdp_sock *xs
Right, so I'm not claiming I'm following what's happening here.
This is on a 4.14 LTS + stuff android device kernel...
which isn't exactly trustworthy...
backporting this patch (ie. the one I proposed reverting) would
potentially fix things,
but I don't really understand why we need this kmemleak
Introduce a flag that can be specified during the bind() call
of an AF_XDP socket to receive packets directly from a queue when there is
no XDP program attached to the device.
This is enabled by introducing a special BPF prog pointer called
BPF_PROG_DIRECT_XSK and a new bind flag XDP_DIRECT that c
Don't allow an AF_XDP socket trying to bind with XDP_DIRECT bind
flag when a normal XDP program is already attached to the device,
Don't attach the default XDP program when AF_XDP socket is created
with XDP_DIRECT bind flag.
Signed-off-by: Sridhar Samudrala
---
tools/lib/bpf/xsk.c | 6 ++
1
This option enables an AF_XDP socket to bind with a XDP_DIRECT flag
that allows packets received on the associated queue to be received
directly when an XDP program is not attached.
Signed-off-by: Sridhar Samudrala
---
samples/bpf/xdpsock_user.c | 17 +
1 file changed, 13 inserti
Currently the users of bpf prog id access it directly via prog->aux->id.
Next patch in this series introduces a special bpf prog pointer to support
AF_XDP sockets bound to a queue to receive packets from that queue directly.
As the special bpf prog pointer is not associated with any struct bpf_prog
This is a rework of the following patch series
https://lore.kernel.org/netdev/1565840783-8269-1-git-send-email-sridhar.samudr...@intel.com/#r
that tried to enable direct receive by bypassing XDP program attached
to the device.
Based on the community feedback and some suggestions from Bjorn, chang
On Mon, Oct 7, 2019 at 9:56 PM Alexei Starovoitov wrote:
>
> On 10/7/19 3:47 PM, Andrii Nakryiko wrote:
> > Add few macros simplifying BCC-like multi-level probe reads, while also
> > emitting CO-RE relocations for each read.
> >
> > Acked-by: John Fastabend
> > Acked-by: Song Liu
> > Signed-off
On Mon, Oct 7, 2019 at 10:35 PM Maciej Żenczykowski
wrote:
>
> From: Maciej Żenczykowski
Please, at least a simple copy-n-paste of kmemleak report will
help a lot here. A changelog would save your time and mine too.
Thanks.
Maciej Żenczykowski wrote:
> From: Maciej Żenczykowski
>
> This reverts commit 114aa35d06d4920c537b72f9fa935de5dd205260.
>
> By my understanding of kmemleak the reasoning for this patch
> is incorrect. If kmemleak couldn't handle rcu we'd have it
> reporting leaks all over the place. My belie
Maciej Żenczykowski wrote:
> From: Maciej Żenczykowski
>
> Cc: Cong Wang
> Cc: Eric Dumazet
> Cc: Pablo Neira Ayuso
> Signed-off-by: Maciej Żenczykowski
> ---
> net/netfilter/nf_conntrack_core.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/net/netfilter/nf_con
On Mon, Oct 7, 2019 at 10:35 PM Maciej Żenczykowski
wrote:
>
> From: Maciej Żenczykowski
>
> This reverts commit 114aa35d06d4920c537b72f9fa935de5dd205260.
>
> By my understanding of kmemleak the reasoning for this patch
> is incorrect. If kmemleak couldn't handle rcu we'd have it
> reporting lea
On Mon, Oct 07, 2019 at 04:59:31PM +0300, Leon Romanovsky wrote:
> From: Yamin Friedman
>
> Expose maximum scatter entries per RDMA READ for optimal performance.
>
> Signed-off-by: Yamin Friedman
> Reviewed-by: Or Gerlitz
> Signed-off-by: Leon Romanovsky
> ---
> include/linux/mlx5/mlx5_ifc.h |
On Sun, Oct 06, 2019 at 10:46:40AM +0800, kbuild test robot wrote:
> tree:
> https://git.kernel.org/pub/scm/linux/kernel/git/klassert/ipsec-next.git
> testing
> head: 5374d99ba41893b4bb1ddbe35a88b1f08e860903
> commit: 735de2631f8680ac714df1ecc8e052785e9f9f8e [7/8] xfrm: add espintcp
> (RFC 8
Firstly, thank you stephen.
Hi, kuznet:
1. according to my test, bandwidth limitation is inaccurate for
ingress ipv6 . The accuracy is affected by burst. if rate is less
than 100mbit , set burst to 1MB or 2MB, the result is almost
acceptable. but when rate is bigger , the result is approxi
On Mon, Oct 07, 2019 at 03:22:30PM -0700, Bart Van Assche wrote:
> On 10/7/19 9:03 AM, Leon Romanovsky wrote:
> > On Mon, Oct 07, 2019 at 08:07:55AM -0700, Bart Van Assche wrote:
> > > On 10/7/19 6:59 AM, Leon Romanovsky wrote:
> > > >/*
> > > > - * Check if the device might use memory registra
On Mon, Oct 07, 2019 at 05:38:55PM -0700, Qing Huang wrote:
> I know this is not critical. Maybe someone can merge this or fix it with
> other commits? Thanks.
It is not "linux-rdma", but netdev. Your chances will be much higher if
you use get_maintainer.pl and put relevant mailing lists together
This adds experimental support for RTL8117. This chip version is found
on the ASUS Pro WS X570-ACE board. I have no hardware to test,
therefore I'd appreciate if people owning this board could test and
provide feedback.
Signed-off-by: Heiner Kallweit
---
drivers/net/ethernet/realtek/r8169_main.c
Please think both these patches through.
I'm not going to claim I'm 100% certain of their correctness.
I'm confused by:
include/net/netfilter/nf_conntrack.h:65:
* beware nf_ct_get() is different and don't inc refcnt.
and maybe there's some subtlety to this krealloc+rcu+kmemleak thing I'm miss
From: Maciej Żenczykowski
This reverts commit 114aa35d06d4920c537b72f9fa935de5dd205260.
By my understanding of kmemleak the reasoning for this patch
is incorrect. If kmemleak couldn't handle rcu we'd have it
reporting leaks all over the place. My belief is that this
was instead papering over a
From: Maciej Żenczykowski
Cc: Cong Wang
Cc: Eric Dumazet
Cc: Pablo Neira Ayuso
Signed-off-by: Maciej Żenczykowski
---
net/netfilter/nf_conntrack_core.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/net/netfilter/nf_conntrack_core.c
b/net/netfilter/nf_conntrack_core.c
On 10/7/19 3:47 PM, Andrii Nakryiko wrote:
> Add few macros simplifying BCC-like multi-level probe reads, while also
> emitting CO-RE relocations for each read.
>
> Acked-by: John Fastabend
> Acked-by: Song Liu
> Signed-off-by: Andrii Nakryiko
...
> +/*
> + * BPF_CORE_READ() is used to simplify
From: Martin Varghese
The openvswitch was supporting a MPLS label depth of 1 in the ingress
direction though the userspace OVS supports a max depth of 3 labels.
This change enables openvswitch module to support a max depth of
3 labels in the ingress.
Signed-off-by: Martin Varghese
---
net/open
On Tue, Oct 8, 2019 at 12:24 PM Alexei Starovoitov
wrote:
>
> On Mon, Oct 7, 2019 at 10:21 AM Daniel T. Lee wrote:
> >
> > Currently, at xdp_adjust_tail_kern.c, MAX_PCKT_SIZE is limited
> > to 600. To make this size flexible, static global variable
> > 'max_pcktsz' is added.
> >
> > By updating n
On Mon, Oct 7, 2019 at 10:21 AM Daniel T. Lee wrote:
>
> Currently, at xdp_adjust_tail_kern.c, MAX_PCKT_SIZE is limited
> to 600. To make this size flexible, static global variable
> 'max_pcktsz' is added.
>
> By updating new packet size from the user space, xdp_adjust_tail_kern.o
> will use this
On Wed, Oct 2, 2019 at 10:07 AM Pravin Shelar wrote:
>
> On Sun, Sep 29, 2019 at 7:09 PM wrote:
> >
> > From: Tonghao Zhang
> >
> > The most case *index < ma->max, we add likely for performance.
> >
> > Signed-off-by: Tonghao Zhang
> > ---
> > net/openvswitch/flow_table.c | 2 +-
> > 1 file ch
On Mon, Oct 7, 2019 at 9:21 AM Stanislav Fomichev wrote:
>
> While having a per-net-ns flow dissector programs is convenient for
> testing, security-wise it's better to have only one vetted global
> flow dissector implementation.
>
> Let's have a convention that when BPF flow dissector is installe
On Wed, Oct 2, 2019 at 10:03 AM Pravin Shelar wrote:
>
> On Sun, Sep 29, 2019 at 7:09 PM wrote:
> >
> > From: Tonghao Zhang
> >
> > The full looking up on flow table traverses all mask array.
> > If mask-array is too large, the number of invalid flow-mask
> > increase, performance will be drop.
On Mon, Oct 7, 2019 at 1:51 AM Anton Ivanov
wrote:
>
> Signed-off-by: Anton Ivanov
Please add some text to commit log even for trivial patches.
I fixed it up this time and applied.
On Fri, Oct 4, 2019 at 10:07 PM Alexei Starovoitov wrote:
>
> Pointer to BTF object is a pointer to kernel object or NULL.
> The memory access in the interpreter has to be done via probe_kernel_read
> to avoid page faults.
>
> Signed-off-by: Alexei Starovoitov
> ---
LGTM.
Acked-by: Andrii Nakry
On Mon, 7 Oct 2019 19:38:15 -0700, Alexei Starovoitov wrote:
> On Mon, Oct 7, 2019 at 7:23 PM Jakub Kicinski wrote:
> > On Mon, 7 Oct 2019 19:16:45 -0700, Alexei Starovoitov wrote:
> > > On Mon, Oct 7, 2019 at 7:00 PM Jakub Kicinski wrote:
> > > > On Mon, 7 Oct 2019 15:56:04 -0700, Andrii Nakry
On Mon, Oct 7, 2019 at 7:23 PM Jakub Kicinski
wrote:
>
> On Mon, 7 Oct 2019 19:16:45 -0700, Alexei Starovoitov wrote:
> > On Mon, Oct 7, 2019 at 7:00 PM Jakub Kicinski wrote:
> > > On Mon, 7 Oct 2019 15:56:04 -0700, Andrii Nakryiko wrote:
> > > > diff --git a/tools/bpf/bpftool/prog.c b/tools/bpf/b
On Mon, 7 Oct 2019 19:16:45 -0700, Alexei Starovoitov wrote:
> On Mon, Oct 7, 2019 at 7:00 PM Jakub Kicinski wrote:
> > On Mon, 7 Oct 2019 15:56:04 -0700, Andrii Nakryiko wrote:
> > > diff --git a/tools/bpf/bpftool/prog.c b/tools/bpf/bpftool/prog.c
> > > index 43fdbbfe41bb..27da96a797ab 100644
>
On Mon, Oct 7, 2019 at 7:00 PM Jakub Kicinski
wrote:
>
> On Mon, 7 Oct 2019 15:56:04 -0700, Andrii Nakryiko wrote:
> > diff --git a/tools/bpf/bpftool/prog.c b/tools/bpf/bpftool/prog.c
> > index 43fdbbfe41bb..27da96a797ab 100644
> > --- a/tools/bpf/bpftool/prog.c
> > +++ b/tools/bpf/bpftool/prog.c
On Mon, 7 Oct 2019 15:56:04 -0700, Andrii Nakryiko wrote:
> diff --git a/tools/bpf/bpftool/prog.c b/tools/bpf/bpftool/prog.c
> index 43fdbbfe41bb..27da96a797ab 100644
> --- a/tools/bpf/bpftool/prog.c
> +++ b/tools/bpf/bpftool/prog.c
> @@ -1092,9 +1092,7 @@ static int do_run(int argc, char **argv)
>
On Mon, Oct 7, 2019 at 3:58 PM Andrii Nakryiko wrote:
>
> As part of libbpf in 5e61f2707029 ("libbpf: stop enforcing kern_version,
> populate it for users") non-LIBBPF_API __bpf_object__open_xattr() API
> was removed from libbpf.h header. This broke bpftool, which relied on
> that function. This p
On Wed, Oct 2, 2019 at 10:02 AM Pravin Shelar wrote:
>
> On Sun, Sep 29, 2019 at 7:09 PM wrote:
> >
> > From: Tonghao Zhang
> >
> > Port the codes to linux upstream and with little changes.
> >
> > Pravin B Shelar, says:
> > | mask caches index of mask in mask_list. On packet recv OVS
> > | need
On Fri, Oct 4, 2019 at 1:09 AM William Tu wrote:
>
> Hi Tonghao,
>
> Thanks for the patch.
>
> > On 29 Sep 2019, at 19:09, xiangxia.m@gmail.com wrote:
> >
> > > From: Tonghao Zhang
> > >
> > > This series patch optimize openvswitch.
> > >
> > > Patch 1, 2, 4: Port Pravin B Shelar patches to
>
On Fri, Oct 4, 2019 at 10:04 PM Alexei Starovoitov wrote:
>
> libbpf analyzes bpf C program, searches in-kernel BTF for given type name
> and stores it into expected_attach_type.
> The kernel verifier expects this btf_id to point to something like:
> typedef void (*btf_trace_kfree_skb)(void *, str
On Fri, Oct 4, 2019 at 10:04 PM Alexei Starovoitov wrote:
>
> For raw tracepoint program types libbpf will try to find
> btf_id of raw tracepoint in vmlinux's BTF.
> It's a responsiblity of bpf program author to annotate the program
> with SEC("raw_tracepoint/name") where "name" is a valid raw tra
-- Andrii
On Mon, Oct 7, 2019 at 2:50 PM Andrii Nakryiko
wrote:
>
> On Mon, Oct 7, 2019 at 2:46 PM Stanislav Fomichev wrote:
> >
> > On 10/07, Andrii Nakryiko wrote:
> > > As part of libbpf in 5e61f2707029 ("libbpf: stop enforcing kern_version,
> > > populate it for users") non-LIBBPF_API __bpf_
As part of libbpf in 5e61f2707029 ("libbpf: stop enforcing kern_version,
populate it for users") non-LIBBPF_API __bpf_object__open_xattr() API
was removed from libbpf.h header. This broke bpftool, which relied on
that function. This patch fixes the build by switching to newly added
bpf_object__open
This patch set makes bpf_helpers.h and bpf_endian.h a part of libbpf itself
for consumption by user BPF programs, not just selftests. It also splits off
tracing helpers into bpf_tracing.h, which also becomes part of libbpf. Some of
the legacy stuff (BPF_ANNOTATE_KV_PAIR, load_{byte,half,word}, bpf_
Having GCC provide its own bpf-helper.h is not the right approach and is
going to be changed. Undo bpf_helpers.h change before moving
bpf_helpers.h into libbpf.
Acked-by: Song Liu
Acked-by: Ilya Leoshkevich
Acked-by: John Fastabend
Signed-off-by: Andrii Nakryiko
---
tools/testing/selftests/bp
Add few macros simplifying BCC-like multi-level probe reads, while also
emitting CO-RE relocations for each read.
Acked-by: John Fastabend
Acked-by: Song Liu
Signed-off-by: Andrii Nakryiko
---
tools/lib/bpf/bpf_helpers.h | 153 +++-
1 file changed, 150 insertion
Split-off PT_REGS-related helpers into bpf_tracing.h header. Adjust
selftests and samples to include it where necessary.
Acked-by: John Fastabend
Acked-by: Song Liu
Signed-off-by: Andrii Nakryiko
---
samples/bpf/map_perf_test_kern.c | 1 +
samples/bpf/offwaketime_kern.c|
Validate BPF_CORE_READ correctness and handling of up to 9 levels of
nestedness using cyclic task->(group_leader->)*->tgid chains.
Also add a test of maximum-dpeth BPF_CORE_READ_STR_INTO() macro.
Acked-by: John Fastabend
Acked-by: Song Liu
Signed-off-by: Andrii Nakryiko
---
.../selftests/bpf/
To allow adding a variadic BPF_CORE_READ macro with slightly different
syntax and semantics, define CORE_READ in CO-RE reloc tests, which is
a thin wrapper around low-level bpf_core_read() macro, which in turn is
just a wrapper around bpf_probe_read().
Acked-by: John Fastabend
Acked-by: Song Liu
Split off few legacy things from bpf_helpers.h into separate
bpf_legacy.h file:
- load_{byte|half|word};
- remove extra inner_idx and numa_node fields from bpf_map_def and
introduce bpf_map_def_legacy for use in samples;
- move BPF_ANNOTATE_KV_PAIR into bpf_legacy.h.
Adjust samples and selftests
Move bpf_helpers.h, bpf_tracing.h, and bpf_endian.h into libbpf. Move
bpf_helper_defs.h generation into libbpf's Makefile. Ensure all those
headers are installed along the other libbpf headers. Also, adjust
selftests and samples include path to include libbpf now.
Acked-by: Song Liu
Signed-off-by
syzbot got a NULL dereference in bond_update_slave_arr() [1],
happening after a failure to allocate bond->slave_arr
A workqueue (bond_slave_arr_handler) is supposed to retry
the allocation later, but if the slave is removed before
the workqueue had a chance to complete, bond->slave_err
can still b
On 10/7/19 9:03 AM, Leon Romanovsky wrote:
On Mon, Oct 07, 2019 at 08:07:55AM -0700, Bart Van Assche wrote:
On 10/7/19 6:59 AM, Leon Romanovsky wrote:
/*
- * Check if the device might use memory registration. This is currently only
- * true for iWarp devices. In the future we can hopefully
On Mon, Oct 7, 2019 at 1:51 AM Anton Ivanov
wrote:
>
> Signed-off-by: Anton Ivanov
Acked-by: Song Liu
For future patches, please specify "PATCH bpf-next" or "PATCH bpf" in
the subject line. This
one I guess goes to bpf-next.
Thanks,
Song
Hi,
On Mon, Oct 07, 2019 at 07:10:37AM -0700, Maciej Żenczykowski wrote:
> unsigned int
> nf_conntrack_in(struct sk_buff *skb, const struct nf_hook_state *state)
> {
> enum ip_conntrack_info ctinfo;
> struct nf_conn *ct, *tmpl;
> u_int8_t protonum;
> int dataoff, re
On 10/3/19 3:51 AM, Jiri Pirko wrote:
> From: Jiri Pirko
>
> Similar to ip tool, add an option to devlink to operate under certain
> network namespace. Unfortunately, "-n" is already taken, so use "-N"
> instead.
>
> Example:
>
> $ devlink -N testns1 dev show
>
> Signed-off-by: Jiri Pirko
> -
On 10/2/19 7:49 AM, Leon Romanovsky wrote:
> From: Leon Romanovsky
>
> RDMA has weak connection between PIDs and HW objects, because
> the latter tied to file descriptors for their lifetime management.
>
> The outcome of such connection is that for the following scenario,
> the returned PID will
On 10/2/19 4:56 AM, Jiri Pirko wrote:
> @@ -1106,7 +1106,8 @@ int iplink_get(char *name, __u32 filt_mask)
>
> if (name) {
> addattr_l(&req.n, sizeof(req),
> - IFLA_IFNAME, name, strlen(name) + 1);
> + !check_ifname(name) ? IFLA_IFNAM
On Mon, Oct 7, 2019 at 2:46 PM Stanislav Fomichev wrote:
>
> On 10/07, Andrii Nakryiko wrote:
> > As part of libbpf in 5e61f2707029 ("libbpf: stop enforcing kern_version,
> > populate it for users") non-LIBBPF_API __bpf_object__open_xattr() API
> > was removed from libbpf.h header. This broke bpft
On Mon, 2019-10-07 at 13:48 -0700, Joe Perches wrote:
> On Mon, 2019-10-07 at 13:44 -0700, Jeff Kirsher wrote:
> > On Sun, 2019-10-06 at 10:19 -0700, Joe Perches wrote:
> > > This got converted from strncpy to strlcpy but it's
> > > now not necessary to use one character less than the
> > > actual
On 10/07, Andrii Nakryiko wrote:
> As part of libbpf in 5e61f2707029 ("libbpf: stop enforcing kern_version,
> populate it for users") non-LIBBPF_API __bpf_object__open_xattr() API
> was removed from libbpf.h header. This broke bpftool, which relied on
> that function. This patch fixes the build by
On 10/2/19 4:56 AM, Jiri Pirko wrote:
> diff --git a/ip/iplink.c b/ip/iplink.c
> index 212a088535da..e3f8a28fe94c 100644
> --- a/ip/iplink.c
> +++ b/ip/iplink.c
> @@ -111,7 +111,9 @@ void iplink_usage(void)
> "\n"
> " ip link xstats type TYPE [ ARGS ]\n"
>
As part of libbpf in 5e61f2707029 ("libbpf: stop enforcing kern_version,
populate it for users") non-LIBBPF_API __bpf_object__open_xattr() API
was removed from libbpf.h header. This broke bpftool, which relied on
that function. This patch fixes the build by switching to newly added
bpf_object__open
On Mon, Oct 07, 2019 at 05:43:44PM +0100, Edward Cree wrote:
>
> (Although I also think full-blown dynamically-linked calls ought not to be
> impossible, *if* we restrict them to taking a ctx and returning a u64, in
> which case the callee can be verified as though it were a normal program,
> a
Greetings
My name is Barrister Hans Erich.
I have a client who is interested to invest in your country, she is a well
known politician in her country and deserve a lucrative investment partnership
with you outside her country without any delay Please can you manage such
investment please Kin
On Mon, 2019-10-07 at 13:44 -0700, Jeff Kirsher wrote:
> On Sun, 2019-10-06 at 10:19 -0700, Joe Perches wrote:
> > This got converted from strncpy to strlcpy but it's
> > now not necessary to use one character less than the
> > actual size.
> >
> > Perhaps the sizeof() - 1 is now not correct and i
On Mon, Oct 7, 2019 at 1:42 PM Andrii Nakryiko wrote:
>
> Current Makefile dependency chain is not strict enough and allows
> test_attach_probe.o to be built before test_progs's
> prog_test/attach_probe.o is built, which leads to assembler complaining
> about missing included binary.
>
> This patc
On Mon, Oct 07, 2019 at 12:11:31PM +0200, Toke Høiland-Jørgensen wrote:
> Alexei Starovoitov writes:
>
> > On Fri, Oct 04, 2019 at 07:22:41PM +0200, Toke Høiland-Jørgensen wrote:
> >> From: Toke Høiland-Jørgensen
> >>
> >> This adds support for injecting chain call logic into eBPF programs befo
On Sun, 2019-10-06 at 10:19 -0700, Joe Perches wrote:
> This got converted from strncpy to strlcpy but it's
> now not necessary to use one character less than the
> actual size.
>
> Perhaps the sizeof() - 1 is now not correct and it
> should use strscpy and a normal sizeof.
>
> from:
>
> commit
On Mon, Oct 07, 2019 at 07:20:36PM +0200, Toke Høiland-Jørgensen wrote:
> From: Toke Høiland-Jørgensen
>
> This adds support for wrapping eBPF program dispatch in chain calling
> logic. The code injection is controlled by a flag at program load time; if
> the flag is set, the BPF program will car
Current Makefile dependency chain is not strict enough and allows
test_attach_probe.o to be built before test_progs's
prog_test/attach_probe.o is built, which leads to assembler complaining
about missing included binary.
This patch is a minimal fix to fix this issue by enforcing that
test_attach_p
On Mon, Oct 07, 2019 at 07:20:37PM +0200, Toke Høiland-Jørgensen wrote:
> From: Toke Høiland-Jørgensen
>
> This adds support for setting and deleting bpf chain call programs through
> a couple of new commands in the bpf() syscall. The CHAIN_ADD and CHAIN_DEL
> commands take two eBPF program fds a
Marcelo noticed a backward compatibility issue of TCA_KIND
after we move from NLA_STRING to NLA_NUL_STRING, so it is probably
too late to change it.
Instead, to make everyone happy, we can just insert a NUL to
terminate the string with nla_strlcpy() like we do for TC actions.
Fixes: 62794fc4fbf5
For TCA_ACT_KIND, we have to keep the backward compatibility too,
and rely on nla_strlcpy() to check and terminate the string with
a NUL.
Note for TC actions, nla_strcmp() is already used to compare kind
strings, so we don't need to fix other places.
Fixes: 199ce850ce11 ("net_sched: add policy va
On Mon, Oct 07, 2019 at 12:11:31PM +0200, Toke Høiland-Jørgensen wrote:
> Alexei Starovoitov writes:
> > On Fri, Oct 04, 2019 at 07:22:41PM +0200, Toke Høiland-Jørgensen wrote:
> >> From: Toke Høiland-Jørgensen
> >>
> >> This adds support for injecting chain call logic into eBPF programs before
On 07/10/2019 18:12, Lorenz Bauer wrote:
> Sure, but this is the simplest, not necessarily realistic use case. There
> is a reason that libbpf has the API it has. For example, we patch our
> eBPF before loading it. I'm sure there are other complications, which is
> why I prefer to keep loading my o
syzbot reported a warning [1] that triggered after recent Jiri patch.
This exposes a bug that we hit already in the past (see commit
ff244c6b29b1 ("tun: handle register_netdevice() failures properly")
for details)
tun uses priv->destructor without an ndo_init() method.
register_netdevice() can r
Toke Høiland-Jørgensen wrote:
> This series adds support for executing multiple XDP programs on a single
> interface in sequence, through the use of chain calls, as discussed at the
> Linux
> Plumbers Conference last month:
>
> https://linuxplumbersconf.org/event/4/contributions/460/
>
Can we a
On Mon, Oct 7, 2019 at 2:43 AM Daniel Borkmann wrote:
>
> On Sun, Oct 06, 2019 at 08:07:36PM -0700, Andrii Nakryiko wrote:
> > Various small fixes to BPF helper documentation comments, enabling
> > automatic header generation with a list of BPF helpers.
> >
> > Signed-off-by: Andrii Nakryiko
> >
On Sun, Oct 6, 2019 at 10:29 PM Alexei Starovoitov
wrote:
>
> On Sun, Oct 6, 2019 at 8:31 PM Andrii Nakryiko wrote:
> >
> > Current Makefile dependency chain is not strict enough and allows
> > test_attach_probe.o to be built before test_progs's
> > prog_test/attach_probe.o is built, which leads
From: Toke Høiland-Jørgensen
This adds simple syscall wrappers for the new BPF_PROG_CHAIN_* commands to
libbpf.
Signed-off-by: Toke Høiland-Jørgensen
---
tools/lib/bpf/bpf.c | 34 ++
tools/lib/bpf/bpf.h |4
tools/lib/bpf/libbpf.map |3 ++
From: Toke Høiland-Jørgensen
This adds support for setting and deleting bpf chain call programs through
a couple of new commands in the bpf() syscall. The CHAIN_ADD and CHAIN_DEL
commands take two eBPF program fds and a return code, and install the
'next' program to be chain called after the 'pre
Currently, at xdp_adjust_tail_kern.c, MAX_PCKT_SIZE is limited
to 600. To make this size flexible, static global variable
'max_pcktsz' is added.
By updating new packet size from the user space, xdp_adjust_tail_kern.o
will use this value as a new max packet size.
This static global variable can be
From: Toke Høiland-Jørgensen
This adds new self tests for the XDP chain call functionality.
Signed-off-by: Toke Høiland-Jørgensen
---
tools/testing/selftests/bpf/.gitignore|1
tools/testing/selftests/bpf/Makefile |3
tools/testing/selftests/bpf/progs/xdp_dummy.c |
From: Toke Høiland-Jørgensen
This updates the bpf.h UAPI header in tools/ to add the bpf chain
call-related definitions.
Signed-off-by: Toke Høiland-Jørgensen
---
tools/include/uapi/linux/bpf.h | 16
1 file changed, 16 insertions(+)
diff --git a/tools/include/uapi/linux/bpf
This series adds support for executing multiple XDP programs on a single
interface in sequence, through the use of chain calls, as discussed at the Linux
Plumbers Conference last month:
https://linuxplumbersconf.org/event/4/contributions/460/
# HIGH-LEVEL IDEA
Since Alexei pointed out some issue
From: Toke Høiland-Jørgensen
This adds support for wrapping eBPF program dispatch in chain calling
logic. The code injection is controlled by a flag at program load time; if
the flag is set, the BPF program will carry a flag bit that changes the
program dispatch logic to wrap it in a chain call l
On Tue, Oct 8, 2019 at 1:41 AM Andrii Nakryiko
wrote:
>
> On Mon, Oct 7, 2019 at 9:06 AM Daniel T. Lee wrote:
> >
> > Currently, at xdp_adjust_tail_kern.c, MAX_PCKT_SIZE is limited
> > to 600. To make this size flexible, static global variable
> > 'max_pcktsz' is added.
> >
> > By updating new pa
On Mon, 7 Oct 2019 at 17:43, Edward Cree wrote:
>
> I might be being naïve, but it doesn't sound more painful than is normal
> for userland. I mean, what operations have you got-
> * create/destroy map (maybe, see above)
> * load prog (pass it an fd from which it can read an ELF, and more fds
>
On Sun, 6 Oct 2019, Andrii Nakryiko wrote:
> Current Makefile dependency chain is not strict enough and allows
> test_attach_probe.o to be built before test_progs's
> prog_test/attach_probe.o is built, which leads to assembler compainig
> about missing included binary.
>
> This patch is a minimal
On Mon, Oct 7, 2019 at 9:14 AM Stanislav Fomichev wrote:
>
> On 10/04, Andrii Nakryiko wrote:
> > Kernel version enforcement for kprobes/kretprobes was removed from
> > 5.0 kernel in 6c4fc209fcf9 ("bpf: remove useless version check for prog
> > load").
> > Since then, BPF programs were specifying
On 04/10/2019 16:58, Lorenz Bauer wrote:
> If you want to support
> all use cases (which you kind of have to) then you'll end up writing an
> RPC wrapper for libbpf,
Yes, you more-or-less would need that. Though I think you can e.g. have
the clients load & pin their own maps and then pass the map
On Mon, Oct 7, 2019 at 9:06 AM Daniel T. Lee wrote:
>
> Currently, at xdp_adjust_tail_kern.c, MAX_PCKT_SIZE is limited
> to 600. To make this size flexible, static global variable
> 'max_pcktsz' is added.
>
> By updating new packet size from the user space, xdp_adjust_tail_kern.o
> will use this v
On Fri, 4 Oct 2019, Alexei Starovoitov wrote:
> libbpf analyzes bpf C program, searches in-kernel BTF for given type name
> and stores it into expected_attach_type.
> The kernel verifier expects this btf_id to point to something like:
> typedef void (*btf_trace_kfree_skb)(void *, struct sk_buff *s
While having a per-net-ns flow dissector programs is convenient for
testing, security-wise it's better to have only one vetted global
flow dissector implementation.
Let's have a convention that when BPF flow dissector is installed
in the root namespace, child namespaces can't override it.
The int
Always use init_net flow dissector BPF program if it's attached and fall
back to the per-net namespace one. Also, deny installing new programs if
there is already one attached to the root namespace.
Users can still detach their BPF programs, but can't attach any
new ones (-EEXIST).
Cc: Petar Penko
Make sure non-root namespaces get an error if root flow dissector is
attached.
Cc: Petar Penkov
Acked-by: Song Liu
Signed-off-by: Stanislav Fomichev
---
.../selftests/bpf/test_flow_dissector.sh | 48 ---
1 file changed, 42 insertions(+), 6 deletions(-)
diff --git a/tools
On 10/04, Andrii Nakryiko wrote:
> Kernel version enforcement for kprobes/kretprobes was removed from
> 5.0 kernel in 6c4fc209fcf9 ("bpf: remove useless version check for prog
> load").
> Since then, BPF programs were specifying SEC("version") just to please
> libbpf. We should stop enforcing this
Currently, at xdp_adjust_tail_kern.c, MAX_PCKT_SIZE is limited
to 600. To make this size flexible, static global variable
'max_pcktsz' is added.
By updating new packet size from the user space, xdp_adjust_tail_kern.o
will use this value as a new max packet size.
This static global variable can be
On Mon, Oct 07, 2019 at 08:07:55AM -0700, Bart Van Assche wrote:
> On 10/7/19 6:59 AM, Leon Romanovsky wrote:
> > /*
> > - * Check if the device might use memory registration. This is currently
> > only
> > - * true for iWarp devices. In the future we can hopefully fine tune this
> > based
> >
On Mon, Oct 07, 2019 at 08:12:37AM -0700, Bart Van Assche wrote:
> On 10/7/19 6:59 AM, Leon Romanovsky wrote:
> > diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h
> > index 4f671378dbfc..60fd98a9b7e8 100644
> > --- a/include/rdma/ib_verbs.h
> > +++ b/include/rdma/ib_verbs.h
> > @@ -44
1 - 100 of 170 matches
Mail list logo