linux-mips
[Top] [All Lists]

Re: [PATCH] UPROBES: Remove useless __weak attribute

To: Ralf Baechle <ralf@linux-mips.org>
Subject: Re: [PATCH] UPROBES: Remove useless __weak attribute
From: Oleg Nesterov <oleg@redhat.com>
Date: Thu, 10 Oct 2013 13:43:14 +0200
Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com>, Anton Arapov <anton@redhat.com>, Ananth N Mavinakayanahalli <ananth@in.ibm.com>, linux-kernel@vger.kernel.org, linux-mips@linux-mips.org
In-reply-to: <20131009120809.GN1615@linux-mips.org>
List-archive: <http://www.linux-mips.org/archives/linux-mips/>
List-help: <mailto:ecartis@linux-mips.org?Subject=help>
List-id: linux-mips <linux-mips.eddie.linux-mips.org>
List-owner: <mailto:ralf@linux-mips.org>
List-post: <mailto:linux-mips@linux-mips.org>
List-software: Ecartis version 1.0.0
List-subscribe: <mailto:ecartis@linux-mips.org?subject=subscribe%20linux-mips>
List-unsubscribe: <mailto:ecartis@linux-mips.org?subject=unsubscribe%20linux-mips>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <20131009120809.GN1615@linux-mips.org>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.5.18 (2008-05-17)
On 10/09, Ralf Baechle wrote:
>
> <linux/uprobes.h> declares arch_uprobe_skip_sstep() as a weak function.
> But as there is no definition of generic version so when trying to build
> uprobes for an architecture that doesn't yet have a arch_uprobe_skip_sstep()
> implementation, the vmlinux will try to call arch_uprobe_skip_sstep()
> somehwere in Stupidhistan leading to a system crash.  We rather want a
> proper link error so remove arch_uprobe_skip_sstep().
> 
> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
> 
>  include/linux/uprobes.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/linux/uprobes.h b/include/linux/uprobes.h
> index 2a9d75d..cec7397 100644
> --- a/include/linux/uprobes.h
> +++ b/include/linux/uprobes.h
> @@ -124,7 +124,7 @@ extern int uprobe_post_sstep_notifier(struct pt_regs 
> *regs);
>  extern int uprobe_pre_sstep_notifier(struct pt_regs *regs);
>  extern void uprobe_notify_resume(struct pt_regs *regs);
>  extern bool uprobe_deny_signal(void);
> -extern bool __weak arch_uprobe_skip_sstep(struct arch_uprobe *aup, struct 
> pt_regs *regs);
> +extern bool arch_uprobe_skip_sstep(struct arch_uprobe *aup, struct pt_regs 
> *regs);

Agreed. I'll take this patch, thanks.

Oleg.


<Prev in Thread] Current Thread [Next in Thread>