From: Mike Rapoport <rppt@kernel.org>
To: Haifeng Xu <haifeng.xu@shopee.com>
Cc: akpm@linux-foundation.org, linux-mm@kvack.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mm/mm_init.c: drop node_start_pfn from adjust_zone_range_for_zone_movable()
Date: Wed, 19 Jul 2023 07:32:18 +0300 [thread overview]
Message-ID: <20230719043218.GF1901145@kernel.org> (raw)
In-Reply-To: <20230717065811.1262-1-haifeng.xu@shopee.com>
On Mon, Jul 17, 2023 at 06:58:11AM +0000, Haifeng Xu wrote:
> node_start_pfn is not used in adjust_zone_range_for_zone_movable(), so
> it is pointless to waste a function argument. Drop the parameter.
>
> Signed-off-by: Haifeng Xu <haifeng.xu@shopee.com>
Reviewed-by: Mike Rapoport (IBM) <rppt@kernel.org>
> ---
> mm/mm_init.c | 6 ++----
> 1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/mm/mm_init.c b/mm/mm_init.c
> index a313d1828a6c..23d50541e1f7 100644
> --- a/mm/mm_init.c
> +++ b/mm/mm_init.c
> @@ -1105,7 +1105,6 @@ void __ref memmap_init_zone_device(struct zone *zone,
> */
> static void __init adjust_zone_range_for_zone_movable(int nid,
> unsigned long zone_type,
> - unsigned long node_start_pfn,
> unsigned long node_end_pfn,
> unsigned long *zone_start_pfn,
> unsigned long *zone_end_pfn)
> @@ -1222,9 +1221,8 @@ static unsigned long __init zone_spanned_pages_in_node(int nid,
> /* Get the start and end of the zone */
> *zone_start_pfn = clamp(node_start_pfn, zone_low, zone_high);
> *zone_end_pfn = clamp(node_end_pfn, zone_low, zone_high);
> - adjust_zone_range_for_zone_movable(nid, zone_type,
> - node_start_pfn, node_end_pfn,
> - zone_start_pfn, zone_end_pfn);
> + adjust_zone_range_for_zone_movable(nid, zone_type, node_end_pfn,
> + zone_start_pfn, zone_end_pfn);
>
> /* Check that this node has pages within the zone's required range */
> if (*zone_end_pfn < node_start_pfn || *zone_start_pfn > node_end_pfn)
> --
> 2.25.1
>
--
Sincerely yours,
Mike.
next prev parent reply other threads:[~2023-07-19 4:32 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-17 6:58 Haifeng Xu
2023-07-17 10:18 ` David Hildenbrand
2023-07-17 11:41 ` Mike Rapoport
2023-07-19 4:32 ` Mike Rapoport [this message]
2023-07-19 7:48 ` Anshuman Khandual
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=20230719043218.GF1901145@kernel.org \
--to=rppt@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=haifeng.xu@shopee.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
/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