xref: /linux/arch/arm/include/asm/page-nommu.h (revision 3a64d5b82eccc0dc629d43cde791a2c19bd67dfc)
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3  *  arch/arm/include/asm/page-nommu.h
4  *
5  *  Copyright (C) 2004 Hyok S. Choi
6  */
7 
8 #ifndef _ASMARM_PAGE_NOMMU_H
9 #define _ASMARM_PAGE_NOMMU_H
10 
11 #define clear_page(page)	memset((page), 0, PAGE_SIZE)
12 #define copy_page(to,from)	memcpy((to), (from), PAGE_SIZE)
13 
14 #define copy_user_page(to, from, vaddr, pg)	copy_page(to, from)
15 
16 /*
17  * These are used to make use of C type-checking..
18  */
19 typedef unsigned long pte_t;
20 typedef unsigned long pmd_t;
21 typedef unsigned long pgd_t[2];
22 typedef unsigned long pgprot_t;
23 
24 #define pte_val(x)      (x)
25 #define pmd_val(x)      (x)
26 #define pgd_val(x)	((x)[0])
27 #define pgprot_val(x)   (x)
28 
29 #define __pte(x)        (x)
30 #define __pmd(x)        (x)
31 #define __pgprot(x)     (x)
32 
33 #endif
34