DPDK patches and discussions
 help / color / mirror / Atom feed
From: bugzilla@dpdk.org
To: dev@dpdk.org
Subject: [dpdk-dev] [Bug 281] BPF: Linking error in librte_bpf
Date: Sat, 18 May 2019 01:34:01 +0000	[thread overview]
Message-ID: <bug-281-3@http.bugs.dpdk.org/> (raw)

https://bugs.dpdk.org/show_bug.cgi?id=281

            Bug ID: 281
           Summary: BPF: Linking error in librte_bpf
           Product: DPDK
           Version: 19.08
          Hardware: x86
                OS: Linux
            Status: CONFIRMED
          Severity: normal
          Priority: Normal
         Component: testpmd
          Assignee: dev@dpdk.org
          Reporter: michel@digirati.com.br
  Target Milestone: ---

I've downloaded DPDK from the git repository (19.08-rc0), installed libelf and
libelf-dev, enabled CONFIG_RTE_LIBRTE_BPF_ELF in config/common_base, made
config for target "x86_64-native-linuxapp-gcc", and built it. My machine is
running Ubuntu 18.04.1. Then, I ran the following commands:

$ cd $RTE_SDK/$RTE_TARGET/app/

$ sudo ./testpmd -l 0-3 -n 4 -- -i --portmask=0x1 --nb-cores=2
[INITIALIZATION MESSAGES]

testpmd> bpf-load rx 0 0 - /home/michel/git/latest_dpdk/examples/bpf/t1.o
rte_bpf_elf_load() is not supported with current config
rebuild with libelf installed
-95:Operation not supported

Investigating this issue, I've found that it is a linking error since function
rte_bpf_elf_load() is being mapped to bpf_load.o instead of bpf_load_elf.o:

$ grep ^rte_bpf_elf_load x86_64-native-linuxapp-gcc/app/testpmd.map 
rte_bpf_elf_load                                 
/home/michel/test_latest_dpdk/dpdk/x86_64-native-linuxapp-gcc/lib/librte_bpf.a(bpf_load.o)

I also noticed that file bpf_load_elf.o after file bpf_load.o in librte_bpf.a:

$ ar t build/lib/librte_bpf.a
bpf.o
bpf_exec.o
bpf_load.o
bpf_pkt.o
bpf_validate.o
bpf_load_elf.o
bpf_jit_x86.o

-- 
You are receiving this mail because:
You are the assignee for the bug.

             reply	other threads:[~2019-05-18  1:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-18  1:34 bugzilla [this message]
2019-05-20 15:03 ` bugzilla

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=bug-281-3@http.bugs.dpdk.org/ \
    --to=bugzilla@dpdk.org \
    --cc=dev@dpdk.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).