From: Brendan Jackman <jackmanb@google.com>
To: Vlastimil Babka <vbabka@suse.cz>
Cc: Johannes Weiner <hannes@cmpxchg.org>,
Andrew Morton <akpm@linux-foundation.org>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3] mm: page_alloc: don't steal single pages from biggest buddy
Date: Tue, 25 Feb 2025 14:40:57 +0000 [thread overview]
Message-ID: <Z73WeTfMrtEmct_6@google.com> (raw)
In-Reply-To: <f44b7e1a-02d1-4cda-8b0e-e748f96e92bd@suse.cz>
On Tue, Feb 25, 2025 at 03:35:25PM +0100, Vlastimil Babka wrote:
> >> - return NULL;
> >> + if (alloc_flags & ALLOC_NOFRAGMENT)
> >> + return NULL;
> >
> > Is this a separate change? Is it a bug that we currently allow
> > stealing a from a fallback type when ALLOC_NOFRAGMENT? (I wonder if
> > the second loop was supposed to start from min_order).
>
> It's subtle but not a new condition. Previously ALLOC_NOFRAGMENT would
> result in not taking the "goto find_smallest" path because it means
> searching >=pageblock_order only and that would always be can_steal == true
> if it found a fallback. And failure to find fallback would reach an
> unconditional return NULL here. Now we fall through the search below
> (instead of the goto), but ALLOC_NOFRAGMENT must not do it so it's now
> explicit here.
Ahhhh yes, thank you for the help. The new explicit code is much
better.
Reviewed-by: Brendan Jackman <jackmanb@google.com>
next prev parent reply other threads:[~2025-02-25 14:41 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-25 0:08 [PATCH 0/3] mm: page_alloc: freelist hygiene follow-up Johannes Weiner
2025-02-25 0:08 ` [PATCH 1/3] mm: page_alloc: don't steal single pages from biggest buddy Johannes Weiner
2025-02-25 10:50 ` Vlastimil Babka
2025-02-25 13:34 ` Brendan Jackman
2025-02-25 14:35 ` Vlastimil Babka
2025-02-25 14:40 ` Brendan Jackman [this message]
2025-02-25 15:04 ` Johannes Weiner
2025-02-25 0:08 ` [PATCH 2/3] mm: page_alloc: remove remnants of unlocked migratetype updates Johannes Weiner
2025-02-25 11:01 ` Vlastimil Babka
2025-02-25 13:43 ` Brendan Jackman
2025-02-25 15:09 ` Johannes Weiner
2025-02-25 15:19 ` Brendan Jackman
2025-02-25 0:08 ` [PATCH 3/3] mm: page_alloc: group fallback functions together Johannes Weiner
2025-02-25 11:02 ` Vlastimil Babka
2025-02-26 8:51 ` Vlastimil Babka
2025-02-25 13:50 ` Brendan Jackman
2025-02-25 15:14 ` Johannes Weiner
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=Z73WeTfMrtEmct_6@google.com \
--to=jackmanb@google.com \
--cc=akpm@linux-foundation.org \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=vbabka@suse.cz \
/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.