linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] x86/unwind: Make some variables static
@ 2020-04-13 14:47 Muchun Song
  2020-04-14  9:23 ` Miroslav Benes
  0 siblings, 1 reply; 2+ messages in thread
From: Muchun Song @ 2020-04-13 14:47 UTC (permalink / raw)
  To: tglx, mingo, bp, hpa, x86, mingo
  Cc: peterz, shile.zhang, linux-kernel, Muchun Song

The variables are local to the source and do not need to be
in global scope, so make them static.

Signed-off-by: Muchun Song <songmuchun@bytedance.com>
---
 arch/x86/kernel/unwind_orc.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/x86/kernel/unwind_orc.c b/arch/x86/kernel/unwind_orc.c
index e9cc182aa97ee..0dbabc469ce2d 100644
--- a/arch/x86/kernel/unwind_orc.c
+++ b/arch/x86/kernel/unwind_orc.c
@@ -16,11 +16,11 @@ extern struct orc_entry __start_orc_unwind[];
 extern struct orc_entry __stop_orc_unwind[];
 
 static DEFINE_MUTEX(sort_mutex);
-int *cur_orc_ip_table = __start_orc_unwind_ip;
-struct orc_entry *cur_orc_table = __start_orc_unwind;
+static int *cur_orc_ip_table = __start_orc_unwind_ip;
+static struct orc_entry *cur_orc_table = __start_orc_unwind;
 
-unsigned int lookup_num_blocks;
-bool orc_init;
+static unsigned int lookup_num_blocks;
+static bool orc_init;
 
 static inline unsigned long orc_ip(const int *ip)
 {
-- 
2.11.0


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

* Re: [PATCH] x86/unwind: Make some variables static
  2020-04-13 14:47 [PATCH] x86/unwind: Make some variables static Muchun Song
@ 2020-04-14  9:23 ` Miroslav Benes
  0 siblings, 0 replies; 2+ messages in thread
From: Miroslav Benes @ 2020-04-14  9:23 UTC (permalink / raw)
  To: Muchun Song
  Cc: tglx, mingo, bp, hpa, x86, mingo, peterz, shile.zhang, linux-kernel

On Mon, 13 Apr 2020, Muchun Song wrote:

> The variables are local to the source and do not need to be
> in global scope, so make them static.
> 
> Signed-off-by: Muchun Song <songmuchun@bytedance.com>
> ---
>  arch/x86/kernel/unwind_orc.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/arch/x86/kernel/unwind_orc.c b/arch/x86/kernel/unwind_orc.c
> index e9cc182aa97ee..0dbabc469ce2d 100644
> --- a/arch/x86/kernel/unwind_orc.c
> +++ b/arch/x86/kernel/unwind_orc.c
> @@ -16,11 +16,11 @@ extern struct orc_entry __start_orc_unwind[];
>  extern struct orc_entry __stop_orc_unwind[];
>  
>  static DEFINE_MUTEX(sort_mutex);
> -int *cur_orc_ip_table = __start_orc_unwind_ip;
> -struct orc_entry *cur_orc_table = __start_orc_unwind;
> +static int *cur_orc_ip_table = __start_orc_unwind_ip;
> +static struct orc_entry *cur_orc_table = __start_orc_unwind;
>  
> -unsigned int lookup_num_blocks;
> -bool orc_init;
> +static unsigned int lookup_num_blocks;
> +static bool orc_init;
>  
>  static inline unsigned long orc_ip(const int *ip)
>  {
> -- 

Already fixed in 
https://lore.kernel.org/lkml/63b5cab2e28b9c08854fc57f5b512a9ccf76ad95.1584033751.git.jpoimboe@redhat.com/

Thanks,
Miroslav

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

end of thread, other threads:[~2020-04-14  9:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-13 14:47 [PATCH] x86/unwind: Make some variables static Muchun Song
2020-04-14  9:23 ` Miroslav Benes

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