From b11bbd30c24e45af44fce6b6a57ed1f27976b4e3 Mon Sep 17 00:00:00 2001 From: Norman Feske Date: Wed, 8 Feb 2012 19:30:55 +0100 Subject: [PATCH] Work-around of running Genode with PaX enabled Thanks to Torsten Hilbrich for reporting. Fixes #91. --- base-linux/src/platform/x86_32/lx_syscall.S | 6 ++++++ base-linux/src/platform/x86_64/lx_restore_rt.S | 7 +++++++ base-linux/src/platform/x86_64/lx_syscall.S | 7 +++++++ 3 files changed, 20 insertions(+) diff --git a/base-linux/src/platform/x86_32/lx_syscall.S b/base-linux/src/platform/x86_32/lx_syscall.S index fccc9c05a8..b53664c369 100644 --- a/base-linux/src/platform/x86_32/lx_syscall.S +++ b/base-linux/src/platform/x86_32/lx_syscall.S @@ -75,3 +75,9 @@ L(pseudo_end): .cfi_endproc +/* + * Allow stacks to be mapped executable (needed because Genode does not + * offer an API to handle non-execute mappings yet). + */ +.section .note.GNU-stack, "", @progbits + diff --git a/base-linux/src/platform/x86_64/lx_restore_rt.S b/base-linux/src/platform/x86_64/lx_restore_rt.S index 9297c94356..a7a24d5648 100644 --- a/base-linux/src/platform/x86_64/lx_restore_rt.S +++ b/base-linux/src/platform/x86_64/lx_restore_rt.S @@ -14,3 +14,10 @@ lx_restore_rt: movq $SYS_rt_sigreturn, %rax syscall + +/* + * Allow stacks to be mapped executable (needed because Genode does not + * offer an API to handle non-execute mappings yet). + */ +.section .note.GNU-stack, "", @progbits + diff --git a/base-linux/src/platform/x86_64/lx_syscall.S b/base-linux/src/platform/x86_64/lx_syscall.S index 47b008a887..a74d2d0223 100644 --- a/base-linux/src/platform/x86_64/lx_syscall.S +++ b/base-linux/src/platform/x86_64/lx_syscall.S @@ -27,3 +27,10 @@ lx_syscall: syscall /* Do the system call. */ L(pseudo_end): ret /* Return to caller. */ + +/* + * Allow stacks to be mapped executable (needed because Genode does not + * offer an API to handle non-execute mappings yet). + */ +.section .note.GNU-stack, "", @progbits +