From: Gao Xiang <hsiangkao@linux.alibaba.com>
To: Denis Arefev <arefev@swemel.ru>,
stable@vger.kernel.org,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Gao Xiang <xiang@kernel.org>, Chao Yu <chao@kernel.org>,
Yue Hu <huyue2@coolpad.com>,
Jeffle Xu <jefflexu@linux.alibaba.com>,
linux-erofs@lists.ozlabs.org, linux-kernel@vger.kernel.org,
lvc-project@linuxtesting.org
Subject: Re: [PATCH 6.1 0/1] erofs: Fix the slab-out-of-bounds in drop_buffers()
Date: Mon, 23 Mar 2026 15:55:19 +0800 [thread overview]
Message-ID: <a53e8e57-c54e-4fdd-8738-7e423e6ca37b@linux.alibaba.com> (raw)
In-Reply-To: <20260323074809.4542-1-arefev@swemel.ru>
Hi Denis,
On 2026/3/23 15:48, Denis Arefev wrote:
> Syzbot reported that a KASAN slab-out-of-bounds bug was discovered in the drop_buffers()
> function [1].
>
> The root cause is that erofs_raw_access_aops does not define .release_folio and
> .invalidate_folio. When using iomap-based operations, folio->private may contain
> iomap-specific data rather than buffer_heads. Without special handlers, the kernel
> may fall back to generic functions (e.g., drop_buffers), which incorrectly treat
> folio->private as a list of buffer_head structures, leading to incorrect memory
> interpretation and out-of-bounds access.
>
> This can be fixed by explicitly setting .release_folio and .invalidate_folio to
> iomap_release_folio and iomap_invalidate_folio, respectively, but there is a
> commit ce529cc25b184e93397b94a8a322128fc0095cbb in upstream that implicitly
> fixes this bug.
See my previous reply to the patch.
Thanks,
Gao Xiang
>
> Please commit it to the stable branch v6.1.y .
>
> [1] https://syzkaller.appspot.com/bug?id=c6aeabd0c4ad2466f63a274faf2a123103f8fbf7
>
> Jingbo Xu (1):
> erofs: enable large folios for iomap mode
>
> fs/erofs/data.c | 2 ++
> fs/erofs/inode.c | 2 ++
> 2 files changed, 4 insertions(+)
>
prev parent reply other threads:[~2026-03-23 7:55 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-23 7:48 [PATCH 6.1 0/1] erofs: Fix the slab-out-of-bounds in drop_buffers() Denis Arefev
2026-03-23 7:48 ` [PATCH 6.1 1/1] erofs: enable large folios for iomap mode Denis Arefev
2026-03-23 7:53 ` Gao Xiang
2026-03-23 7:55 ` Gao Xiang [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=a53e8e57-c54e-4fdd-8738-7e423e6ca37b@linux.alibaba.com \
--to=hsiangkao@linux.alibaba.com \
--cc=arefev@swemel.ru \
--cc=chao@kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=huyue2@coolpad.com \
--cc=jefflexu@linux.alibaba.com \
--cc=linux-erofs@lists.ozlabs.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lvc-project@linuxtesting.org \
--cc=stable@vger.kernel.org \
--cc=xiang@kernel.org \
/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