From: Anton Blanchard <anton@samba.org>
To: ananth@in.ibm.com, akpm@osdl.org
Cc: paulus@samba.org, linux-kernel@vger.kernel.org
Subject: [PATCH] ppc64: kprobes breaks BUG() handling
Date: Mon, 10 Jan 2005 22:19:37 +1100 [thread overview]
Message-ID: <20050110111937.GN14239@krispykreme.ozlabs.ibm.com> (raw)
Hi,
I was running some tests and noticed BUG() handling wasnt working as
expected. The kprobes code has some code to check for breakpoint
removal races and only checks for one opcode. It turns out there are
many forms of the breakpoint instruction, comparing against one is not
good enough.
For the momemt remove the code in question so BUG()s work again and we
can discuss a better solution (I thought kprobes was emulating
instructions or running them out of line).
Anton
Signed-off-by: Anton Blanchard <anton@samba.org>
diff -puN arch/ppc64/kernel/kprobes.c~fix_breakage arch/ppc64/kernel/kprobes.c
--- foobar2/arch/ppc64/kernel/kprobes.c~fix_breakage 2005-01-10 21:41:43.157624895 +1100
+++ foobar2-anton/arch/ppc64/kernel/kprobes.c 2005-01-10 21:42:04.560169990 +1100
@@ -99,6 +99,7 @@ static inline int kprobe_handler(struct
p = get_kprobe(addr);
if (!p) {
unlock_kprobes();
+#if 0
if (*addr != BREAKPOINT_INSTRUCTION) {
/*
* The breakpoint instruction was removed right
@@ -109,6 +110,7 @@ static inline int kprobe_handler(struct
*/
ret = 1;
}
+#endif
/* Not one of ours: let kernel handle it */
goto no_kprobe;
}
_
next reply other threads:[~2005-01-10 11:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-10 11:19 Anton Blanchard [this message]
2005-01-10 12:38 ` [PATCH] ppc64: kprobes breaks BUG() handling Ananth N Mavinakayanahalli
2005-01-12 11:30 ` Ananth N Mavinakayanahalli
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=20050110111937.GN14239@krispykreme.ozlabs.ibm.com \
--to=anton@samba.org \
--cc=akpm@osdl.org \
--cc=ananth@in.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=paulus@samba.org \
/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;
as well as URLs for NNTP newsgroup(s).