Commit ac7fb273 authored by Matthew Wilcox's avatar Matthew Wilcox Committed by Linus Torvalds

[PATCH] headers_check: Clean up asm-parisc/page.h for user headers

Remove definitions of PAGE_* from the user view
Delete unnecessary comments referring to the size of pages
Only include <asm-generic> if we're in __KERNEL__
Signed-off-by: default avatarDavid Woodhouse <dwmw2@infradead.org>
Signed-off-by: default avatarMatthew Wilcox <matthew@wil.cx>
Signed-off-by: default avatarKyle McMartin <kyle@parisc-linux.org>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 020d8c06
#ifndef _PARISC_PAGE_H #ifndef _PARISC_PAGE_H
#define _PARISC_PAGE_H #define _PARISC_PAGE_H
#if !defined(__KERNEL__)
/* this is for userspace applications (4k page size) */
# define PAGE_SHIFT 12 /* 4k */
# define PAGE_SIZE (1UL << PAGE_SHIFT)
# define PAGE_MASK (~(PAGE_SIZE-1))
#endif
#ifdef __KERNEL__ #ifdef __KERNEL__
#if defined(CONFIG_PARISC_PAGE_SIZE_4KB) #if defined(CONFIG_PARISC_PAGE_SIZE_4KB)
# define PAGE_SHIFT 12 /* 4k */ # define PAGE_SHIFT 12
#elif defined(CONFIG_PARISC_PAGE_SIZE_16KB) #elif defined(CONFIG_PARISC_PAGE_SIZE_16KB)
# define PAGE_SHIFT 14 /* 16k */ # define PAGE_SHIFT 14
#elif defined(CONFIG_PARISC_PAGE_SIZE_64KB) #elif defined(CONFIG_PARISC_PAGE_SIZE_64KB)
# define PAGE_SHIFT 16 /* 64k */ # define PAGE_SHIFT 16
#else #else
# error "unknown default kernel page size" # error "unknown default kernel page size"
#endif #endif
...@@ -188,9 +180,9 @@ extern int npmem_ranges; ...@@ -188,9 +180,9 @@ extern int npmem_ranges;
#define VM_DATA_DEFAULT_FLAGS (VM_READ | VM_WRITE | VM_EXEC | \ #define VM_DATA_DEFAULT_FLAGS (VM_READ | VM_WRITE | VM_EXEC | \
VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
#endif /* __KERNEL__ */
#include <asm-generic/memory_model.h> #include <asm-generic/memory_model.h>
#include <asm-generic/page.h> #include <asm-generic/page.h>
#endif /* __KERNEL__ */
#endif /* _PARISC_PAGE_H */ #endif /* _PARISC_PAGE_H */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment