From: Sergey Senozhatsky <senozhatsky@chromium.org>
To: Christoph Hellwig <hch@lst.de>
Cc: minchan@kernel.org, senozhatsky@chromium.org,
linux-block@vger.kernel.org, linux-kernel@vger.kernel.org,
Dusty Mabe <dusty@dustymabe.com>
Subject: Re: [PATCH] zram: take device and not only bvec offset into account
Date: Sat, 5 Aug 2023 16:46:45 +0900 [thread overview]
Message-ID: <20230805074645.GA907732@google.com> (raw)
In-Reply-To: <20230805055537.147835-1-hch@lst.de>
On (23/08/05 07:55), Christoph Hellwig wrote:
> Commit af8b04c63708 ("zram: simplify bvec iteration in
> __zram_make_request") changed the bio iteration in zram to rely on the
> implicit capping to page boundaries in bio_for_each_segment. But it
> failed to care for the fact zram not only care about the page alignment
> of the bio payload, but also the page alignment into the device. For
> buffered I/O and swap those are the same, but for direct I/O or kernel
> internal I/O like XFS log buffer writes they can differ.
>
> Fix this by open coding bio_for_each_segment and limiting the bvec len
> so that it never crosses over a page alignment boundary in the device
> in addition to the payload boundary already taken care of by
> bio_iter_iovec.
>
> Fixes: af8b04c63708 ("zram: simplify bvec iteration in __zram_make_request")
> Reported-by: Dusty Mabe <dusty@dustymabe.com>
> Signed-off-by: Christoph Hellwig <hch@lst.de>
Acked-by: Sergey Senozhatsky <senozhatsky@chromium.org>
next prev parent reply other threads:[~2023-08-05 7:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-05 5:55 [PATCH] zram: take device and not only bvec offset into account Christoph Hellwig
2023-08-05 7:46 ` Sergey Senozhatsky [this message]
2023-08-05 8:13 ` Christoph Hellwig
2023-08-05 21:47 ` Dusty Mabe
2023-08-06 7:16 ` Sergey Senozhatsky
2023-08-05 22:13 ` Jens Axboe
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=20230805074645.GA907732@google.com \
--to=senozhatsky@chromium.org \
--cc=dusty@dustymabe.com \
--cc=hch@lst.de \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=minchan@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.