From: Yafang Shao <laoar.shao@gmail.com>
To: ast@kernel.org, daniel@iogearbox.net, andrii@kernel.org,
kafai@fb.com, songliubraving@fb.com, yhs@fb.com,
john.fastabend@gmail.com, kpsingh@kernel.org, sdf@google.com,
haoluo@google.com, jolsa@kernel.org
Cc: bpf@vger.kernel.org, Yafang Shao <laoar.shao@gmail.com>
Subject: [PATCH bpf-next v2 0/3] bpf: bpf trampoline improvements
Date: Mon, 15 May 2023 13:08:46 +0000 [thread overview]
Message-ID: <20230515130849.57502-1-laoar.shao@gmail.com> (raw)
When we run fexit bpf programs (e.g. attaching tcp_recvmsg) on our servers
which were running old kernels, some of these servers crashed. Finally we
figured out that it was caused by the same issue resolved by
commit e21aa341785c ("bpf: Fix fexit trampoline."). After we backported
that commit, the crash disappears. However new issues are introduced by
that commit. This patchset fixes them.
PATCH #1: Fix a memory leak found on our server
PATCH #2: Remove bpf trampoline selector and also fix the issue in perf
caused by the name change in bpf trampoline
PATCH #3: Show target_{obj,btf}_id when link to a bpf trampoline
v1->v2:
- Reuse the common code between __bpf_tramp_image_put_deferred and
bpf_tramp_image_free (Song)
- Add fixes tag in patch #1 (Song)
- Restore the old bpf trampoline name format (Song)
- Jiri pointed out a issue in perf
- Show btf information in the tracing link info
Yafang Shao (3):
bpf: Fix memleak due to fentry attach failure
bpf: Remove bpf trampoline selector
bpf: Show target_{obj,btf}_id in tracing link info
include/linux/bpf.h | 1 -
kernel/bpf/syscall.c | 12 ++++++++++--
kernel/bpf/trampoline.c | 32 +++++++++++++++++++-------------
tools/bpf/bpftool/link.c | 4 ++++
4 files changed, 33 insertions(+), 16 deletions(-)
--
1.8.3.1
next reply other threads:[~2023-05-15 13:09 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-15 13:08 Yafang Shao [this message]
2023-05-15 13:08 ` [PATCH bpf-next v2 1/3] bpf: Fix memleak due to fentry attach failure Yafang Shao
2023-05-15 15:52 ` Song Liu
2023-05-15 20:17 ` Daniel Borkmann
2023-05-15 21:14 ` Song Liu
2023-05-15 21:49 ` Daniel Borkmann
2023-05-15 13:08 ` [PATCH bpf-next v2 2/3] bpf: Remove bpf trampoline selector Yafang Shao
2023-05-15 15:53 ` Song Liu
2023-05-15 20:42 ` Daniel Borkmann
2023-05-15 13:08 ` [PATCH bpf-next v2 3/3] bpf: Show target_{obj,btf}_id in tracing link info Yafang Shao
2023-05-15 16:12 ` Song Liu
2023-05-16 2:21 ` Yafang Shao
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=20230515130849.57502-1-laoar.shao@gmail.com \
--to=laoar.shao@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=haoluo@google.com \
--cc=john.fastabend@gmail.com \
--cc=jolsa@kernel.org \
--cc=kafai@fb.com \
--cc=kpsingh@kernel.org \
--cc=sdf@google.com \
--cc=songliubraving@fb.com \
--cc=yhs@fb.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