mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Miklos Szeredi <miklos@szeredi.hu>
To: Haofeng Li <lihaofeng@kylinos.cn>
Cc: joannelkoong@gmail.com, fuse-devel@lists.linux.dev,
	 linux-kernel@vger.kernel.org, djwong@kernel.org,
	brauner@kernel.org
Subject: Re: [PATCH v2] fuse: honor desc offset in readahead reads
Date: Fri, 17 Jul 2026 10:56:20 +0200	[thread overview]
Message-ID: <CAJfpegv=akLW1qzq=B=F11Qfx5Gg8qoRiV4Z-pty-0Og+sU4GQ@mail.gmail.com> (raw)
In-Reply-To: <20260717032835.922433-1-lihaofeng@kylinos.cn>

On Fri, 17 Jul 2026 at 05:28, Haofeng Li <lihaofeng@kylinos.cn> wrote:
>
> fuse_handle_readahead records non-zero descs[].offset when
> iomap skips leading uptodate blocks in a folio, but
> fuse_send_readpages built FUSE_READ from folio_pos() alone.
> The reply was still copied at descs[0].offset, so wrong
> file data was placed into the page cache.
>
> Add descs[0].offset to the request position. Apply the
> same correction in fuse_short_read for EOF size updates.
>
> Fixes: 4ea907108a5c ("fuse: use iomap for readahead")
> Signed-off-by: Haofeng Li <lihaofeng@kylinos.cn>
> Reviewed-by: Joanne Koong <joannelkoong@gmail.com>

Sashiko founds some more cases:
https://sashiko.dev/#/patchset/20260717032835.922433-1-lihaofeng%40kylinos.cn

This is a large folio issue, right?  I do wonder why fsx-linux missed
these with the large folios enabled.

Thanks,
Miklos

  reply	other threads:[~2026-07-17  8:56 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-16  9:40 [PATCH] " Haofeng Li
2026-07-16 18:11 ` Joanne Koong
2026-07-17  3:03   ` Haofeng Li
2026-07-17  3:28   ` [PATCH v2] " Haofeng Li
2026-07-17  8:56     ` Miklos Szeredi [this message]
2026-07-17 10:17       ` Horst Birthelmer
2026-07-17 20:33         ` Joanne Koong
2026-07-17 18:37       ` Haofeng Li

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='CAJfpegv=akLW1qzq=B=F11Qfx5Gg8qoRiV4Z-pty-0Og+sU4GQ@mail.gmail.com' \
    --to=miklos@szeredi.hu \
    --cc=brauner@kernel.org \
    --cc=djwong@kernel.org \
    --cc=fuse-devel@lists.linux.dev \
    --cc=joannelkoong@gmail.com \
    --cc=lihaofeng@kylinos.cn \
    --cc=linux-kernel@vger.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