From: Eduard Zingerman <eddyz87@gmail.com>
To: Matt Bobrowski <mattbobrowski@google.com>
Cc: bpf@vger.kernel.org, andrii@kernel.org, acme@redhat.com
Subject: Re: bpf: Question about odd BPF verifier behaviour
Date: Mon, 27 Feb 2023 16:17:35 +0200 [thread overview]
Message-ID: <693dffd9571073a47820653fd2de863010491454.camel@gmail.com> (raw)
In-Reply-To: <c4cda35711804ec26ebaeedc07d10d5d51901495.camel@gmail.com>
On Sun, 2023-02-26 at 03:03 +0200, Eduard Zingerman wrote:
> On Sat, 2023-02-25 at 20:50 +0000, Matt Bobrowski wrote:
> > Sorry Eduard, I replied late last night although the email bounced due
> > to exceeding the mail char limit. Let's try attaching a compressed
> > variant of the requested files, which includes the compiled kernel's
> > BTF and the kernel's config.
>
> Hi Matt,
>
> I tried using your config but still can't reproduce the issue.
> Will try to do it using debian 12 chroot tomorrow or on Monday.
Hi Matt,
Short update:
I've reproduced the issue with multiple STRUCT 'linux_binprm' BTF IDs
in Debian testing chroot, thank you for providing all details.
Attaching the instructions in the end of the email.
Need some time to analyze pahole behavior.
Thanks,
Eduard
--
host root:
mkdir bookworm
sudo debootstrap testing bookworm/ http://deb.debian.org/debian/
sudo mount -t proc proc bookworm/proc/
sudo mount -t sysfs sys bookworm/sys/
sudo chroot bookworm/ /bin/bash
bookworm root:
apt install python3 bc build-essential git \
cmake libdwarf-dev libdw-dev flex bison \
kmod cpio libncurses5-dev libelf-dev libssl-dev
adduser eddy
sudo eddy
bookworm user:
cd ~
git clone git://git.kernel.org/pub/scm/devel/pahole/pahole.git
mkdir build && \
cd build && \
cmake -D__LIB=lib .. && \
make -j $(nproc)
export PATH=/home/eddy/pahole/build/:$PATH
cd ~
git clone https://github.com/torvalds/linux.git && cd linux
make defconfig && make kvm_guest.config
scripts/config \
-e BPF \
-e BPF_SYSCALL \
-e BPF_LSM \
-e BPF_JIT \
-e BPF_EVENTS \
-e DEBUG_INFO \
-e DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT \
-e DEBUG_INFO_BTF \
-e DEBUG_INFO_BTF_MODULES \
-e PAHOLE_HAS_SPLIT_BTF \
-e FTRACE \
-e DYNAMIC_FTRACE \
-e FUNCTION_TRACER
make olddefconfig
# Multiple warnings in the end:
# WARN: multiple IDs found for 'task_struct': 176, 23383 - using 176
# WARN: multiple IDs found for 'file': 638, 23422 - using 638
# ...
make -C ./tools/bpf/bpftool
./tools/bpf/bpftool/bpftool btf dump file ./vmlinux | \
grep -c linux_binprm
# The output is 19 for me
Repository versions:
- kernel:
f3a2439f20d9 ("Merge tag 'rproc-v6.3' of git://git.kernel.org/pub/scm/linux/kernel/git/remoteproc/linux")
- pahole:
431df45 ("btfdiff: Exclude Rust CUs since those are not yet being converted to BTF on the Linux kernel")
next prev parent reply other threads:[~2023-02-27 14:17 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-20 22:35 bpf: Question about odd BPF verifier behaviour Matt Bobrowski
2023-02-21 20:00 ` Matt Bobrowski
2023-02-22 15:28 ` Eduard Zingerman
2023-02-23 9:37 ` Matt Bobrowski
2023-02-23 12:42 ` Eduard Zingerman
2023-02-23 14:15 ` Eduard Zingerman
2023-02-24 5:31 ` Matt Bobrowski
2023-02-24 14:14 ` Eduard Zingerman
2023-02-25 20:50 ` Matt Bobrowski
2023-02-26 1:03 ` Eduard Zingerman
2023-02-27 14:17 ` Eduard Zingerman [this message]
2023-02-27 17:31 ` Andrii Nakryiko
2023-02-27 18:04 ` KP Singh
2023-02-27 18:10 ` KP Singh
2023-02-27 19:24 ` Andrii Nakryiko
2023-02-27 19:29 ` Eduard Zingerman
2023-02-27 19:31 ` Andrii Nakryiko
2023-02-27 20:48 ` Eduard Zingerman
2023-02-28 2:55 ` KP Singh
2023-02-28 18:08 ` Eduard Zingerman
2023-02-28 18:56 ` Andrii Nakryiko
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=693dffd9571073a47820653fd2de863010491454.camel@gmail.com \
--to=eddyz87@gmail.com \
--cc=acme@redhat.com \
--cc=andrii@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=mattbobrowski@google.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox