diff options
author | Roland Dreier <roland@eddore.topspincom.com> | 2005-07-27 19:12:56 -0700 |
---|---|---|
committer | Roland Dreier <roland@eddore.topspincom.com> | 2005-07-27 19:12:56 -0700 |
commit | 2868bd281fef21d1e73d6b7648a41efc3d75f10c (patch) | |
tree | 0ad821cfcc9e3f9e8b662d026bec6bb6d4ce69ac /include/asm-cris/arch-v32/page.h | |
parent | 6d376756f2cf3478d5a4fdb8d18e958948366b9d (diff) | |
parent | 41c018b7ecb60b1c2c4d5dee0cd37d32a94c45af (diff) |
Merge /scratch/Ksrc/linux-git/
Diffstat (limited to 'include/asm-cris/arch-v32/page.h')
-rw-r--r-- | include/asm-cris/arch-v32/page.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/include/asm-cris/arch-v32/page.h b/include/asm-cris/arch-v32/page.h new file mode 100644 index 000000000000..77827bc17cca --- /dev/null +++ b/include/asm-cris/arch-v32/page.h @@ -0,0 +1,28 @@ +#ifndef _ASM_CRIS_ARCH_PAGE_H +#define _ASM_CRIS_ARCH_PAGE_H + +#include <linux/config.h> + +#ifdef __KERNEL__ + +#define PAGE_OFFSET KSEG_C /* kseg_c is mapped to physical ram. */ + +/* + * Macros to convert between physical and virtual addresses. By stripiing a + * selected bit it's possible to convert between KSEG_x and 0x40000000 where the + * DRAM really resides. DRAM is virtually at 0xc. + */ +#ifndef CONFIG_ETRAXFS_SIM +#define __pa(x) ((unsigned long)(x) & 0x7fffffff) +#define __va(x) ((void *)((unsigned long)(x) | 0x80000000)) +#else +#define __pa(x) ((unsigned long)(x) & 0x3fffffff) +#define __va(x) ((void *)((unsigned long)(x) | 0xc0000000)) +#endif + +#define VM_STACK_DEFAULT_FLAGS (VM_READ | VM_WRITE | \ + VM_MAYREAD | VM_MAYWRITE) + +#endif /* __KERNEL__ */ + +#endif /* _ASM_CRIS_ARCH_PAGE_H */ |