x86: move pte types into pgtable*.h
[pandora-kernel.git] / arch / x86 / include / asm / page_32_types.h
1 #ifndef _ASM_X86_PAGE_32_DEFS_H
2 #define _ASM_X86_PAGE_32_DEFS_H
3
4 #include <linux/const.h>
5
6 /*
7  * This handles the memory map.
8  *
9  * A __PAGE_OFFSET of 0xC0000000 means that the kernel has
10  * a virtual address space of one gigabyte, which limits the
11  * amount of physical memory you can use to about 950MB.
12  *
13  * If you want more physical memory than this then see the CONFIG_HIGHMEM4G
14  * and CONFIG_HIGHMEM64G options in the kernel configuration.
15  */
16 #define __PAGE_OFFSET           _AC(CONFIG_PAGE_OFFSET, UL)
17
18 #ifdef CONFIG_4KSTACKS
19 #define THREAD_ORDER    0
20 #else
21 #define THREAD_ORDER    1
22 #endif
23 #define THREAD_SIZE     (PAGE_SIZE << THREAD_ORDER)
24
25 #define STACKFAULT_STACK 0
26 #define DOUBLEFAULT_STACK 1
27 #define NMI_STACK 0
28 #define DEBUG_STACK 0
29 #define MCE_STACK 0
30 #define N_EXCEPTION_STACKS 1
31
32 #ifdef CONFIG_X86_PAE
33 /* 44=32+12, the limit we can fit into an unsigned long pfn */
34 #define __PHYSICAL_MASK_SHIFT   44
35 #define __VIRTUAL_MASK_SHIFT    32
36 #define PAGETABLE_LEVELS        3
37
38 #else  /* !CONFIG_X86_PAE */
39 #define __PHYSICAL_MASK_SHIFT   32
40 #define __VIRTUAL_MASK_SHIFT    32
41 #define PAGETABLE_LEVELS        2
42 #endif  /* CONFIG_X86_PAE */
43
44 #ifndef __ASSEMBLY__
45
46 /*
47  * This much address space is reserved for vmalloc() and iomap()
48  * as well as fixmap mappings.
49  */
50 extern unsigned int __VMALLOC_RESERVE;
51 extern int sysctl_legacy_va_layout;
52
53 extern void find_low_pfn_range(void);
54 extern unsigned long init_memory_mapping(unsigned long start,
55                                          unsigned long end);
56 extern void initmem_init(unsigned long, unsigned long);
57 extern void free_initmem(void);
58 extern void setup_bootmem_allocator(void);
59
60 #endif  /* !__ASSEMBLY__ */
61
62 #endif /* _ASM_X86_PAGE_32_DEFS_H */