From: Anthony Iliopoulos <ailiop@suse.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: Linux Memory Management List <linux-mm@kvack.org>,
"linux-block@vger.kernel.org" <linux-block@vger.kernel.org>,
Christoph Hellwig <hch@lst.de>,
akpm@linux-foundation.org
Subject: Re: [PATCH] swap: fix swapfile read/write offset
Date: Wed, 3 Mar 2021 16:46:45 +0100 [thread overview]
Message-ID: <YD+vZW2bJsmpCGn5@technoir> (raw)
In-Reply-To: <6f9da9c6-c6c5-08fe-95ea-940954456c40@kernel.dk>
On Tue, Mar 02, 2021 at 03:36:19PM -0700, Jens Axboe wrote:
> We're not factoring in the start of the file for where to write and
> read the swapfile, which leads to very unfortunate side effects of
> writing where we should not be...
>
> Fixes: 48d15436fde6 ("mm: remove get_swap_bio")
Presumably the usage of swap_page_sector was already affecting swap on
blockdevs that implement rw_page (currently brd, zram, btt, pmem), so it
may worth adding:
Fixes: dd6bd0d9c7db ("swap: use bdev_read_page() / bdev_write_page()")
Cc: <stable@vger.kernel.org> # v3.16+
for backporting, since it also affects stable.
next parent reply other threads:[~2021-03-03 15:46 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <6f9da9c6-c6c5-08fe-95ea-940954456c40@kernel.dk>
2021-03-03 15:46 ` Anthony Iliopoulos [this message]
2021-03-03 16:24 ` Jens Axboe
2021-03-04 3:19 ` Anthony Iliopoulos
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=YD+vZW2bJsmpCGn5@technoir \
--to=ailiop@suse.com \
--cc=akpm@linux-foundation.org \
--cc=axboe@kernel.dk \
--cc=hch@lst.de \
--cc=linux-block@vger.kernel.org \
--cc=linux-mm@kvack.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