linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Zi Yan <ziy@nvidia.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Mel Gorman <mgorman@techsingularity.net>,
	David Hildenbrand <david@redhat.com>,
	Vlastimil Babka <vbabka@suse.cz>,
	Mike Rapoport <rppt@linux.ibm.com>,
	Oscar Salvador <osalvador@suse.de>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linux-MM <linux-mm@kvack.org>
Subject: Re: [BUG] Crash on x86_32 for: mm: page_alloc: avoid merging non-fallbackable pageblocks with others
Date: Wed, 30 Mar 2022 16:53:37 -0400	[thread overview]
Message-ID: <20220330165337.7138810e@gandalf.local.home> (raw)
In-Reply-To: <B7789993-75EC-4F74-B4E6-AF1CC2CBD9D4@nvidia.com>

On Wed, 30 Mar 2022 16:29:28 -0400
Zi Yan <ziy@nvidia.com> wrote:

> diff --git a/mm/page_alloc.c b/mm/page_alloc.c
> index bdc8f60ae462..83a90e2973b7 100644
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -1108,6 +1108,8 @@ static inline void __free_one_page(struct page *page,
> 
>                 buddy_pfn = __find_buddy_pfn(pfn, order);
>                 buddy = page + (buddy_pfn - pfn);
> +               if (!page_is_buddy(page, buddy, order))
> +                       goto done_merging;
>                 buddy_mt = get_pageblock_migratetype(buddy);
> 
>                 if (migratetype != buddy_mt
> 

The above did not apply to Linus's tree, nor even the problem commit
(before or after), but I found where the code is, and added it manually.

It does appear to allow the machine to boot.

-- Steve


  reply	other threads:[~2022-03-30 20:53 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-30 19:42 Steven Rostedt
2022-03-30 20:05 ` Linus Torvalds
2022-03-30 20:29   ` Zi Yan
2022-03-30 20:53     ` Steven Rostedt [this message]
2022-03-30 21:25       ` Zi Yan
2022-03-30 21:43         ` Zi Yan
2022-03-30 21:48           ` Vlastimil Babka
2022-03-30 21:57         ` Steven Rostedt
2022-03-30 20:57     ` Steven Rostedt
2022-03-30 21:43   ` Vlastimil Babka
2022-03-30 22:03     ` Zi Yan
2022-03-30 22:15       ` Vlastimil Babka
2022-03-30 22:24         ` Zi Yan

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=20220330165337.7138810e@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=akpm@linux-foundation.org \
    --cc=david@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mgorman@techsingularity.net \
    --cc=osalvador@suse.de \
    --cc=rppt@linux.ibm.com \
    --cc=torvalds@linux-foundation.org \
    --cc=vbabka@suse.cz \
    --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