aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86/page.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-x86/page.h')
-rw-r--r--include/asm-x86/page.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/include/asm-x86/page.h b/include/asm-x86/page.h
index dc936dddf161..28d7b4533b1a 100644
--- a/include/asm-x86/page.h
+++ b/include/asm-x86/page.h
@@ -51,9 +51,17 @@
51 51
52#ifndef __ASSEMBLY__ 52#ifndef __ASSEMBLY__
53 53
54typedef struct { pgdval_t pgd; } pgd_t;
55typedef struct { pgprotval_t pgprot; } pgprot_t;
56
54extern int page_is_ram(unsigned long pagenr); 57extern int page_is_ram(unsigned long pagenr);
55extern int devmem_is_allowed(unsigned long pagenr); 58extern int devmem_is_allowed(unsigned long pagenr);
59extern void map_devmem(unsigned long pfn, unsigned long size,
60 pgprot_t vma_prot);
61extern void unmap_devmem(unsigned long pfn, unsigned long size,
62 pgprot_t vma_prot);
56 63
64extern unsigned long max_low_pfn_mapped;
57extern unsigned long max_pfn_mapped; 65extern unsigned long max_pfn_mapped;
58 66
59struct page; 67struct page;
@@ -74,9 +82,6 @@ static inline void copy_user_page(void *to, void *from, unsigned long vaddr,
74 alloc_page_vma(GFP_HIGHUSER | __GFP_ZERO | movableflags, vma, vaddr) 82 alloc_page_vma(GFP_HIGHUSER | __GFP_ZERO | movableflags, vma, vaddr)
75#define __HAVE_ARCH_ALLOC_ZEROED_USER_HIGHPAGE 83#define __HAVE_ARCH_ALLOC_ZEROED_USER_HIGHPAGE
76 84
77typedef struct { pgdval_t pgd; } pgd_t;
78typedef struct { pgprotval_t pgprot; } pgprot_t;
79
80static inline pgd_t native_make_pgd(pgdval_t val) 85static inline pgd_t native_make_pgd(pgdval_t val)
81{ 86{
82 return (pgd_t) { val }; 87 return (pgd_t) { val };
@@ -160,6 +165,7 @@ static inline pteval_t native_pte_val(pte_t pte)
160#endif 165#endif
161 166
162#define pte_val(x) native_pte_val(x) 167#define pte_val(x) native_pte_val(x)
168#define pte_flags(x) native_pte_val(x)
163#define __pte(x) native_make_pte(x) 169#define __pte(x) native_make_pte(x)
164 170
165#endif /* CONFIG_PARAVIRT */ 171#endif /* CONFIG_PARAVIRT */