From: Christoph Hellwig <hch@lst.de>
To: Christian Brauner <brauner@kernel.org>
Cc: Christoph Hellwig <hch@lst.de>,
Eric Biggers <ebiggers@kernel.org>,
Al Viro <viro@zeniv.linux.org.uk>, Jan Kara <jack@suse.cz>,
David Sterba <dsterba@suse.com>, Theodore Ts'o <tytso@mit.edu>,
Jaegeuk Kim <jaegeuk@kernel.org>, Chao Yu <chao@kernel.org>,
Andrey Albershteyn <aalbersh@redhat.com>,
linux-fsdevel@vger.kernel.org, linux-btrfs@vger.kernel.org,
linux-ext4@vger.kernel.org,
linux-f2fs-devel@lists.sourceforge.net, fsverity@lists.linux.dev
Subject: Re: [PATCH 3/6] fs,fsverity: handle fsverity in generic_file_open
Date: Mon, 19 Jan 2026 13:06:11 +0100 [thread overview]
Message-ID: <20260119120611.GA23787@lst.de> (raw)
In-Reply-To: <20260119-davon-krippenkind-78d683621491@brauner>
On Mon, Jan 19, 2026 at 11:02:37AM +0100, Christian Brauner wrote:
> > + if (IS_ENABLED(CONFIG_FS_VERITY) && IS_VERITY(inode)) {
> > + if (filp->f_mode & FMODE_WRITE)
> > + return -EPERM;
> > + return fsverity_file_open(inode, filp);
> > + }
>
> This is the only one where I'm not happy about the location.
> This hides the ordering requirement between fsverity and fscrypt. It's
> easier to miss now. This also really saves very little compared to the
> other changes. So I wonder whether it's really that big of a deal to
> have the call located in the open routines of the filesystems.
So my idea was to do a similar pass for fscrypt eventually, and enforce
the ordering in one place, instead of relying on file systems to get it
right. I'd be fine with delaying this patch until then and give it
another try. The good thing is that unlike say the stat hook fsverity
will simply not work without wiring this up, so it can't be easily
forgotten.
next prev parent reply other threads:[~2026-01-19 12:06 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-19 6:22 fsverity optimzations and speedups Christoph Hellwig
2026-01-19 6:22 ` [PATCH 1/6] fs,fsverity: reject size changes on fsverity files in setattr_prepare Christoph Hellwig
2026-01-19 6:22 ` [PATCH 2/6] fs,fsverity: clear out fsverity_info from common code Christoph Hellwig
2026-01-19 6:22 ` [PATCH 3/6] fs,fsverity: handle fsverity in generic_file_open Christoph Hellwig
2026-01-19 9:05 ` Jan Kara
2026-01-19 9:26 ` Christoph Hellwig
2026-01-19 10:02 ` Christian Brauner
2026-01-19 12:06 ` Christoph Hellwig [this message]
2026-01-19 6:22 ` [PATCH 4/6] fsverity: use a hashtable to find the fsverity_info Christoph Hellwig
2026-01-19 9:21 ` Jan Kara
2026-01-19 9:27 ` Christoph Hellwig
2026-01-19 19:05 ` Eric Biggers
2026-01-20 7:35 ` Christoph Hellwig
2026-01-19 6:22 ` [PATCH 5/6] fsverity: pass struct file to ->write_merkle_tree_block Christoph Hellwig
2026-01-19 6:22 ` [PATCH 6/6] fsverity: kick off hash readahead at data I/O submission time Christoph Hellwig
2026-01-19 9:37 ` fsverity optimzations and speedups Christian Brauner
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=20260119120611.GA23787@lst.de \
--to=hch@lst.de \
--cc=aalbersh@redhat.com \
--cc=brauner@kernel.org \
--cc=chao@kernel.org \
--cc=dsterba@suse.com \
--cc=ebiggers@kernel.org \
--cc=fsverity@lists.linux.dev \
--cc=jack@suse.cz \
--cc=jaegeuk@kernel.org \
--cc=linux-btrfs@vger.kernel.org \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-f2fs-devel@lists.sourceforge.net \
--cc=linux-fsdevel@vger.kernel.org \
--cc=tytso@mit.edu \
--cc=viro@zeniv.linux.org.uk \
/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