All of lore.kernel.org
 help / color / mirror / Atom feed
* bug(?): SET_PERSONALITY 2.4.18-rc3
@ 2002-02-22  2:50 Tom Gall
  2002-02-22  6:00 ` David S. Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Tom Gall @ 2002-02-22  2:50 UTC (permalink / raw)
  To: linux-kernel, marcelo

Greetings,

While getting 2.4.18-rc[1|2] up and running on ppc64 the following bug
surfaced. Least I think it's a bug. You be the judge. If it's not, we'd
kinda like to know why not.

in fs/binfmt_elf.c I believe the following patch appears to be needed

------8<----------8<--------------------
diff -urN linuxppc64_2_4.bld-rc.borked/fs/binfmt_elf.c
linuxppc64_2_4.bld-rc/fs/binfmt_elf.c
--- linuxppc64_2_4.bld-rc.borked/fs/binfmt_elf.c        Wed Feb 20
13:32:56 2002
+++ linuxppc64_2_4.bld-rc/fs/binfmt_elf.c       Thu Feb 21 17:27:04 2002
@@ -568,6 +565,9 @@
			// printk(KERN_WARNING "ELF: Ambiguous type, using ELF\n");
			interpreter_type = INTERPRETER_ELF;
		}
+	} else {
+		/* Executables without an interpreter also need a personality  */
+		SET_PERSONALITY(elf_ex, ibcs2_interpreter);
	}

	/* OK, we are done with that, now set up the arg stuff,
----8<-------------8<------------------

otherwise a static application would be run without SET_PERSONALITY
being called, which On ppc64, very quickly leads to a bad day.

Regards,

Tom

-- 
Tom Gall - [embedded] [PPC64 | PPC32] Code Monkey
Peace, Love &                  "Where's the ka-boom? There was
Linux Technology Center         supposed to be an earth
http://www.ibm.com/linux/ltc/   shattering ka-boom!"
(w) tom_gall@vnet.ibm.com       -- Marvin Martian
(w) 507-253-4558
(h) tgall@rochcivictheatre.org

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

* Re: bug(?): SET_PERSONALITY 2.4.18-rc3
  2002-02-22  2:50 bug(?): SET_PERSONALITY 2.4.18-rc3 Tom Gall
@ 2002-02-22  6:00 ` David S. Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David S. Miller @ 2002-02-22  6:00 UTC (permalink / raw)
  To: tom_gall; +Cc: linux-kernel, marcelo

   From: Tom Gall <tom_gall@vnet.ibm.com>
   Date: Thu, 21 Feb 2002 20:50:08 -0600
   
   otherwise a static application would be run without SET_PERSONALITY
   being called, which On ppc64, very quickly leads to a bad day.

This is also breaking static 32-bit apps on sparc64.
Thanks for finding this.

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

end of thread, other threads:[~2002-02-22  6:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-02-22  2:50 bug(?): SET_PERSONALITY 2.4.18-rc3 Tom Gall
2002-02-22  6:00 ` David S. Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.