]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
cross-arch: don't corrupt personality flags upon exec()
authorJiri Kosina <jkosina@suse.cz>
Fri, 28 Sep 2012 00:20:11 +0000 (10:20 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 3 Oct 2012 06:50:39 +0000 (16:50 +1000)
commitcc0370cf582d4b6302fe295d71d8af193d3898e9
tree3e08b621aa3e8446d3f8218f1ed9de8eea0a6179
parenta6f676c32116d1a3ef544ec127990f3071eebec2
cross-arch: don't corrupt personality flags upon exec()

Historically, the top three bytes of personality have been used for things
such as ADDR_NO_RANDOMIZE, which made sense only for specific
architectures.

We now however have a flag there that is general no matter the
architecture (UNAME26); generally we have to be careful to preserve the
personality flags across exec().

This patch tries to fix all architectures that forcefully overwrite
personality flags during exec() (ppc32 and s390 have been fixed recently
by commits f9783ec86 and 59e4c3a2f in a similar way already).

Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no>
Cc: Mike Frysinger <vapier@gentoo.org>
Cc: Mark Salter <msalter@redhat.com>
Cc: Mikael Starvik <starvik@axis.com>
Cc: Jesper Nilsson <jesper.nilsson@axis.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Cc: Richard Kuo <rkuo@codeaurora.org>
Cc: Hirokazu Takata <takata@linux-m32r.org>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Michal Simek <monstr@monstr.eu>
Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
Cc: Jonas Bonn <jonas@southpole.se>
Cc: Chen Liqin <liqin.chen@sunplusct.com>
Cc: Lennox Wu <lennox.wu@gmail.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Chris Zankel <chris@zankel.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
16 files changed:
arch/avr32/include/asm/elf.h
arch/blackfin/include/asm/elf.h
arch/c6x/include/asm/elf.h
arch/cris/include/asm/elf.h
arch/frv/include/asm/elf.h
arch/h8300/include/asm/elf.h
arch/hexagon/include/asm/elf.h
arch/m32r/include/asm/elf.h
arch/m68k/include/asm/elf.h
arch/microblaze/include/asm/elf.h
arch/mn10300/include/asm/elf.h
arch/openrisc/include/asm/elf.h
arch/score/include/asm/elf.h
arch/sh/include/asm/elf.h
arch/sparc/include/asm/elf_32.h
arch/xtensa/include/asm/elf.h