Re: [PATCH mm] Remove deprecation of a.out ELF interpreters

Previous thread: [GIT] Please pull NFS client changes for 2.6.25... by Trond Myklebust on Wednesday, January 30, 2008 - 3:27 am. (1 message)

Next thread: [PATCH 0/4] [libata] Blackfin pata-bf54x driver updates by Bryan Wu on Wednesday, January 30, 2008 - 4:43 am. (6 messages)
To: <akpm@...>
Cc: <linux-kernel@...>
Date: Wednesday, January 30, 2008 - 4:40 am

Andrew has already queued the patch to remove the support for a.out
ELF interpreters. So remove the deprecation with it too.

Signed-off-by: Andi Kleen <ak@suse.de>

Index: linux/Documentation/feature-removal-schedule.txt
===================================================================
--- linux.orig/Documentation/feature-removal-schedule.txt
+++ linux/Documentation/feature-removal-schedule.txt
@@ -107,17 +107,6 @@ Who: Eric Biederman <ebiederm@xmission.c

---------------------------

-What: a.out interpreter support for ELF executables
-When: 2.6.25
-Files: fs/binfmt_elf.c
-Why: Using a.out interpreters for ELF executables was a feature for
- transition from a.out to ELF. But now it is unlikely to be still
- needed anymore and removing it would simplify the hairy ELF
- loader code.
-Who: Andi Kleen <ak@suse.de>
-
----------------------------
-
What: remove EXPORT_SYMBOL(kernel_thread)
When: August 2006
Files: arch/*/kernel/*_ksyms.c
--

To: Andi Kleen <andi@...>
Cc: <linux-kernel@...>
Date: Wednesday, January 30, 2008 - 7:29 pm

On Wed, 30 Jan 2008 09:40:41 +0100

I'm trying to find which patch I might have queued which did this and came
up blank.
aout-suppress-aout-library-support-if-config_arch_supports_aout.patch is
the only relevant one.

You have such a patch in your tree but afaict that will just wreck David's
patch.

Confused.
--

To: Andrew Morton <akpm@...>
Cc: Andi Kleen <andi@...>, <linux-kernel@...>
Date: Wednesday, January 30, 2008 - 11:09 pm

Sorry I somehow thought you had it queued.

My patch makes parts of David's patch obsolete because he makes
the code ifdef, but I remove the code completely. David also
does some other cleanups which still make sense.

So I think the correct way is to apply my patch first and then David's
and just ignore all the rejects and refresh. The result should be correct.

Basically after that only the core dump changes in David's patch should
be left over.

Can you do that or should I resubmit both patches in a merged form?
(I can do that too)

-Andi
--

To: Andi Kleen <andi@...>
Cc: <linux-kernel@...>
Date: Thursday, January 31, 2008 - 2:11 am

Your patch on top of rc8-mm1 would be simplest for me.

I'm at a bit of a loss because I don't appear to have a copy of the patch
which we're discussing handy.

--

To: Andrew Morton <akpm@...>
Cc: Andi Kleen <andi@...>, <linux-kernel@...>
Date: Thursday, January 31, 2008 - 3:35 am

> Your patch on top of rc8-mm1 would be simplest for me.

Here you go. I also folded in the update deprecation file patch so
you only need this one, nothing else.

-Andi

---

Remove a.out interpreter support in ELF loader

-mm patch for now. To be applied to 2.6.25.

Following the deprecation schedule the a.out ELF interpreter support
is removed now with this patch. a.out ELF interpreters were an transition
feature for moving a.out systems to ELF, but they're unlikely to be still
needed. Pure a.out systems will still work of course. This allows to
simplify the hairy ELF loader.

Signed-off-by: Andi Kleen <ak@suse.de>

---
Documentation/feature-removal-schedule.txt | 11 --
fs/binfmt_elf.c | 129 +----------------------------
2 files changed, 8 insertions(+), 132 deletions(-)

Index: linux-2.6.24-rc8-mm1/fs/binfmt_elf.c
===================================================================
--- linux-2.6.24-rc8-mm1.orig/fs/binfmt_elf.c
+++ linux-2.6.24-rc8-mm1/fs/binfmt_elf.c
@@ -134,8 +134,7 @@ static int padzero(unsigned long elf_bss

static int
create_elf_tables(struct linux_binprm *bprm, struct elfhdr *exec,
- int interp_aout, unsigned long load_addr,
- unsigned long interp_load_addr)
+ unsigned long load_addr, unsigned long interp_load_addr)
{
unsigned long p = bprm->p;
int argc = bprm->argc;
@@ -223,12 +222,7 @@ create_elf_tables(struct linux_binprm *b

sp = STACK_ADD(p, ei_index);

- items = (argc + 1) + (envc + 1);
- if (interp_aout) {
- items += 3; /* a.out interpreters require argv & envp too */
- } else {
- items += 1; /* ELF interpreters only put argc on the stack */
- }
+ items = (argc + 1) + (envc + 1) + 1;
bprm->p = STACK_ROUND(sp, items);

/* Point sp at the lowest address on the stack */
@@ -251,16 +245,8 @@ create_elf_tables(struct linux_binprm *b
/* Now, let's put argc (and argv, envp if appropriate) on the stack */
if (__put_user(argc, sp++))
return -EFAULT;...

Previous thread: [GIT] Please pull NFS client changes for 2.6.25... by Trond Myklebust on Wednesday, January 30, 2008 - 3:27 am. (1 message)

Next thread: [PATCH 0/4] [libata] Blackfin pata-bf54x driver updates by Bryan Wu on Wednesday, January 30, 2008 - 4:43 am. (6 messages)