Linux MM tree latest commits
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: mm-commits@vger.kernel.org, richard.weiyang@gmail.com,
	osalvador@suse.de, mhocko@kernel.org, linmiaohe@huawei.com,
	david@redhat.com, yuehaibing@huawei.com,
	akpm@linux-foundation.org
Subject: + mm-memory_hotplug-reset-nodes-state-when-empty-during-offline-fix.patch added to -mm tree
Date: Wed, 13 Apr 2022 19:35:12 -0700	[thread overview]
Message-ID: <20220414023513.845DDC385A3@smtp.kernel.org> (raw)


The patch titled
     Subject: mm/memory_hotplug: fix build warning without CONFIG_MEMORY_HOTREMOVE
has been added to the -mm tree.  Its filename is
     mm-memory_hotplug-reset-nodes-state-when-empty-during-offline-fix.patch

This patch should soon appear at
    https://ozlabs.org/~akpm/mmots/broken-out/mm-memory_hotplug-reset-nodes-state-when-empty-during-offline-fix.patch
and later at
    https://ozlabs.org/~akpm/mmotm/broken-out/mm-memory_hotplug-reset-nodes-state-when-empty-during-offline-fix.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: YueHaibing <yuehaibing@huawei.com>
Subject: mm/memory_hotplug: fix build warning without CONFIG_MEMORY_HOTREMOVE

mm/memory_hotplug.c:1148:13: warning: `reset_node_present_pages' defined but not used [-Wunused-function]
 1148 | static void reset_node_present_pages(pg_data_t *pgdat)
      |             ^~~~~~~~~~~~~~~~~~~~~~~~

reset_node_present_pages() now only used in node_reset_state(),move it
inside the ifdef block to fix this warning.

Link: https://lkml.kernel.org/r/20220408022402.29668-1-yuehaibing@huawei.com
Fixes: 0d540af7befe ("mm/memory_hotplug: reset node's state when empty during offline")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Cc: Oscar Salvador <osalvador@suse.de>
Cc: David Hildenbrand <david@redhat.com>
Cc: Miaohe Lin <linmiaohe@huawei.com>
Cc: Michal Hocko <mhocko@kernel.org>
Cc: Wei Yang <richard.weiyang@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---


--- a/mm/memory_hotplug.c~mm-memory_hotplug-reset-nodes-state-when-empty-during-offline-fix
+++ a/mm/memory_hotplug.c
@@ -1145,16 +1145,6 @@ failed_addition:
 	return ret;
 }
 
-static void reset_node_present_pages(pg_data_t *pgdat)
-{
-	struct zone *z;
-
-	for (z = pgdat->node_zones; z < pgdat->node_zones + MAX_NR_ZONES; z++)
-		z->present_pages = 0;
-
-	pgdat->node_present_pages = 0;
-}
-
 /* we are OK calling __meminit stuff here - we have CONFIG_MEMORY_HOTPLUG */
 static pg_data_t __ref *hotadd_init_pgdat(int nid)
 {
@@ -1755,6 +1745,16 @@ static void node_states_clear_node(int n
 		node_clear_state(node, N_MEMORY);
 }
 
+static void reset_node_present_pages(pg_data_t *pgdat)
+{
+	struct zone *z;
+
+	for (z = pgdat->node_zones; z < pgdat->node_zones + MAX_NR_ZONES; z++)
+		z->present_pages = 0;
+
+	pgdat->node_present_pages = 0;
+}
+
 static void node_reset_state(int node)
 {
 	pg_data_t *pgdat = NODE_DATA(node);
_

Patches currently in -mm which might be from yuehaibing@huawei.com are

mm-memory_hotplug-reset-nodes-state-when-empty-during-offline-fix.patch


                 reply	other threads:[~2022-04-14  2:35 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20220414023513.845DDC385A3@smtp.kernel.org \
    --to=akpm@linux-foundation.org \
    --cc=david@redhat.com \
    --cc=linmiaohe@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mhocko@kernel.org \
    --cc=mm-commits@vger.kernel.org \
    --cc=osalvador@suse.de \
    --cc=richard.weiyang@gmail.com \
    --cc=yuehaibing@huawei.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