From: Andrew Morton <akpm@linux-foundation.org>
To: Yang Shi <shy828301@gmail.com>
Cc: Miaohe Lin <linmiaohe@huawei.com>,
nao.horiguchi@gmail.com, xuyu@linux.alibaba.com,
linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH -rc7] mm/huge_memory: mark huge_zero_page reserved
Date: Tue, 14 May 2024 14:42:04 -0700 [thread overview]
Message-ID: <20240514144204.88790f125b0275ef68acf6de@linux-foundation.org> (raw)
In-Reply-To: <CAHbLzkq+NBjwjSvU1fQe56nLf5mmGp65TH8hDpb66EFLENctKA@mail.gmail.com>
On Tue, 14 May 2024 15:28:12 -0600 Yang Shi <shy828301@gmail.com> wrote:
> On Tue, May 14, 2024 at 3:14 PM Andrew Morton <akpm@linux-foundation.org> wrote:
> >
> > On Sat, 11 May 2024 11:54:35 +0800 Miaohe Lin <linmiaohe@huawei.com> wrote:
> >
> > > When I did memory failure tests recently, below panic occurs:
> > >
> > > kernel BUG at include/linux/mm.h:1135!
> > > invalid opcode: 0000 [#1] PREEMPT SMP NOPTI
> > > CPU: 9 PID: 137 Comm: kswapd1 Not tainted 6.9.0-rc4-00491-gd5ce28f156fe-dirty #14
> > >
> > > ...
> > >
> > > --- a/mm/huge_memory.c
> > > +++ b/mm/huge_memory.c
> > > @@ -208,6 +208,7 @@ static bool get_huge_zero_page(void)
> > > __free_pages(zero_page, compound_order(zero_page));
> > > goto retry;
> > > }
> > > + __SetPageReserved(zero_page);
> > > WRITE_ONCE(huge_zero_pfn, page_to_pfn(zero_page));
> > >
> > > /* We take additional reference here. It will be put back by shrinker */
> > > @@ -260,6 +261,7 @@ static unsigned long shrink_huge_zero_page_scan(struct shrinker *shrink,
> > > struct page *zero_page = xchg(&huge_zero_page, NULL);
> > > BUG_ON(zero_page == NULL);
> > > WRITE_ONCE(huge_zero_pfn, ~0UL);
> > > + __ClearPageReserved(zero_page);
> > > __free_pages(zero_page, compound_order(zero_page));
> > > return HPAGE_PMD_NR;
> > > }
> >
> > This causes a bit of a mess when staged ahead of mm-stable. So to
> > avoid disruption I staged it behind mm-stable. This means that when
> > the -stable maintainers try to merge it, they will ask for a fixed up
> > version for older kernels so you can please just send them this
> > version.
>
> Can you please drop this from mm-unstable since both I and David
> nack'ed a similar patch in another thread.
> https://lore.kernel.org/linux-mm/20240511032801.1295023-1-linmiaohe@huawei.com/
That appears to link to the incorrect email thread?
next prev parent reply other threads:[~2024-05-14 21:42 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-11 3:54 Miaohe Lin
2024-05-14 21:14 ` Andrew Morton
2024-05-14 21:28 ` Yang Shi
2024-05-14 21:42 ` Andrew Morton [this message]
2024-05-14 21:55 ` Yang Shi
2024-05-15 1:48 ` Miaohe Lin
2024-05-17 7:03 ` kernel test robot
2024-05-20 1:47 ` Miaohe Lin
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=20240514144204.88790f125b0275ef68acf6de@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=linmiaohe@huawei.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=nao.horiguchi@gmail.com \
--cc=shy828301@gmail.com \
--cc=xuyu@linux.alibaba.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