/* SPDX-License-Identifier: GPL-2.0 */ #ifndef __ASM_SH_PGTABLE_3LEVEL_H #define __ASM_SH_PGTABLE_3LEVEL_H #define __ARCH_USE_5LEVEL_HACK #include <asm-generic/pgtable-nopud.h> /* * Some cores need a 3-level page table layout, for example when using * 64-bit PTEs and 4K pages. */ #define PAGETABLE_LEVELS 3 #define PTE_MAGNITUDE 3 /* 64-bit PTEs on SH-X2 TLB */ /* PGD bits */ #define PGDIR_SHIFT 30 #define PTRS_PER_PGD 4 #define USER_PTRS_PER_PGD 2 /* PMD bits */ #define PMD_SHIFT (PAGE_SHIFT + (PAGE_SHIFT - PTE_MAGNITUDE)) #define PMD_SIZE (1UL << PMD_SHIFT) #define PMD_MASK (~(PMD_SIZE-1)) #define PTRS_PER_PMD ((1 << PGDIR_SHIFT) / PMD_SIZE) #define pmd_ERROR(e) \ printk("%s:%d: bad pmd %016llx.\n", __FILE__, __LINE__, pmd_val(e)) typedef struct { unsigned long long pmd; } pmd_t; #define pmd_val(x) ((x).pmd) #define __pmd(x) ((pmd_t) { (x) } )
static inline unsigned long pud_page_vaddr(pud_t pud) { return pud_val(pud); }Contributors
Person | Tokens | Prop | Commits | CommitProp |
Matt Fleming | 17 | 100.00% | 1 | 100.00% |
Total | 17 | 100.00% | 1 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Matt Fleming | 32 | 100.00% | 1 | 100.00% |
Total | 32 | 100.00% | 1 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Matt Fleming | 171 | 93.44% | 2 | 33.33% |
Paul Mundt | 8 | 4.37% | 2 | 33.33% |
Kirill A. Shutemov | 3 | 1.64% | 1 | 16.67% |
Greg Kroah-Hartman | 1 | 0.55% | 1 | 16.67% |
Total | 183 | 100.00% | 6 | 100.00% |