1b2441318SGreg Kroah-Hartman /* SPDX-License-Identifier: GPL-2.0 */ 2b0b5e9b1SAneesh Kumar K.V #ifndef _ASM_POWERPC_PGTABLE_RADIX_64K_H 3b0b5e9b1SAneesh Kumar K.V #define _ASM_POWERPC_PGTABLE_RADIX_64K_H 4b0b5e9b1SAneesh Kumar K.V 5b0b5e9b1SAneesh Kumar K.V /* 6b0b5e9b1SAneesh Kumar K.V * For 64K page size supported index is 13/9/9/5 7b0b5e9b1SAneesh Kumar K.V */ 8*eea86aa4SMichael Ellerman #define RADIX_PTE_INDEX_SIZE 5 // size: 8B << 5 = 256B, maps 2^5 x 64K = 2MB 9*eea86aa4SMichael Ellerman #define RADIX_PMD_INDEX_SIZE 9 // size: 8B << 9 = 4KB, maps 2^9 x 2MB = 1GB 10*eea86aa4SMichael Ellerman #define RADIX_PUD_INDEX_SIZE 9 // size: 8B << 9 = 4KB, maps 2^9 x 1GB = 512GB 11*eea86aa4SMichael Ellerman #define RADIX_PGD_INDEX_SIZE 13 // size: 8B << 13 = 64KB, maps 2^13 x 512GB = 4PB 12b0b5e9b1SAneesh Kumar K.V 13fb4e5dbdSAneesh Kumar K.V /* 14fb4e5dbdSAneesh Kumar K.V * We use a 256 byte PTE page fragment in radix 15fb4e5dbdSAneesh Kumar K.V * 8 bytes per each PTE entry. 16fb4e5dbdSAneesh Kumar K.V */ 17fb4e5dbdSAneesh Kumar K.V #define RADIX_PTE_FRAG_SIZE_SHIFT (RADIX_PTE_INDEX_SIZE + 3) 18fb4e5dbdSAneesh Kumar K.V #define RADIX_PTE_FRAG_NR (PAGE_SIZE >> RADIX_PTE_FRAG_SIZE_SHIFT) 198a6c697bSAneesh Kumar K.V 208a6c697bSAneesh Kumar K.V #define RADIX_PMD_FRAG_SIZE_SHIFT (RADIX_PMD_INDEX_SIZE + 3) 218a6c697bSAneesh Kumar K.V #define RADIX_PMD_FRAG_NR (PAGE_SIZE >> RADIX_PMD_FRAG_SIZE_SHIFT) 228a6c697bSAneesh Kumar K.V 23b0b5e9b1SAneesh Kumar K.V #endif /* _ASM_POWERPC_PGTABLE_RADIX_64K_H */ 24