Merge branch 'writeback-for-next' of git://git.kernel.org/pub/scm/linux/kernel/git...
[deliverable/linux.git] / arch / x86 / include / asm / page_32.h
CommitLineData
1965aae3
PA
1#ifndef _ASM_X86_PAGE_32_H
2#define _ASM_X86_PAGE_32_H
11b7c7dc 3
51c78eb3 4#include <asm/page_32_types.h>
3bf8f5a9 5
beb6943d
IM
6#ifndef __ASSEMBLY__
7
11b7c7dc
JF
8#ifdef CONFIG_HUGETLB_PAGE
9#define HAVE_ARCH_HUGETLB_UNMAPPED_AREA
10#endif
1da177e4 11
af5c2bd1 12#define __phys_addr_nodebug(x) ((x) - PAGE_OFFSET)
a1bf9631 13#ifdef CONFIG_DEBUG_VIRTUAL
59ea7463 14extern unsigned long __phys_addr(unsigned long);
a1bf9631 15#else
af5c2bd1 16#define __phys_addr(x) __phys_addr_nodebug(x)
a1bf9631 17#endif
11b7c7dc
JF
18#define __phys_reloc_hide(x) RELOC_HIDE((x), 0)
19
20#ifdef CONFIG_FLATMEM
21#define pfn_valid(pfn) ((pfn) < max_mapnr)
22#endif /* CONFIG_FLATMEM */
23
11b7c7dc
JF
24#ifdef CONFIG_X86_USE_3DNOW
25#include <asm/mmx.h>
e6e5494c 26
11b7c7dc
JF
27static inline void clear_page(void *page)
28{
29 mmx_clear_page(page);
30}
1da177e4 31
11b7c7dc
JF
32static inline void copy_page(void *to, void *from)
33{
34 mmx_copy_page(to, from);
35}
36#else /* !CONFIG_X86_USE_3DNOW */
37#include <linux/string.h>
1da177e4 38
11b7c7dc
JF
39static inline void clear_page(void *page)
40{
41 memset(page, 0, PAGE_SIZE);
42}
fd4fd5aa 43
11b7c7dc
JF
44static inline void copy_page(void *to, void *from)
45{
46 memcpy(to, from, PAGE_SIZE);
47}
48#endif /* CONFIG_X86_3DNOW */
49#endif /* !__ASSEMBLY__ */
cd469e0c 50
1965aae3 51#endif /* _ASM_X86_PAGE_32_H */
This page took 0.740443 seconds and 5 git commands to generate.