From: Claude Code Review Bot <claude-review@example.com>
To: dri-devel-reviews@example.com
Subject: Claude review: dma-buf: set SB_I_NOEXEC and SB_I_NODEV on the pseudo filesystem
Date: Mon, 25 May 2026 18:08:04 +1000 [thread overview]
Message-ID: <review-patch1-20260523011117.121390-1-jhubbard@nvidia.com> (raw)
In-Reply-To: <20260523011117.121390-1-jhubbard@nvidia.com>
Patch Review
**Correctness: Good.** The fix adds `SB_I_NOEXEC` and `SB_I_NODEV` to the superblock's internal flags in `dma_buf_fs_init_context()`. This directly addresses the `VFS_WARN_ON_ONCE` in `path_noexec()` at `fs/exec.c:118-119`:
```c
VFS_WARN_ON_ONCE(IS_ANON_FILE(d_inode(path->dentry)) &&
!(path->mnt->mnt_sb->s_iflags & SB_I_NOEXEC));
```
**Placement is correct.** The flags are set on `fc->s_iflags` after the `init_pseudo()` call, which is the same pattern used by `kvm/guest_memfd.c:976-977`:
```c
fc->s_iflags |= SB_I_NOEXEC;
fc->s_iflags |= SB_I_NODEV;
```
**Semantics are correct.** dma-bufs should never be executable (they're GPU memory buffers), and the pseudo filesystem creates no device nodes, so both flags are appropriate.
**Minor style nit (non-blocking):** Some callers (e.g., `ipc/mqueue.c:408`) combine both flags in a single statement: `sb->s_iflags |= SB_I_NOEXEC | SB_I_NODEV;`. Using two separate lines is also fine and arguably more readable — the KVM code follows the same two-line pattern, so this is consistent. No change needed.
**Fixes tag and Cc stable are appropriate.** This is a regression introduced by `1e7ab6f67824` in 6.17, and the fix is trivially backportable.
**Reviewed-by from Christian Brauner** (the VFS maintainer who authored the assertion) is already present, which provides strong confidence in the approach.
No issues found. This patch is ready to merge.
---
Generated by Claude Code Patch Reviewer
prev parent reply other threads:[~2026-05-25 8:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-23 1:11 [PATCH v2] dma-buf: set SB_I_NOEXEC and SB_I_NODEV on the pseudo filesystem John Hubbard
2026-05-25 8:08 ` Claude review: " Claude Code Review Bot
2026-05-25 8:08 ` Claude Code Review Bot [this message]
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=review-patch1-20260523011117.121390-1-jhubbard@nvidia.com \
--to=claude-review@example.com \
--cc=dri-devel-reviews@example.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