diff mbox series

[v3,12/34] nds32: mm: Add p?d_large() definitions

Message ID 20190227170608.27963-13-steven.price@arm.com (mailing list archive)
State New, archived
Headers show
Series Convert x86 & arm64 to use generic page walk | expand

Commit Message

Steven Price Feb. 27, 2019, 5:05 p.m. UTC
walk_page_range() is going to be allowed to walk page tables other than
those of user space. For this it needs to know when it has reached a
'leaf' entry in the page tables. This information is provided by the
p?d_large() functions/macros.

For nds32, we don't support large pages, so add stubs returning 0.

CC: Greentime Hu <green.hu@gmail.com>
CC: Vincent Chen <deanbo422@gmail.com>
Signed-off-by: Steven Price <steven.price@arm.com>
---
 arch/nds32/include/asm/pgtable.h | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/arch/nds32/include/asm/pgtable.h b/arch/nds32/include/asm/pgtable.h
index 9f52db930c00..202ac93c0a6b 100644
--- a/arch/nds32/include/asm/pgtable.h
+++ b/arch/nds32/include/asm/pgtable.h
@@ -309,6 +309,7 @@  static inline pte_t pte_mkspecial(pte_t pte)
 
 #define pmd_none(pmd)         (pmd_val(pmd)&0x1)
 #define pmd_present(pmd)      (!pmd_none(pmd))
+#define pmd_large(pmd)        (0)
 #define	pmd_bad(pmd)	      pmd_none(pmd)
 
 #define copy_pmd(pmdpd,pmdps)	set_pmd((pmdpd), *(pmdps))
@@ -349,6 +350,7 @@  static inline pmd_t __mk_pmd(pte_t * ptep, unsigned long prot)
 #define pgd_none(pgd)		(0)
 #define pgd_bad(pgd)		(0)
 #define pgd_present(pgd)  	(1)
+#define pgd_large(pgd)		(0)
 #define pgd_clear(pgdp)		do { } while (0)
 
 #define page_pte_prot(page,prot)     	mk_pte(page, prot)