linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] powerpc/mm: Update max/min_low_pfn in the same function
@ 2022-07-04  6:38 Aneesh Kumar K.V
  2022-10-04 13:26 ` Michael Ellerman
  0 siblings, 1 reply; 2+ messages in thread
From: Aneesh Kumar K.V @ 2022-07-04  6:38 UTC (permalink / raw)
  To: linuxppc-dev, mpe; +Cc: Aneesh Kumar K.V

For both CONFIG_NUMA enabled/disabled use mem_topology_setup to
update max/min_low_pfn.

This also add min_low_pfn update to CONFIG_NUMA which was initialized
to zero before.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
---
 arch/powerpc/mm/numa.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c
index 0801b2ce9b7d..b44ce71917d7 100644
--- a/arch/powerpc/mm/numa.c
+++ b/arch/powerpc/mm/numa.c
@@ -1160,6 +1160,9 @@ void __init mem_topology_setup(void)
 {
 	int cpu;
 
+	max_low_pfn = max_pfn = memblock_end_of_DRAM() >> PAGE_SHIFT;
+	min_low_pfn = MEMORY_START >> PAGE_SHIFT;
+
 	/*
 	 * Linux/mm assumes node 0 to be online at boot. However this is not
 	 * true on PowerPC, where node 0 is similar to any other node, it
@@ -1204,9 +1207,6 @@ void __init initmem_init(void)
 {
 	int nid;
 
-	max_low_pfn = memblock_end_of_DRAM() >> PAGE_SHIFT;
-	max_pfn = max_low_pfn;
-
 	memblock_dump_all();
 
 	for_each_online_node(nid) {
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v2] powerpc/mm: Update max/min_low_pfn in the same function
  2022-07-04  6:38 [PATCH v2] powerpc/mm: Update max/min_low_pfn in the same function Aneesh Kumar K.V
@ 2022-10-04 13:26 ` Michael Ellerman
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Ellerman @ 2022-10-04 13:26 UTC (permalink / raw)
  To: Aneesh Kumar K.V, mpe, linuxppc-dev

On Mon, 4 Jul 2022 12:08:51 +0530, Aneesh Kumar K.V wrote:
> For both CONFIG_NUMA enabled/disabled use mem_topology_setup to
> update max/min_low_pfn.
> 
> This also add min_low_pfn update to CONFIG_NUMA which was initialized
> to zero before.
> 
> 
> [...]

Applied to powerpc/next.

[1/1] powerpc/mm: Update max/min_low_pfn in the same function
      https://git.kernel.org/powerpc/c/7b31f7dadd7074fa70bb14a53bd286ffdfc98b04

cheers

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-10-04 13:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-04  6:38 [PATCH v2] powerpc/mm: Update max/min_low_pfn in the same function Aneesh Kumar K.V
2022-10-04 13:26 ` Michael Ellerman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).