summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Kjellerstedt <peter.kjellerstedt@axis.com>2006-02-23 15:11:29 +0000
committerPeter Kjellerstedt <peter.kjellerstedt@axis.com>2006-02-23 15:11:29 +0000
commit1d94558cb3dc19c819f1a74a47975b8a710366e2 (patch)
tree32866aa78f1028534444c98666509c8443662139
parent635d70f15447060a0deab7e3e2ca0703d6551c13 (diff)
Allow MMAP2_PAGE_SHIFT to be specified by the architecture specific
header files.
-rw-r--r--ldso/include/dl-syscall.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/ldso/include/dl-syscall.h b/ldso/include/dl-syscall.h
index 8f8c64a30..0c0687131 100644
--- a/ldso/include/dl-syscall.h
+++ b/ldso/include/dl-syscall.h
@@ -150,8 +150,15 @@ static inline _syscall6(void *, _dl_mmap, void *, start, size_t, length,
# define __NR___syscall_mmap2 __NR_mmap2
static inline _syscall6(__ptr_t, __syscall_mmap2, __ptr_t, addr, size_t, len,
int, prot, int, flags, int, fd, off_t, offset);
-/* always 12, even on architectures where PAGE_SHIFT != 12 */
+
+/* Some architectures always use 12 as page shift for mmap2() eventhough the
+ * real PAGE_SHIFT != 12. Other architectures use the same value as
+ * PAGE_SHIFT...
+ */
+#ifndef MMAP2_PAGE_SHIFT
# define MMAP2_PAGE_SHIFT 12
+#endif
+
static inline void * _dl_mmap(void * addr, unsigned long size, int prot,
int flags, int fd, unsigned long offset)
{