linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Mike Rapoport <rppt@kernel.org>
To: Anshuman Khandual <anshuman.khandual@arm.com>
Cc: linux-mm@kvack.org, mgorman@suse.de, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mm/page_alloc: Repalce with deferred_pages_enabled() wherever applicable
Date: Thu, 5 Jan 2023 11:43:45 +0200	[thread overview]
Message-ID: <Y7ab0VbU4gBLHqI7@kernel.org> (raw)
In-Reply-To: <20230105082506.241529-1-anshuman.khandual@arm.com>

On Thu, Jan 05, 2023 at 01:55:06PM +0530, Anshuman Khandual wrote:
> Instead of directly accessing static deferred_pages, replace such instances
> with the helper deferred_pages_enabled(). No functional change is intended.
> 
> Cc; Andrew Morton <akpm@linux-foundation.org>
> Cc: linux-mm@kvack.org
> Cc: linux-kernel@vger.kernel.org
> Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com>

Reviewed-by: Mike Rapoport (IBM) <rppt@kernel.org>

> ---
> This applies on v6.2-rc2.
> 
>  mm/page_alloc.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/mm/page_alloc.c b/mm/page_alloc.c
> index 0745aedebb37..232d0323047b 100644
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -4244,7 +4244,7 @@ get_page_from_freelist(gfp_t gfp_mask, unsigned int order, int alloc_flags,
>  			 * Watermark failed for this zone, but see if we can
>  			 * grow this zone if it contains deferred pages.
>  			 */
> -			if (static_branch_unlikely(&deferred_pages)) {
> +			if (deferred_pages_enabled()) {
>  				if (_deferred_grow_zone(zone, order))
>  					goto try_this_zone;
>  			}
> @@ -4293,7 +4293,7 @@ get_page_from_freelist(gfp_t gfp_mask, unsigned int order, int alloc_flags,
>  		} else {
>  #ifdef CONFIG_DEFERRED_STRUCT_PAGE_INIT
>  			/* Try again if zone has deferred pages */
> -			if (static_branch_unlikely(&deferred_pages)) {
> +			if (deferred_pages_enabled()) {
>  				if (_deferred_grow_zone(zone, order))
>  					goto try_this_zone;
>  			}
> -- 
> 2.25.1
> 

-- 
Sincerely yours,
Mike.


  reply	other threads:[~2023-01-05  9:43 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-05  8:25 Anshuman Khandual
2023-01-05  9:43 ` Mike Rapoport [this message]
2023-01-05 13:00 ` David Hildenbrand
2023-01-09 13:32 ` Mel Gorman

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=Y7ab0VbU4gBLHqI7@kernel.org \
    --to=rppt@kernel.org \
    --cc=anshuman.khandual@arm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mgorman@suse.de \
    /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