From: Greg KH <gregkh@linuxfoundation.org>
To: Charan Teja Kalla <quic_charante@quicinc.com>
Cc: Zi Yan <ziy@nvidia.com>, David Hildenbrand <david@redhat.com>,
Matthew Wilcox <willy@infradead.org>,
akpm@linux-foundation.org, vbabka@suse.cz, dhowells@redhat.com,
surenb@google.com, linux-mm@kvack.org,
linux-kernel@vger.kernel.org,
# see patch description <stable@vger.kernel.org>,
Huang Ying <ying.huang@intel.com>,
Naoya Horiguchi <naoya.horiguchi@linux.dev>
Subject: Re: [PATCH] mm/huge_memory: fix swap entry values of tail pages of THP
Date: Mon, 4 Mar 2024 11:48:55 +0100 [thread overview]
Message-ID: <2024030444-unfreeze-crystal-1ccf@gregkh> (raw)
In-Reply-To: <acdf3d44-b20e-8491-6302-bfb1b354bc62@quicinc.com>
On Wed, Feb 28, 2024 at 09:06:19PM +0530, Charan Teja Kalla wrote:
> Thanks David/Zi Yan,
>
> On 2/27/2024 9:45 PM, Zi Yan wrote:
> > So likely we'd have to fix the stable kernels:
> >
> > 4.19
> > 5.4
> > 5.10
> > 5.15
> > 6.1
> >
> > That's a lot of pre-folio code. A backport of my series likely won't really make any sense.
>
> So, I assume this is a consensus to have stable-only fix for this issue.
>
> >
> > For v6.1, the fix would like below?
> >
> > diff --git a/mm/migrate.c b/mm/migrate.c
> > index c93dd6a31c31..c5968021fde0 100644
> > --- a/mm/migrate.c
> > +++ b/mm/migrate.c
> > @@ -423,8 +423,12 @@ int folio_migrate_mapping(struct address_space *mapping,
> > if (folio_test_swapbacked(folio)) {
> > __folio_set_swapbacked(newfolio);
> > if (folio_test_swapcache(folio)) {
> > + int i;
> > +
> > folio_set_swapcache(newfolio);
> > - newfolio->private = folio_get_private(folio);
> > + for (i = 0; i < nr; i++)
> > + set_page_private(folio_page(newfolio, i),
> > + page_private(folio_page(folio, i)));
> > }
> > entries = nr;
> > } else {
>
> Similar to this is what we had tested[1] internally and observed no issues.
>
> Can this be taken to 6.1, please?
Someone needs to submit it properly and get it reviewed by the relevent
maintainers.
thanks,
greg k-h
next prev parent reply other threads:[~2024-03-04 10:49 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-13 8:48 Charan Teja Kalla
2024-02-13 8:54 ` Matthew Wilcox
2024-02-13 9:10 ` Charan Teja Kalla
2024-02-13 9:25 ` David Hildenbrand
2024-02-13 16:27 ` Charan Teja Kalla
2024-02-13 18:36 ` David Hildenbrand
2024-02-14 6:34 ` Charan Teja Kalla
2024-02-14 14:18 ` Matthew Wilcox
2024-02-14 14:34 ` David Hildenbrand
2024-02-27 14:11 ` David Hildenbrand
2024-02-27 14:52 ` Zi Yan
2024-02-27 15:01 ` David Hildenbrand
2024-02-27 15:20 ` Zi Yan
2024-02-27 16:15 ` Zi Yan
2024-02-28 15:36 ` Charan Teja Kalla
2024-03-04 10:48 ` Greg KH [this message]
2024-02-13 9:41 ` Greg KH
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=2024030444-unfreeze-crystal-1ccf@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=akpm@linux-foundation.org \
--cc=david@redhat.com \
--cc=dhowells@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=naoya.horiguchi@linux.dev \
--cc=quic_charante@quicinc.com \
--cc=stable@vger.kernel.org \
--cc=surenb@google.com \
--cc=vbabka@suse.cz \
--cc=willy@infradead.org \
--cc=ying.huang@intel.com \
--cc=ziy@nvidia.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