summaryrefslogtreecommitdiff
path: root/arch/x86/kernel
diff options
context:
space:
mode:
authorArjan van de Ven <arjan@linux.intel.com>2008-02-06 21:39:45 (GMT)
committerIngo Molnar <mingo@elte.hu>2008-02-06 21:39:45 (GMT)
commit984bb80d94d891592ab16d4d129b988792752c7b (patch)
treeefc22a5eb3e3cf05b056bedcbe48bbdb48b99ad8 /arch/x86/kernel
parenta57dae3aa4d00a000b5bac4238025438204c78b2 (diff)
downloadlinux-fsl-qoriq-984bb80d94d891592ab16d4d129b988792752c7b.tar.xz
x86: mark the .rodata section also NX
The .rodata section shouldn't just be read-only, but also non-executable. This is free since we've broken up the 2MB page already anyway. also update test_nx to check for this. Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r--arch/x86/kernel/test_nx.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/test_nx.c b/arch/x86/kernel/test_nx.c
index 36c100c..10b8a6f 100644
--- a/arch/x86/kernel/test_nx.c
+++ b/arch/x86/kernel/test_nx.c
@@ -139,7 +139,6 @@ static int test_NX(void)
* Until then, don't run them to avoid too many people getting scared
* by the error message
*/
-#if 0
#ifdef CONFIG_DEBUG_RODATA
/* Test 3: Check if the .rodata section is executable */
@@ -152,6 +151,7 @@ static int test_NX(void)
}
#endif
+#if 0
/* Test 4: Check if the .data section of a module is executable */
if (test_address(&test_data)) {
printk(KERN_ERR "test_nx: .data section is executable\n");