[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7f7499bd-8d48-945b-6d69-60685a02c8da@arm.com>
Date: Wed, 24 Apr 2019 14:37:11 +0530
From: Anshuman Khandual <anshuman.khandual@....com>
To: Pavel Tatashin <pasha.tatashin@...een.com>, jmorris@...ei.org,
sashal@...nel.org, linux-kernel@...r.kernel.org,
linux-mm@...ck.org, linux-nvdimm@...ts.01.org,
akpm@...ux-foundation.org, mhocko@...e.com,
dave.hansen@...ux.intel.com, dan.j.williams@...el.com,
keith.busch@...el.com, vishal.l.verma@...el.com,
dave.jiang@...el.com, zwisler@...nel.org, thomas.lendacky@....com,
ying.huang@...el.com, fengguang.wu@...el.com, bp@...e.de,
bhelgaas@...gle.com, baiyaowei@...s.chinamobile.com, tiwai@...e.de,
jglisse@...hat.com, catalin.marinas@....com, will.deacon@....com,
rppt@...ux.vnet.ibm.com, ard.biesheuvel@...aro.org,
andrew.murray@....com, james.morse@....com, marc.zyngier@....com,
sboyd@...nel.org, linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH] arm64: configurable sparsemem section size
On 04/24/2019 02:08 AM, Pavel Tatashin wrote:
> sparsemem section size determines the maximum size and alignment that
> is allowed to offline/online memory block. The bigger the size the less
> the clutter in /sys/devices/system/memory/*. On the other hand, however,
> there is less flexability in what granules of memory can be added and
> removed.
Is there any scenario where less than a 1GB needs to be added on arm64 ?
>
> Recently, it was enabled in Linux to hotadd persistent memory that
> can be either real NV device, or reserved from regular System RAM
> and has identity of devdax.
devdax (even ZONE_DEVICE) support has not been enabled on arm64 yet.
>
> The problem is that because ARM64's section size is 1G, and devdax must
> have 2M label section, the first 1G is always missed when device is
> attached, because it is not 1G aligned.
devdax has to be 2M aligned ? Does Linux enforce that right now ?
>
> Allow, better flexibility by making section size configurable.
Unless 2M is being enforced from Linux not sure why this is necessary at
the moment.
>
> Signed-off-by: Pavel Tatashin <pasha.tatashin@...een.com>
> ---
> arch/arm64/Kconfig | 10 ++++++++++
> arch/arm64/include/asm/sparsemem.h | 2 +-
> 2 files changed, 11 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig
> index b5d8cf57e220..a0c5b9d13a7f 100644
> --- a/arch/arm64/Kconfig
> +++ b/arch/arm64/Kconfig
> @@ -801,6 +801,16 @@ config ARM64_PA_BITS
> default 48 if ARM64_PA_BITS_48
> default 52 if ARM64_PA_BITS_52
>
> +config ARM64_SECTION_SIZE_BITS
> + int "sparsemem section size shift"
> + range 27 30
27 and 28 do not even compile for ARM64_64_PAGES because of MAX_ORDER and
SECTION_SIZE mismatch.
Powered by blists - more mailing lists