From: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
To: Adrian Bunk <bunk@stusta.de>
Cc: Andrew Morton <akpm@osdl.org>,
prasanna@in.ibm.com, anil.s.keshavamurthy@intel.com,
davem@davemloft.net, linux-kernel@vger.kernel.org
Subject: Re: [2.6 patch] kernel/kprobes.c: fix a warning #ifndef ARCH_SUPPORTS_KRETPROBES
Date: Thu, 19 Jan 2006 09:35:49 +0530 [thread overview]
Message-ID: <20060119040549.GA2326@in.ibm.com> (raw)
In-Reply-To: <20060119021154.GD19398@stusta.de>
On Thu, Jan 19, 2006 at 03:11:54AM +0100, Adrian Bunk wrote:
> This patch fixes the following warning #ifndef ARCH_SUPPORTS_KRETPROBES:
>
> <-- snip -->
>
> ...
> CC kernel/kprobes.o
> kernel/kprobes.c:353: warning: 'pre_handler_kretprobe' defined but not used
> ...
>
> <-- snip -->
>
>
> Signed-off-by: Adrian Bunk <bunk@stusta.de>
Acked-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Ananth
>
> ---
>
> This patch was already sent on:
> - 14 Jan 2006
>
> --- linux-2.6.15-mm4-sparc64/kernel/kprobes.c.old 2006-01-14 20:17:59.000000000 +0100
> +++ linux-2.6.15-mm4-sparc64/kernel/kprobes.c 2006-01-14 20:19:03.000000000 +0100
> @@ -344,23 +344,6 @@
> spin_unlock_irqrestore(&kretprobe_lock, flags);
> }
>
> -/*
> - * This kprobe pre_handler is registered with every kretprobe. When probe
> - * hits it will set up the return probe.
> - */
> -static int __kprobes pre_handler_kretprobe(struct kprobe *p,
> - struct pt_regs *regs)
> -{
> - struct kretprobe *rp = container_of(p, struct kretprobe, kp);
> - unsigned long flags = 0;
> -
> - /*TODO: consider to only swap the RA after the last pre_handler fired */
> - spin_lock_irqsave(&kretprobe_lock, flags);
> - arch_prepare_kretprobe(rp, regs);
> - spin_unlock_irqrestore(&kretprobe_lock, flags);
> - return 0;
> -}
> -
> static inline void free_rp_inst(struct kretprobe *rp)
> {
> struct kretprobe_instance *ri;
> @@ -578,6 +561,23 @@
>
> #ifdef ARCH_SUPPORTS_KRETPROBES
>
> +/*
> + * This kprobe pre_handler is registered with every kretprobe. When probe
> + * hits it will set up the return probe.
> + */
> +static int __kprobes pre_handler_kretprobe(struct kprobe *p,
> + struct pt_regs *regs)
> +{
> + struct kretprobe *rp = container_of(p, struct kretprobe, kp);
> + unsigned long flags = 0;
> +
> + /*TODO: consider to only swap the RA after the last pre_handler fired */
> + spin_lock_irqsave(&kretprobe_lock, flags);
> + arch_prepare_kretprobe(rp, regs);
> + spin_unlock_irqrestore(&kretprobe_lock, flags);
> + return 0;
> +}
> +
> int __kprobes register_kretprobe(struct kretprobe *rp)
> {
> int ret = 0;
>
next prev parent reply other threads:[~2006-01-19 4:06 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-19 2:11 [2.6 patch] kernel/kprobes.c: fix a warning #ifndef ARCH_SUPPORTS_KRETPROBES Adrian Bunk
2006-01-19 4:05 ` Ananth N Mavinakayanahalli [this message]
-- strict thread matches above, loose matches on Subject: below --
2006-01-19 16:18 Keshavamurthy, Anil S
2006-01-14 19:55 Adrian Bunk
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=20060119040549.GA2326@in.ibm.com \
--to=ananth@in.ibm.com \
--cc=akpm@osdl.org \
--cc=anil.s.keshavamurthy@intel.com \
--cc=bunk@stusta.de \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=prasanna@in.ibm.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;
as well as URLs for NNTP newsgroup(s).