lkml.org 
[lkml]   [2008]   [Jun]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v2] export linux/a.out.h
From
Date
On Mon, 2008-06-16 at 16:40 +0200, Andi Kleen wrote:
> > We should get rid of CONFIG_ARCH_SUPPORTS_AOUT entirely. The only
> > remaining users of it are fs/exec.c, which uses it entirely redundantly:
> > #if defined(__alpha__) && defined(CONFIG_ARCH_SUPPORTS_AOUT)
> >
> > ...and (indirectly, by virtue of being the only other file that includes
> > <linux/a.out.h> when ARCH_SUPPORTS_AOUT might be unset) fs/binfmt_elf.c,
> > which still has unnecessary references to 'struct exec' even though Andi
> > removed the support for a.out interpreters a few months ago. That can
> > just go away.
>
> I didn't think the Alpha /sbin/loader stuff was an a.out interpreter for ELF.
>
> Also pure a.out is still supported.
>
> It might be ok to remove it anyways, but you should check with someone
> who knows Alpha first. cc Richard.

The Alpha /sbin/loader support, and the a.out-interpreter-for-ELF, are
two completely separate issues -- you're right that /sbin/loader isn't
an a.out interpreter for ELF files.

They're the two places which rely on '#ifdef CONFIG_ARCH_SUPPORTS_AOUT'
in <linux/a.out.h>, because they include <linux/a.out.h> on platforms
which might not have <asm/a.out.h>.

In the Alpha case in fs/exec.c, we can simply include <linux/a.out.h>
only #ifdef __alpha__ -- while noting that that code could probably do
with a little more cleanup and turning into a properly registered binfmt
rather than a special case, if possible.

In the case of fs/binfmt_elf.c, we can simply remove the inclusion of
<linux/a.out.h> and all references to 'struct exec'. You removed the
rest of the a.out interpreter support already; that last part probably
should have gone away at the same time.

Proper a.out support in fs/binfmt_aout.c can stay as it is; you won't be
building binfmt_aout.c unless your platform supports a.out anyway.

And then we can remove the #ifdef CONFIG_ARCH_SUPPORTS_AOUT in
<linux/a.out.h>, and export it to userspace again, which was the point
of Peter's patch that started this thread.

--
dwmw2



\
 
 \ /
  Last update: 2008-06-16 17:19    [W:0.100 / U:0.520 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site