From: castet.matthieu@free.fr
To: Siarhei Liakh <sliakh.lkml@gmail.com>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [tip:x86/mm] x86, mm: NX protection for kernel data
Date: Tue, 02 Mar 2010 17:23:33 +0100 [thread overview]
Message-ID: <1267547013.4b8d3b8596461@imp.free.fr> (raw)
[-- Attachment #1: Type: text/plain, Size: 303 bytes --]
> At this point I need some help and guidance on how to track down what
> exactly happens there, as I am not very familiar with what goes into
> .data and why are we trying to execute it.
Can't you add debug printk in the fault handler before any exception processing
Something like that.
Matthieu
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: test.diff --]
[-- Type: text/x-diff; name="test.diff", Size: 401 bytes --]
diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c
index f627779..578ba52 100644
--- a/arch/x86/mm/fault.c
+++ b/arch/x86/mm/fault.c
@@ -629,6 +629,8 @@ no_context(struct pt_regs *regs, unsigned long error_code,
unsigned long flags;
int sig;
+ if (error_code & PF_INSTR)
+ printk("exec on NX\n");
/* Are we prepared to handle this kernel fault? */
if (fixup_exception(regs))
return;
next reply other threads:[~2010-03-02 16:23 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-02 16:23 castet.matthieu [this message]
2010-03-02 17:51 ` Siarhei Liakh
2010-03-02 18:03 ` Siarhei Liakh
-- strict thread matches above, loose matches on Subject: below --
2010-03-13 12:12 matthieu castet
2010-03-15 18:20 ` Siarhei Liakh
2010-03-15 21:40 ` Siarhei Liakh
2010-01-31 23:27 [PATCH V6] x86: " Siarhei Liakh
2010-02-17 19:51 ` [tip:x86/mm] x86, mm: " tip-bot for Siarhei Liakh
2010-02-22 10:54 ` Ingo Molnar
2010-02-22 11:01 ` Ingo Molnar
2010-02-22 17:19 ` H. Peter Anvin
2010-02-22 17:21 ` Ingo Molnar
2010-03-06 19:44 ` Siarhei Liakh
2010-03-10 13:32 ` Ingo Molnar
2010-03-10 15:06 ` Siarhei Liakh
2010-03-12 3:12 ` Siarhei Liakh
2010-03-02 15:13 ` Siarhei Liakh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1267547013.4b8d3b8596461@imp.free.fr \
--to=castet.matthieu@free.fr \
--cc=linux-kernel@vger.kernel.org \
--cc=sliakh.lkml@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®