All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Nuoqi Gui" <gnq25@mails.tsinghua.edu.cn>
Cc: bpf@vger.kernel.org
Subject: Re: [PATCH bpf 2/2] selftests/bpf: Cover dynptr probe-read kfunc capability gate
Date: Mon, 15 Jun 2026 08:41:55 +0000	[thread overview]
Message-ID: <20260615084155.8ECDA1F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260615-f01-07-dynptr-probe-read-cap-v1-2-e626cd61a381@mails.tsinghua.edu.cn>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] The commit message claims to declare explicit kfunc prototypes locally in `dynptr_success.c`, but the patch fails to include these declarations.
--

commit d3deda1bfd50e0af66e0dced005423edd99c0d03
Author: Nuoqi Gui <gnq25@mails.tsinghua.edu.cn>

selftests/bpf: Cover dynptr probe-read kfunc capability gate

This commit adds selftest programs to verify that the nofault probe-read
dynptr kfuncs fail with -EACCES when called without CAP_PERFMON and
CAP_SYS_ADMIN. It tests the policy boundary for these kfuncs using
capabilities.

> Add focused dynptr selftest programs that load socket-filter programs using
> bpf_dynptr_from_mem() followed by each nofault probe-read dynptr kfunc:
> bpf_probe_read_user_dynptr(), bpf_probe_read_kernel_dynptr(),
> bpf_probe_read_user_str_dynptr(), and bpf_probe_read_kernel_str_dynptr().
> Declare the dynptr kfuncs used by this BPF object locally in
> dynptr_success.c so the dynptr BPF object builds with explicit prototypes.

[Severity: Medium]
Is this description accurate for the included changes?

The commit message mentions adding explicit local declarations for the dynptr
kfuncs in dynptr_success.c, but these declarations do not appear to be
included in the code. Were they accidentally omitted from this patch, or
is the commit message outdated?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260615-f01-07-dynptr-probe-read-cap-v1-0-e626cd61a381@mails.tsinghua.edu.cn?part=2

  reply	other threads:[~2026-06-15  8:41 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-15  8:31 [PATCH bpf 0/2] bpf: Gate dynptr probe-read kfuncs like helpers Nuoqi Gui
2026-06-15  8:31 ` [PATCH bpf 1/2] " Nuoqi Gui
2026-06-15  8:55   ` sashiko-bot
2026-06-15  8:31 ` [PATCH bpf 2/2] selftests/bpf: Cover dynptr probe-read kfunc capability gate Nuoqi Gui
2026-06-15  8:41   ` sashiko-bot [this message]
2026-06-15  9:36     ` Nuoqi Gui
2026-06-15 15:48 ` [PATCH bpf 0/2] bpf: Gate dynptr probe-read kfuncs like helpers Alexei Starovoitov

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=20260615084155.8ECDA1F000E9@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=gnq25@mails.tsinghua.edu.cn \
    --cc=sashiko-reviews@lists.linux.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.