From: Pavel Begunkov <asml.silence@gmail.com>
To: Sechang Lim <rhkrqnwk98@gmail.com>, axboe@kernel.dk
Cc: io-uring@vger.kernel.org, bpf@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] io_uring/bpf-ops: validate loop_step before registration
Date: Thu, 26 Nov 2026 13:28:47 +0000 [thread overview]
Message-ID: <11a00d5a-18cc-484c-9861-37fc116f6dbf@gmail.com> (raw)
In-Reply-To: <20261119115942.3613868-1-rhkrqnwk98@gmail.com>
On 11/19/26 11:59, Sechang Lim wrote:
> A struct_ops map with only ring_fd set leaves loop_step NULL. The
> struct_ops update path skips a zero program fd, and bpf_ring_ops does
> not validate the completed value. Without BPF_F_LINK, the update then
> calls bpf_io_reg(), where io_install_bpf() triggers a kernel warning
> before returning -EINVAL. With BPF_F_LINK, the warning occurs when the
> link is created.
>
> Validate loop_step before either registration path. Reject an incomplete
> value with -EINVAL so malformed userspace input cannot trigger the
> warning.
Looks good, thanks for the patch.
Reviewed-by: Pavel Begunkov <asml.silence@gmail.com>
--
Pavel Begunkov
next prev parent reply other threads:[~2026-11-26 13:28 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-19 11:59 Sechang Lim
2026-11-26 13:28 ` Pavel Begunkov [this message]
2026-11-26 16:18 ` Jens Axboe
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=11a00d5a-18cc-484c-9861-37fc116f6dbf@gmail.com \
--to=asml.silence@gmail.com \
--cc=axboe@kernel.dk \
--cc=bpf@vger.kernel.org \
--cc=io-uring@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rhkrqnwk98@gmail.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
all inboxes | Powered by JetHome®