From: Ilya Leoshkevich <iii@linux.ibm.com>
To: Alexei Starovoitov <ast@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
Andrii Nakryiko <andrii@kernel.org>
Cc: bpf@vger.kernel.org, Heiko Carstens <hca@linux.ibm.com>,
Vasily Gorbik <gor@linux.ibm.com>,
Alexander Gordeev <agordeev@linux.ibm.com>,
Song Liu <song@kernel.org>, Ilya Leoshkevich <iii@linux.ibm.com>
Subject: [PATCH bpf 0/2] s390/bpf: Fix backchain issues in the trampoline
Date: Tue, 10 Oct 2023 22:20:08 +0200 [thread overview]
Message-ID: <20231010203512.385819-1-iii@linux.ibm.com> (raw)
Hi,
Song reported that a patch he wrote was causing kernel panics on s390.
The disassembly printed by the kernel indicated that the stored
backchain was not a valid pointer; setting a watchpoint in GDB has
shown the culprit: the trampoline.
Currently it's implemented without regard for backchain: it clobbers
the caller's backchain and causes the issue reported by Song, and also
doesn't store its own, making it impossible to unwind past itself.
This series fixes both problems.
Best regards,
Ilya
[1] https://lore.kernel.org/bpf/20231004004350.533234-1-song@kernel.org/
Ilya Leoshkevich (2):
s390/bpf: Fix clobbering the caller's backchain in the trampoline
s390/bpf: Fix unwinding past the trampoline
arch/s390/net/bpf_jit_comp.c | 25 ++++++++++++++++++++-----
1 file changed, 20 insertions(+), 5 deletions(-)
--
2.41.0
next reply other threads:[~2023-10-10 20:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-10 20:20 Ilya Leoshkevich [this message]
2023-10-10 20:20 ` [PATCH bpf 1/2] s390/bpf: Fix clobbering the caller's backchain in the trampoline Ilya Leoshkevich
2023-10-10 20:20 ` [PATCH bpf 2/2] s390/bpf: Fix unwinding past " Ilya Leoshkevich
2023-10-10 22:10 ` [PATCH bpf 0/2] s390/bpf: Fix backchain issues in " patchwork-bot+netdevbpf
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=20231010203512.385819-1-iii@linux.ibm.com \
--to=iii@linux.ibm.com \
--cc=agordeev@linux.ibm.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=gor@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=song@kernel.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