]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[S390] arch_setup_additional_pages arguments
authorMartin Schwidefsky <schwidefsky@de.ibm.com>
Thu, 25 Dec 2008 12:38:35 +0000 (13:38 +0100)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Thu, 25 Dec 2008 12:38:54 +0000 (13:38 +0100)
arch_setup_additional_pages currently gets two arguments, the binary
format descripton and an indication if the process uses an executable
stack or not. The second argument is not used by anybody, it could
be removed without replacement.

What actually does make sense is to pass an indication if the process
uses the elf interpreter or not. The glibc code will not use anything
from the vdso if the process does not use the dynamic linker, so for
statically linked binaries the architecture backend can choose not
to map the vdso.

Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/powerpc/include/asm/elf.h
arch/powerpc/kernel/vdso.c
arch/sh/include/asm/elf.h
arch/sh/kernel/vsyscall/vsyscall.c
arch/x86/include/asm/elf.h
arch/x86/vdso/vdso32-setup.c
arch/x86/vdso/vma.c
fs/binfmt_elf.c

index d812929390e45e602b0a2e02506c7e4e4ac1474c..cd46f023ec6d298dd4571249881ed54a12649eb0 100644 (file)
@@ -267,7 +267,7 @@ extern int ucache_bsize;
 #define ARCH_HAS_SETUP_ADDITIONAL_PAGES
 struct linux_binprm;
 extern int arch_setup_additional_pages(struct linux_binprm *bprm,
-                                      int executable_stack);
+                                      int uses_interp);
 #define VDSO_AUX_ENT(a,b) NEW_AUX_ENT(a,b);
 
 #endif /* __KERNEL__ */
index 65639a43e644888577d4bf92328f54c95aef99fb..f7ec7d0888fef270bc33aeb26bd8a074af917664 100644 (file)
@@ -184,8 +184,7 @@ static void dump_vdso_pages(struct vm_area_struct * vma)
  * This is called from binfmt_elf, we create the special vma for the
  * vDSO and insert it into the mm struct tree
  */
-int arch_setup_additional_pages(struct linux_binprm *bprm,
-                               int executable_stack)
+int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp)
 {
        struct mm_struct *mm = current->mm;
        struct page **vdso_pagelist;
index 9eb9036a1bdc27e9a1fb50efe636ed9150e9c3f1..9381397ebeb8e8ad0d4a4e29e700b61d4c449d68 100644 (file)
@@ -204,7 +204,7 @@ do {                                                                        \
 #define ARCH_HAS_SETUP_ADDITIONAL_PAGES
 struct linux_binprm;
 extern int arch_setup_additional_pages(struct linux_binprm *bprm,
-                                      int executable_stack);
+                                      int uses_interp);
 
 extern unsigned int vdso_enabled;
 extern void __kernel_vsyscall;
index 95f4de0800ec71ceaf167d7801168d5011d95d4e..3f7e415be86ade5ee681e11b174754d91f231d6b 100644 (file)
@@ -59,8 +59,7 @@ int __init vsyscall_init(void)
 }
 
 /* Setup a VMA at program startup for the vsyscall page */
-int arch_setup_additional_pages(struct linux_binprm *bprm,
-                               int executable_stack)
+int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp)
 {
        struct mm_struct *mm = current->mm;
        unsigned long addr;
index 40ca1bea7916cc075448446887609b43e58dc670..f51a3ddde01a753c5931e4d352c165a6e3d0ebd7 100644 (file)
@@ -325,7 +325,7 @@ struct linux_binprm;
 
 #define ARCH_HAS_SETUP_ADDITIONAL_PAGES 1
 extern int arch_setup_additional_pages(struct linux_binprm *bprm,
-                                      int executable_stack);
+                                      int uses_interp);
 
 extern int syscall32_setup_pages(struct linux_binprm *, int exstack);
 #define compat_arch_setup_additional_pages     syscall32_setup_pages
index 513f330c58326b2126e6cfe4c78214eaa77226e8..1241f118ab561b181b5dd9634f5c80d7783de493 100644 (file)
@@ -310,7 +310,7 @@ int __init sysenter_setup(void)
 }
 
 /* Setup a VMA at program startup for the vsyscall page */
-int arch_setup_additional_pages(struct linux_binprm *bprm, int exstack)
+int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp)
 {
        struct mm_struct *mm = current->mm;
        unsigned long addr;
index 257ba4a10abf0740ee908d2ff1369c77d7d31b50..9c98cc6ba9783ce1c1caac812341924e43ae98aa 100644 (file)
@@ -98,7 +98,7 @@ static unsigned long vdso_addr(unsigned long start, unsigned len)
 
 /* Setup a VMA at program startup for the vsyscall page.
    Not called for compat tasks */
-int arch_setup_additional_pages(struct linux_binprm *bprm, int exstack)
+int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp)
 {
        struct mm_struct *mm = current->mm;
        unsigned long addr;
index 8fcfa398d35075e1e149b70d62226a6095524ad3..95a76ff9e01b6d9b3da8fd352b358b6d0d675ef0 100644 (file)
@@ -949,7 +949,7 @@ static int load_elf_binary(struct linux_binprm *bprm, struct pt_regs *regs)
        set_binfmt(&elf_format);
 
 #ifdef ARCH_HAS_SETUP_ADDITIONAL_PAGES
-       retval = arch_setup_additional_pages(bprm, executable_stack);
+       retval = arch_setup_additional_pages(bprm, !!elf_interpreter);
        if (retval < 0) {
                send_sig(SIGKILL, current, 0);
                goto out;