From: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
To: Masami Hiramatsu <mhiramat@redhat.com>
Cc: akpm@linux-foundation.org, mm-commits@vger.kernel.org,
anil.s.keshavamurthy@intel.com,
Jim Keniston <jkenisto@us.ibm.com>,
systemtap-ml <systemtap@sources.redhat.com>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH -mm] bugfix: pass aggr_kprobe to arch_remove_kprobe
Date: Wed, 19 Nov 2008 10:01:21 +0530 [thread overview]
Message-ID: <20081119043121.GB4053@in.ibm.com> (raw)
In-Reply-To: <4922ED4D.8070201@redhat.com>
On Tue, Nov 18, 2008 at 11:29:01AM -0500, Masami Hiramatsu wrote:
> Hi Andrew,
>
> akpm@linux-foundation.org wrote:
> > The patch titled
> > kprobes: support probing module __exit function
> > has been added to the -mm tree. Its filename is
> > kprobes-support-probing-module-__exit-function.patch
>
> I found that one bug was still alive. Here is the bugfix.
>
> Thank you,
>
> Call arch_remove_kprobe() with aggr_kprobe instead of user specific kprobe,
> because the user specific kprobe on the gone or reused aggr_kprobe may have
> invalid arch_specific_insn.
>
> Signed-off-by: Masami Hiramatsu <mhiramat@redhat.com>
> Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Acked-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
> ---
> kernel/kprobes.c | 14 +++++++-------
> 1 file changed, 7 insertions(+), 7 deletions(-)
>
> Index: 2.6-rc/kernel/kprobes.c
> ===================================================================
> --- 2.6-rc.orig/kernel/kprobes.c
> +++ 2.6-rc/kernel/kprobes.c
> @@ -766,14 +766,14 @@ static void __kprobes __unregister_kprob
> {
> struct kprobe *old_p;
>
> - if (list_empty(&p->list) || list_is_singular(&p->list)) {
> - if (!list_empty(&p->list)) {
> - /* "p" is the last child of an aggr_kprobe */
> - old_p = list_entry(p->list.next, struct kprobe, list);
> - list_del(&p->list);
> - kfree(old_p);
> - }
> + if (list_empty(&p->list))
> arch_remove_kprobe(p);
> + else if (list_is_singular(&p->list)) {
> + /* "p" is the last child of an aggr_kprobe */
> + old_p = list_entry(p->list.next, struct kprobe, list);
> + list_del(&p->list);
> + arch_remove_kprobe(old_p);
> + kfree(old_p);
> }
> }
>
>
> --
> Masami Hiramatsu
>
> Software Engineer
> Hitachi Computer Products (America) Inc.
> Software Solutions Division
>
> e-mail: mhiramat@redhat.com
>
prev parent reply other threads:[~2008-11-19 4:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200811140028.mAE0SppC021444@imap1.linux-foundation.org>
2008-11-18 16:29 ` [PATCH -mm] bugfix: pass aggr_kprobe to arch_remove_kprobe Masami Hiramatsu
2008-11-19 4:31 ` Ananth N Mavinakayanahalli [this message]
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=20081119043121.GB4053@in.ibm.com \
--to=ananth@in.ibm.com \
--cc=akpm@linux-foundation.org \
--cc=anil.s.keshavamurthy@intel.com \
--cc=jkenisto@us.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mhiramat@redhat.com \
--cc=mm-commits@vger.kernel.org \
--cc=systemtap@sources.redhat.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