]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
arm_elf_read_implies_exec(): remove unused argument
authorNicolas Pitre <nicolas.pitre@linaro.org>
Sat, 22 Jul 2017 04:48:09 +0000 (00:48 -0400)
committerNicolas Pitre <nicolas.pitre@linaro.org>
Sun, 10 Sep 2017 23:31:46 +0000 (19:31 -0400)
The first argument to elf_read_implies_exec() is either the actual
header structure or a pointer to that structure whether one looks
at fs/binfmt_elf.c or fs/binfmt_elf_fdpic.c. This ought to be fixed
of course, but in the mean time let's sidestep the issue by removing
that first argument from arm_elf_read_implies_exec() as it is unused
anyway.

Signed-off-by: Nicolas Pitre <nico@linaro.org>
Acked-by: Mickael GUENE <mickael.guene@st.com>
Tested-by: Vincent Abriou <vincent.abriou@st.com>
Tested-by: Andras Szemzo <szemzo.andras@gmail.com>
arch/arm/include/asm/elf.h
arch/arm/kernel/elf.c

index f13ae153fb246b9d64f2c99f75a717b70c1e5a67..e2786acf8202e92b5c57233e3ff975473669e280 100644 (file)
@@ -102,8 +102,8 @@ extern int elf_check_arch(const struct elf32_hdr *);
 
 #define vmcore_elf64_check_arch(x) (0)
 
-extern int arm_elf_read_implies_exec(const struct elf32_hdr *, int);
-#define elf_read_implies_exec(ex,stk) arm_elf_read_implies_exec(&(ex), stk)
+extern int arm_elf_read_implies_exec(int);
+#define elf_read_implies_exec(ex,stk) arm_elf_read_implies_exec(stk)
 
 struct task_struct;
 int dump_task_regs(struct task_struct *t, elf_gregset_t *elfregs);
index d0d1e83150c9553619c4a7f6c76605504d8765bc..52fb98358d9d755ad004d2a448f4798cd09573c5 100644 (file)
@@ -80,7 +80,7 @@ EXPORT_SYMBOL(elf_set_personality);
  *  - the binary requires an executable stack
  *  - we're running on a CPU which doesn't support NX.
  */
-int arm_elf_read_implies_exec(const struct elf32_hdr *x, int executable_stack)
+int arm_elf_read_implies_exec(int executable_stack)
 {
        if (executable_stack != EXSTACK_DISABLE_X)
                return 1;