LKML Archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/3] disallow modular binfmt_elf32
@ 2006-07-08 18:05 Christoph Hellwig
  2006-07-08 20:48 ` David Miller
  2006-07-10  6:06 ` Heiko Carstens
  0 siblings, 2 replies; 4+ messages in thread
From: Christoph Hellwig @ 2006-07-08 18:05 UTC (permalink / raw
  To: akpm, davem, schwidefsky; +Cc: linux-kernel

Currently most architectures either always build binfmt_elf32 in the
kernel image or make it a boolean option.  Only sparc64 and s390 allow
to build it modularly.  This patch turns the option into a boolean
aswell because elf requires various symbols that shouldn't be available
to modules.  The most urgent one is tasklist_lock whos export this patch
series kills, but there are others like force_sgi aswell.

Note that sparc doesn't allow a modular 32bit a.out handler either, and
that would be the more useful case as only few people want 32bit sunos
compatibility and 99.9% of all sparc64 users need 32bit linux native elf
support.


Signed-off-by: Christoph Hellwig <hch@lst.de>

Index: linux-2.6/arch/s390/Kconfig
===================================================================
--- linux-2.6.orig/arch/s390/Kconfig	2006-07-06 14:21:17.000000000 +0200
+++ linux-2.6/arch/s390/Kconfig	2006-07-08 19:08:46.000000000 +0200
@@ -119,7 +119,7 @@
 	default y
 
 config BINFMT_ELF32
-	tristate "Kernel support for 31 bit ELF binaries"
+	bool "Kernel support for 31 bit ELF binaries"
 	depends on COMPAT
 	help
 	  This allows you to run 32-bit Linux/ELF binaries on your zSeries
Index: linux-2.6/arch/sparc64/Kconfig
===================================================================
--- linux-2.6.orig/arch/sparc64/Kconfig	2006-07-01 12:49:02.000000000 +0200
+++ linux-2.6/arch/sparc64/Kconfig	2006-07-08 19:08:32.000000000 +0200
@@ -334,7 +334,7 @@
 	default y
 
 config BINFMT_ELF32
-	tristate "Kernel support for 32-bit ELF binaries"
+	bool "Kernel support for 32-bit ELF binaries"
 	depends on SPARC32_COMPAT
 	help
 	  This allows you to run 32-bit Linux/ELF binaries on your Ultra.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 2/3] disallow modular binfmt_elf32
  2006-07-08 18:05 [PATCH 2/3] disallow modular binfmt_elf32 Christoph Hellwig
@ 2006-07-08 20:48 ` David Miller
  2006-07-10  6:06 ` Heiko Carstens
  1 sibling, 0 replies; 4+ messages in thread
From: David Miller @ 2006-07-08 20:48 UTC (permalink / raw
  To: hch; +Cc: akpm, schwidefsky, linux-kernel

From: Christoph Hellwig <hch@lst.de>
Date: Sat, 8 Jul 2006 20:05:54 +0200

> Currently most architectures either always build binfmt_elf32 in the
> kernel image or make it a boolean option.  Only sparc64 and s390 allow
> to build it modularly.  This patch turns the option into a boolean
> aswell because elf requires various symbols that shouldn't be available
> to modules.  The most urgent one is tasklist_lock whos export this patch
> series kills, but there are others like force_sgi aswell.
> 
> Note that sparc doesn't allow a modular 32bit a.out handler either, and
> that would be the more useful case as only few people want 32bit sunos
> compatibility and 99.9% of all sparc64 users need 32bit linux native elf
> support.
> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>

Yeah, I'm ok with this:

Signed-off-by: David S. Miller <davem@davemloft.net>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 2/3] disallow modular binfmt_elf32
  2006-07-08 18:05 [PATCH 2/3] disallow modular binfmt_elf32 Christoph Hellwig
  2006-07-08 20:48 ` David Miller
@ 2006-07-10  6:06 ` Heiko Carstens
  2006-07-10  8:27   ` Martin Schwidefsky
  1 sibling, 1 reply; 4+ messages in thread
From: Heiko Carstens @ 2006-07-10  6:06 UTC (permalink / raw
  To: Christoph Hellwig; +Cc: akpm, davem, schwidefsky, linux-kernel

On Sat, Jul 08, 2006 at 08:05:54PM +0200, Christoph Hellwig wrote:
> Currently most architectures either always build binfmt_elf32 in the
> kernel image or make it a boolean option.  Only sparc64 and s390 allow
> to build it modularly.  This patch turns the option into a boolean
> aswell because elf requires various symbols that shouldn't be available
> to modules.  The most urgent one is tasklist_lock whos export this patch
> series kills, but there are others like force_sgi aswell.
> [...] 
> Index: linux-2.6/arch/s390/Kconfig
> ===================================================================
> --- linux-2.6.orig/arch/s390/Kconfig	2006-07-06 14:21:17.000000000 +0200
> +++ linux-2.6/arch/s390/Kconfig	2006-07-08 19:08:46.000000000 +0200
> @@ -119,7 +119,7 @@
>  	default y
>  
>  config BINFMT_ELF32
> -	tristate "Kernel support for 31 bit ELF binaries"
> +	bool "Kernel support for 31 bit ELF binaries"
>  	depends on COMPAT
>  	help

Martin and I discussed this already a few days ago. This config option
should go away on s390, since everybody who wants CONFIG_COMPAT also wants
CONFIG_BINFMT_ELF32. See patch below which applies on top of yours:

From: Heiko Carstens <heiko.carstens@de.ibm.com>

[PATCH] s390: remove BINFMT_ELF32 config option

Remove BINFMT_ELF32 config option. Support should be always compiled in
if CONFIG_COMPAT is set.

Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
---

 arch/s390/Kconfig         |    7 -------
 arch/s390/kernel/Makefile |    4 ++--
 2 files changed, 2 insertions(+), 9 deletions(-)

Index: linux-2.6/arch/s390/Kconfig
===================================================================
--- linux-2.6.orig/arch/s390/Kconfig
+++ linux-2.6/arch/s390/Kconfig
@@ -118,13 +118,6 @@ config SYSVIPC_COMPAT
 	depends on COMPAT && SYSVIPC
 	default y
 
-config BINFMT_ELF32
-	bool "Kernel support for 31 bit ELF binaries"
-	depends on COMPAT
-	help
-	  This allows you to run 32-bit Linux/ELF binaries on your zSeries
-	  in 64 bit mode. Everybody wants this; say Y.
-
 comment "Code generation options"
 
 choice
Index: linux-2.6/arch/s390/kernel/Makefile
===================================================================
--- linux-2.6.orig/arch/s390/kernel/Makefile
+++ linux-2.6/arch/s390/kernel/Makefile
@@ -17,8 +17,8 @@ obj-$(CONFIG_MODULES)		+= s390_ksyms.o m
 obj-$(CONFIG_SMP)		+= smp.o
 
 obj-$(CONFIG_COMPAT)		+= compat_linux.o compat_signal.o \
-					compat_wrapper.o compat_exec_domain.o
-obj-$(CONFIG_BINFMT_ELF32)	+= binfmt_elf32.o
+					compat_wrapper.o compat_exec_domain.o \
+					binfmt_elf32.o
 
 obj-$(CONFIG_VIRT_TIMER)	+= vtime.o
 obj-$(CONFIG_STACKTRACE)	+= stacktrace.o

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 2/3] disallow modular binfmt_elf32
  2006-07-10  6:06 ` Heiko Carstens
@ 2006-07-10  8:27   ` Martin Schwidefsky
  0 siblings, 0 replies; 4+ messages in thread
From: Martin Schwidefsky @ 2006-07-10  8:27 UTC (permalink / raw
  To: Heiko Carstens; +Cc: Christoph Hellwig, akpm, davem, linux-kernel

On Mon, 2006-07-10 at 08:06 +0200, Heiko Carstens wrote:
> On Sat, Jul 08, 2006 at 08:05:54PM +0200, Christoph Hellwig wrote:
> > Currently most architectures either always build binfmt_elf32 in the
> > kernel image or make it a boolean option.  Only sparc64 and s390 allow
> > to build it modularly.  This patch turns the option into a boolean
> > aswell because elf requires various symbols that shouldn't be available
> > to modules.  The most urgent one is tasklist_lock whos export this patch
> > series kills, but there are others like force_sgi aswell.
> > [...] 
> > Index: linux-2.6/arch/s390/Kconfig
> > ===================================================================
> > --- linux-2.6.orig/arch/s390/Kconfig	2006-07-06 14:21:17.000000000 +0200
> > +++ linux-2.6/arch/s390/Kconfig	2006-07-08 19:08:46.000000000 +0200
> > @@ -119,7 +119,7 @@
> >  	default y
> >  
> >  config BINFMT_ELF32
> > -	tristate "Kernel support for 31 bit ELF binaries"
> > +	bool "Kernel support for 31 bit ELF binaries"
> >  	depends on COMPAT
> >  	help
> 
> Martin and I discussed this already a few days ago. This config option
> should go away on s390, since everybody who wants CONFIG_COMPAT also wants
> CONFIG_BINFMT_ELF32. See patch below which applies on top of yours:

Yes, the removal of the BINFMT_ELF32 Kconfig option has been part of the
s390 Kconfig cleanup patch as well, it is supposed to go away.

-- 
blue skies,
  Martin.

Martin Schwidefsky
Linux for zSeries Development & Services
IBM Deutschland Entwicklung GmbH

"Reality continues to ruin my life." - Calvin.



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2006-07-10  8:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-08 18:05 [PATCH 2/3] disallow modular binfmt_elf32 Christoph Hellwig
2006-07-08 20:48 ` David Miller
2006-07-10  6:06 ` Heiko Carstens
2006-07-10  8:27   ` Martin Schwidefsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).