path: root/samples/bpf/xdp_redirect_user.c
diff options
authorMaciej Fijalkowski <maciejromanfijalkowski@gmail.com>2019-02-01 22:42:26 +0100
committerDaniel Borkmann <daniel@iogearbox.net>2019-02-01 23:37:51 +0100
commit6a5457618f62147aeac706d26ff28e0e57a324e3 (patch)
tree245cfdab823957b6dcdc0cdf2ad8432be72d9857 /samples/bpf/xdp_redirect_user.c
parentbbaf6029c49ccf2dc93d9564af58a20d125947a1 (diff)
samples/bpf: Extend RLIMIT_MEMLOCK for xdp_{sample_pkts, router_ipv4}
There is a common problem with xdp samples that happens when user wants to run a particular sample and some bpf program is already loaded. The default 64kb RLIMIT_MEMLOCK resource limit will cause a following error (assuming that xdp sample that is failing was converted to libbpf usage): libbpf: Error in bpf_object__probe_name():Operation not permitted(1). Couldn't load basic 'r0 = 0' BPF program. libbpf: failed to load object './xdp_sample_pkts_kern.o' Fix it in xdp_sample_pkts and xdp_router_ipv4 by setting RLIMIT_MEMLOCK to RLIM_INFINITY. Signed-off-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com> Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com> Acked-by: Jesper Dangaard Brouer <brouer@redhat.com> Acked-by: John Fastabend <john.fastabend@gmail.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Diffstat (limited to 'samples/bpf/xdp_redirect_user.c')
0 files changed, 0 insertions, 0 deletions