Linux EXT4 FS development
 help / color / mirror / Atom feed
From: Eric Biggers <ebiggers@kernel.org>
To: Baokun Li <libaokun@linux.alibaba.com>
Cc: Alberto Garcia <berto@igalia.com>, Theodore Ts'o <tytso@mit.edu>,
	Andreas Dilger <adilger.kernel@dilger.ca>,
	Jan Kara <jack@suse.cz>, Ojaswin Mujoo <ojaswin@linux.ibm.com>,
	"Ritesh Harjani (IBM)" <ritesh.list@gmail.com>,
	Zhang Yi <yi.zhang@huawei.com>,
	linux-ext4@vger.kernel.org
Subject: Re: [REGRESSION] ext4: oops in ext4_finish_bio() after enabling encryption on a mounted fs
Date: Wed, 23 Sep 2026 18:01:19 +0000	[thread overview]
Message-ID: <20260923180119.GA1506901@google.com> (raw)
In-Reply-To: <cbbfa461-c770-457d-bfc6-317d744f1dcd@linux.alibaba.com>

On Wed, Sep 23, 2026 at 09:28:54PM +0800, Baokun Li wrote:
> On 2026/9/23 20:40, Alberto Garcia wrote:
> > On Wed, Sep 23, 2026 at 08:12:03PM +0800, Baokun Li wrote:
> >>> 1) Enable encryption on an ext4 filesystem with tune2fs -O encrypt
> >> Is it valid to enable encrypt at mount time?
> > Good question, I always understood that it was allowed and tune2fs
> > certainly doesn't forbid it (compare with casefold):
> >
> > https://github.com/tytso/e2fsprogs/blob/v1.47.4/misc/tune2fs.c#L1599
> >
> > Berto
> 
> 
> If enabling encryption on a mounted ext4 fs is allowed,
> I think the current change is fine.
> 
> Ted, Eric - would either of you know the details here?

Yes, it is allowed.

The proposed patch looks good, even though the problem seems to be gone
on mainline already due to the removal of the code path that used the
non-large-folio-compatible function fscrypt_encrypt_pagecache_blocks().

There can be another patch that removes both that check and the
mount-time check, if they're truly no longer needed (I don't know of any
reason why they would be, but it needs to be properly tested).

- Eric

  reply	other threads:[~2026-09-23 18:01 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-23 11:12 [REGRESSION] ext4: oops in ext4_finish_bio() after enabling encryption on a mounted fs Alberto Garcia
2026-09-23 11:43 ` sashiko-bot
2026-09-23 12:12 ` Baokun Li
2026-09-23 12:40   ` Alberto Garcia
2026-09-23 13:28     ` Baokun Li
2026-09-23 18:01       ` Eric Biggers [this message]
2026-09-24 10:19         ` Baokun Li
2026-09-24 15:15         ` Alberto Garcia
2026-09-24 18:04           ` Eric Biggers
2026-09-25 11:06             ` Alberto Garcia
2026-09-25 19:07               ` Eric Biggers
2026-09-27 22:12                 ` Alberto Garcia
2026-09-29 11:18                   ` Jan Kara
2026-09-23 13:29 ` Jan Kara
2026-09-23 13:39   ` Alberto Garcia

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=20260923180119.GA1506901@google.com \
    --to=ebiggers@kernel.org \
    --cc=adilger.kernel@dilger.ca \
    --cc=berto@igalia.com \
    --cc=jack@suse.cz \
    --cc=libaokun@linux.alibaba.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=ojaswin@linux.ibm.com \
    --cc=ritesh.list@gmail.com \
    --cc=tytso@mit.edu \
    --cc=yi.zhang@huawei.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