]> www.infradead.org Git - users/willy/linux.git/commit
mm: Introduce common STRUCT_PAGE_MAX_SHIFT define
authorLogan Gunthorpe <logang@deltatee.com>
Wed, 5 Dec 2018 00:14:20 +0000 (11:14 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Mon, 10 Dec 2018 08:29:15 +0000 (19:29 +1100)
commit28fe6e58967188e8db0dfd49885e97d8b825030c
tree1a57deea9ce414fe2989f75e1b2a355d0b28ed10
parent47edb5d5f7a25b39e1161e20a0082eb7b7c52d1e
mm: Introduce common STRUCT_PAGE_MAX_SHIFT define

This define is used by arm64 to calculate the size of the vmemmap
region. It is defined as the log2 of the upper bound on the size
of a struct page.

We move it into mm_types.h so it can be defined properly instead of
set and checked with a build bug. This also allows us to use the same
define for riscv.

Link: http://lkml.kernel.org/r/20181107205433.3875-2-logang@deltatee.com
Signed-off-by: Logan Gunthorpe <logang@deltatee.com>
Acked-by: Will Deacon <will.deacon@arm.com>
Acked-by: Andrew Morton <akpm@linux-foundation.org>
Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
arch/arm64/include/asm/memory.h
arch/arm64/mm/init.c
include/asm-generic/fixmap.h
include/linux/mm_types.h