From: Anshuman Khandual <anshuman.khandual@arm.com> To: linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, akpm@linux-foundation.org, catalin.marinas@arm.com, will@kernel.org Cc: mark.rutland@arm.com, david@redhat.com, cai@lca.pw, logang@deltatee.com, cpandya@codeaurora.org, arunks@codeaurora.org, dan.j.williams@intel.com, mgorman@techsingularity.net, osalvador@suse.de, ard.biesheuvel@arm.com, steve.capper@arm.com, broonie@kernel.org, valentin.schneider@arm.com, Robin.Murphy@arm.com, steven.price@arm.com, suzuki.poulose@arm.com, ira.weiny@intel.com, Anshuman Khandual <anshuman.khandual@arm.com>, Rob Herring <robh+dt@kernel.org>, Frank Rowand <frowand.list@gmail.com>, devicetree@vger.kernel.org Subject: [PATCH V11 3/5] of/fdt: Mark boot memory with MEMBLOCK_BOOT Date: Fri, 10 Jan 2020 08:39:13 +0530 [thread overview] Message-ID: <1578625755-11792-4-git-send-email-anshuman.khandual@arm.com> (raw) In-Reply-To: <1578625755-11792-1-git-send-email-anshuman.khandual@arm.com> early_init_dt_add_memory_arch() adds memory into memblock on both UEFI and DT based arm64 systems. Lets mark these as boot memory right after they get into memblock. All other platforms using this default implementation for early_init_dt_add_memory_arch() will also have this memblock flag set on boot memory ranges but will be upto the platforms if they would like to use it or not. On arm64 platform this flag will be used to identify boot memory at runtime and reject any attempt to remove them. Cc: Rob Herring <robh+dt@kernel.org> Cc: Frank Rowand <frowand.list@gmail.com> Cc: devicetree@vger.kernel.org Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com> --- drivers/of/fdt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c index 2cdf64d..a2ae2c88 100644 --- a/drivers/of/fdt.c +++ b/drivers/of/fdt.c @@ -1143,6 +1143,7 @@ void __init __weak early_init_dt_add_memory_arch(u64 base, u64 size) base = phys_offset; } memblock_add(base, size); + memblock_mark_boot(base, size); } int __init __weak early_init_dt_mark_hotplug_memory_arch(u64 base, u64 size) -- 2.7.4
WARNING: multiple messages have this Message-ID (diff)
From: Anshuman Khandual <anshuman.khandual@arm.com> To: linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, akpm@linux-foundation.org, catalin.marinas@arm.com, will@kernel.org Cc: mark.rutland@arm.com, devicetree@vger.kernel.org, Frank Rowand <frowand.list@gmail.com>, ira.weiny@intel.com, david@redhat.com, mgorman@techsingularity.net, steve.capper@arm.com, Robin.Murphy@arm.com, Rob Herring <robh+dt@kernel.org>, steven.price@arm.com, broonie@kernel.org, cai@lca.pw, ard.biesheuvel@arm.com, cpandya@codeaurora.org, arunks@codeaurora.org, dan.j.williams@intel.com, Anshuman Khandual <anshuman.khandual@arm.com>, logang@deltatee.com, valentin.schneider@arm.com, suzuki.poulose@arm.com, osalvador@suse.de Subject: [PATCH V11 3/5] of/fdt: Mark boot memory with MEMBLOCK_BOOT Date: Fri, 10 Jan 2020 08:39:13 +0530 [thread overview] Message-ID: <1578625755-11792-4-git-send-email-anshuman.khandual@arm.com> (raw) In-Reply-To: <1578625755-11792-1-git-send-email-anshuman.khandual@arm.com> early_init_dt_add_memory_arch() adds memory into memblock on both UEFI and DT based arm64 systems. Lets mark these as boot memory right after they get into memblock. All other platforms using this default implementation for early_init_dt_add_memory_arch() will also have this memblock flag set on boot memory ranges but will be upto the platforms if they would like to use it or not. On arm64 platform this flag will be used to identify boot memory at runtime and reject any attempt to remove them. Cc: Rob Herring <robh+dt@kernel.org> Cc: Frank Rowand <frowand.list@gmail.com> Cc: devicetree@vger.kernel.org Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com> --- drivers/of/fdt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c index 2cdf64d..a2ae2c88 100644 --- a/drivers/of/fdt.c +++ b/drivers/of/fdt.c @@ -1143,6 +1143,7 @@ void __init __weak early_init_dt_add_memory_arch(u64 base, u64 size) base = phys_offset; } memblock_add(base, size); + memblock_mark_boot(base, size); } int __init __weak early_init_dt_mark_hotplug_memory_arch(u64 base, u64 size) -- 2.7.4 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2020-01-10 3:09 UTC|newest] Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-01-10 3:09 [PATCH V11 0/5] arm64/mm: Enable memory hot remove Anshuman Khandual 2020-01-10 3:09 ` Anshuman Khandual 2020-01-10 3:09 ` [PATCH V11 1/5] mm/hotplug: Introduce arch callback validating the hot remove range Anshuman Khandual 2020-01-10 3:09 ` Anshuman Khandual 2020-01-10 8:42 ` David Hildenbrand 2020-01-10 8:42 ` David Hildenbrand 2020-01-13 9:11 ` Anshuman Khandual 2020-01-13 9:11 ` Anshuman Khandual 2020-01-13 9:14 ` David Hildenbrand 2020-01-13 9:14 ` David Hildenbrand 2020-01-13 9:50 ` Anshuman Khandual 2020-01-13 9:50 ` Anshuman Khandual 2020-01-13 10:37 ` David Hildenbrand 2020-01-13 10:37 ` David Hildenbrand 2020-01-14 2:13 ` Anshuman Khandual 2020-01-14 2:13 ` Anshuman Khandual 2020-01-14 11:09 ` Anshuman Khandual 2020-01-14 11:09 ` Anshuman Khandual 2020-01-14 12:30 ` David Hildenbrand 2020-01-14 12:30 ` David Hildenbrand 2020-01-11 14:11 ` kbuild test robot 2020-01-11 14:11 ` kbuild test robot 2020-01-11 14:11 ` kbuild test robot 2020-01-13 4:06 ` Anshuman Khandual 2020-01-13 4:06 ` Anshuman Khandual 2020-01-13 4:06 ` Anshuman Khandual 2020-01-11 19:49 ` kbuild test robot 2020-01-11 19:49 ` kbuild test robot 2020-01-11 19:49 ` kbuild test robot 2020-01-10 3:09 ` [PATCH V11 2/5] mm/memblock: Introduce MEMBLOCK_BOOT flag Anshuman Khandual 2020-01-10 3:09 ` Anshuman Khandual 2020-01-13 7:37 ` Mike Rapoport 2020-01-13 7:37 ` Mike Rapoport 2020-01-13 8:43 ` Anshuman Khandual 2020-01-13 8:43 ` Anshuman Khandual 2020-01-13 8:57 ` David Hildenbrand 2020-01-13 8:57 ` David Hildenbrand 2020-01-10 3:09 ` Anshuman Khandual [this message] 2020-01-10 3:09 ` [PATCH V11 3/5] of/fdt: Mark boot memory with MEMBLOCK_BOOT Anshuman Khandual 2020-01-10 3:09 ` [PATCH V11 4/5] arm64/mm: Hold memory hotplug lock while walking for kernel page table dump Anshuman Khandual 2020-01-10 3:09 ` Anshuman Khandual 2020-01-10 3:09 ` [PATCH V11 5/5] arm64/mm: Enable memory hot remove Anshuman Khandual 2020-01-10 3:09 ` 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=1578625755-11792-4-git-send-email-anshuman.khandual@arm.com \ --to=anshuman.khandual@arm.com \ --cc=Robin.Murphy@arm.com \ --cc=akpm@linux-foundation.org \ --cc=ard.biesheuvel@arm.com \ --cc=arunks@codeaurora.org \ --cc=broonie@kernel.org \ --cc=cai@lca.pw \ --cc=catalin.marinas@arm.com \ --cc=cpandya@codeaurora.org \ --cc=dan.j.williams@intel.com \ --cc=david@redhat.com \ --cc=devicetree@vger.kernel.org \ --cc=frowand.list@gmail.com \ --cc=ira.weiny@intel.com \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-kernel@vger.kernel.org \ --cc=linux-mm@kvack.org \ --cc=logang@deltatee.com \ --cc=mark.rutland@arm.com \ --cc=mgorman@techsingularity.net \ --cc=osalvador@suse.de \ --cc=robh+dt@kernel.org \ --cc=steve.capper@arm.com \ --cc=steven.price@arm.com \ --cc=suzuki.poulose@arm.com \ --cc=valentin.schneider@arm.com \ --cc=will@kernel.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: linkBe 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.