kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] kprobes/x86: remove extern from function definition
@ 2012-03-03 16:12 Emil Goode
  2012-03-05  2:55 ` Masami Hiramatsu
  0 siblings, 1 reply; 2+ messages in thread
From: Emil Goode @ 2012-03-03 16:12 UTC (permalink / raw)
  To: kernel-janitors

Functions with definition should not be declared extern.

sparse warns:
arch/x86/kernel/kprobes.c:1489:13: warning:
     function 'arch_unoptimize_kprobes' with external linkage
     has definition

Signed-off-by: Emil Goode <emilgoode@gmail.com>
---
 arch/x86/kernel/kprobes.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/x86/kernel/kprobes.c b/arch/x86/kernel/kprobes.c
index 7da647d..f55c28e 100644
--- a/arch/x86/kernel/kprobes.c
+++ b/arch/x86/kernel/kprobes.c
@@ -1486,8 +1486,8 @@ static void __kprobes setup_unoptimize_kprobe(struct text_poke_param *tprm,
  * Recover original instructions and breakpoints from relative jumps.
  * Caller must call with locking kprobe_mutex.
  */
-extern void arch_unoptimize_kprobes(struct list_head *oplist,
-				    struct list_head *done_list)
+void arch_unoptimize_kprobes(struct list_head *oplist,
+			     struct list_head *done_list)
 {
 	struct optimized_kprobe *op, *tmp;
 	int c = 0;
-- 
1.7.9.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] kprobes/x86: remove extern from function definition
  2012-03-03 16:12 [PATCH] kprobes/x86: remove extern from function definition Emil Goode
@ 2012-03-05  2:55 ` Masami Hiramatsu
  0 siblings, 0 replies; 2+ messages in thread
From: Masami Hiramatsu @ 2012-03-05  2:55 UTC (permalink / raw)
  To: kernel-janitors

(2012/03/04 1:12), Emil Goode wrote:
> Functions with definition should not be declared extern.
> 
> sparse warns:
> arch/x86/kernel/kprobes.c:1489:13: warning:
>      function 'arch_unoptimize_kprobes' with external linkage
>      has definition
> 
> Signed-off-by: Emil Goode <emilgoode@gmail.com>

Acked-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>

Thank you!

> ---
>  arch/x86/kernel/kprobes.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/x86/kernel/kprobes.c b/arch/x86/kernel/kprobes.c
> index 7da647d..f55c28e 100644
> --- a/arch/x86/kernel/kprobes.c
> +++ b/arch/x86/kernel/kprobes.c
> @@ -1486,8 +1486,8 @@ static void __kprobes setup_unoptimize_kprobe(struct text_poke_param *tprm,
>   * Recover original instructions and breakpoints from relative jumps.
>   * Caller must call with locking kprobe_mutex.
>   */
> -extern void arch_unoptimize_kprobes(struct list_head *oplist,
> -				    struct list_head *done_list)
> +void arch_unoptimize_kprobes(struct list_head *oplist,
> +			     struct list_head *done_list)
>  {
>  	struct optimized_kprobe *op, *tmp;
>  	int c = 0;


-- 
Masami HIRAMATSU
Software Platform Research Dept. Linux Technology Center
Hitachi, Ltd., Yokohama Research Laboratory
E-mail: masami.hiramatsu.pt@hitachi.com

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-03-05  2:55 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-03 16:12 [PATCH] kprobes/x86: remove extern from function definition Emil Goode
2012-03-05  2:55 ` Masami Hiramatsu

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).