linux/arch/powerpc
Christophe Leroy 03bb2d6590 powerpc: get hugetlbpage handling more generic
Today there are two implementations of hugetlbpages which are managed
by exclusive #ifdefs:
* FSL_BOOKE: several directory entries points to the same single hugepage
* BOOK3S: one upper level directory entry points to a table of hugepages

In preparation of implementation of hugepage support on the 8xx, we
need a mix of the two above solutions, because the 8xx needs both cases
depending on the size of pages:
* In 4k page size mode, each PGD entry covers a 4M bytes area. It means
that 2 PGD entries will be necessary to cover an 8M hugepage while a
single PGD entry will cover 8x 512k hugepages.
* In 16 page size mode, each PGD entry covers a 64M bytes area. It means
that 8x 8M hugepages will be covered by one PGD entry and 64x 512k
hugepages will be covers by one PGD entry.

This patch:
* removes #ifdefs in favor of if/else based on the range sizes
* merges the two huge_pte_alloc() functions as they are pretty similar
* merges the two hugetlbpage_init() functions as they are pretty similar

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> (v3)
Signed-off-by: Scott Wood <oss@buserror.net>
2016-12-09 22:48:09 -06:00
..
boot powerpc/dts: add device tree entry for W83793 on T4240RDB 2016-11-22 01:26:48 -06:00
configs powerpc/85xx: Enable gpio power/reset driver 2016-11-23 01:23:38 -06:00
crypto Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 2016-10-10 14:04:16 -07:00
include powerpc: port 64 bits pgtable_cache to 32 bits 2016-12-09 22:48:01 -06:00
kernel powerpc/vio: Clarify vio_find_node() reference counting 2016-11-14 20:05:59 +11:00
kvm KVM: PPC: Book3S HV: Fix build error when SMP=n 2016-10-22 08:44:37 +11:00
lib powerpc: EX_TABLE macro for exception tables 2016-11-14 11:11:51 +11:00
math-emu
mm powerpc: get hugetlbpage handling more generic 2016-12-09 22:48:09 -06:00
net powerpc/bpf: Add support for bpf constant blinding 2016-10-04 20:33:20 +11:00
oprofile powerpc/sparse: Make a bunch of things static 2016-09-13 17:35:47 +10:00
perf powerpc/sparse: Make a bunch of things static 2016-09-13 17:35:47 +10:00
platforms powerpc/83xx/suspend: use builtin_platform_driver 2016-12-04 19:51:27 -06:00
scripts
sysdev powerpc/fsl_pmc: use builtin_platform_driver 2016-12-04 19:51:44 -06:00
xmon powerpc/xmon: Don't use ld on 32-bit 2016-09-13 17:37:02 +10:00
Kconfig powerpc/64: Add an option to force run-at-load to test relocation 2016-11-14 11:11:51 +11:00
Kconfig.debug powerpc/mm: Dump linux pagetables 2016-11-17 17:11:46 +11:00
Makefile powerpc/book3s64: Always build for power4 or later 2016-11-14 11:11:51 +11:00
relocs_check.sh powerpc/64: whitelist unresolved modversions CRCs 2016-09-22 14:46:31 +02:00