linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: build warning after merge of the tip tree
@ 2020-04-28  6:29 Stephen Rothwell
  2020-04-28  7:16 ` [PATCH] x86/unwind/orc: Move ORC sorting variables under CONFIG_MODULE Josh Poimboeuf
  0 siblings, 1 reply; 4+ messages in thread
From: Stephen Rothwell @ 2020-04-28  6:29 UTC (permalink / raw)
  To: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, Peter Zijlstra
  Cc: Linux Next Mailing List, Linux Kernel Mailing List, Josh Poimboeuf

[-- Attachment #1: Type: text/plain, Size: 709 bytes --]

Hi all,

After merging the tip tree, today's linux-next build (x86_64 allnoconfig)
produced this warning:

arch/x86/kernel/unwind_orc.c:29:26: warning: 'cur_orc_table' defined but not used [-Wunused-variable]
   29 | static struct orc_entry *cur_orc_table = __start_orc_unwind;
      |                          ^~~~~~~~~~~~~
arch/x86/kernel/unwind_orc.c:28:13: warning: 'cur_orc_ip_table' defined but not used [-Wunused-variable]
   28 | static int *cur_orc_ip_table = __start_orc_unwind_ip;
      |             ^~~~~~~~~~~~~~~~

Exposed by commit

  153eb2223c79 ("x86/unwind/orc: Convert global variables to static")

This build has CONFIG_MODULE not set.

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

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

* [PATCH] x86/unwind/orc: Move ORC sorting variables under CONFIG_MODULE
  2020-04-28  6:29 linux-next: build warning after merge of the tip tree Stephen Rothwell
@ 2020-04-28  7:16 ` Josh Poimboeuf
  2020-04-28  7:20   ` Josh Poimboeuf
  2020-05-03 11:29   ` [tip: x86/urgent] x86/unwind/orc: Move ORC sorting variables under !CONFIG_MODULES tip-bot2 for Josh Poimboeuf
  0 siblings, 2 replies; 4+ messages in thread
From: Josh Poimboeuf @ 2020-04-28  7:16 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, Peter Zijlstra,
	Linux Next Mailing List, Linux Kernel Mailing List

Fix the following warnings seen with !CONFIG_MODULE:

  arch/x86/kernel/unwind_orc.c:29:26: warning: 'cur_orc_table' defined but not used [-Wunused-variable]
     29 | static struct orc_entry *cur_orc_table = __start_orc_unwind;
        |                          ^~~~~~~~~~~~~
  arch/x86/kernel/unwind_orc.c:28:13: warning: 'cur_orc_ip_table' defined but not used [-Wunused-variable]
     28 | static int *cur_orc_ip_table = __start_orc_unwind_ip;
        |             ^~~~~~~~~~~~~~~~

Fixes: 153eb2223c79 ("x86/unwind/orc: Convert global variables to static")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.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 0ebc11a8bb45..5b0bd8581fe6 100644
--- a/arch/x86/kernel/unwind_orc.c
+++ b/arch/x86/kernel/unwind_orc.c
@@ -24,10 +24,6 @@ extern struct orc_entry __stop_orc_unwind[];
 static bool orc_init __ro_after_init;
 static unsigned int lookup_num_blocks __ro_after_init;
 
-static DEFINE_MUTEX(sort_mutex);
-static int *cur_orc_ip_table = __start_orc_unwind_ip;
-static struct orc_entry *cur_orc_table = __start_orc_unwind;
-
 static inline unsigned long orc_ip(const int *ip)
 {
 	return (unsigned long)ip + *ip;
@@ -192,6 +188,10 @@ static struct orc_entry *orc_find(unsigned long ip)
 
 #ifdef CONFIG_MODULES
 
+static DEFINE_MUTEX(sort_mutex);
+static int *cur_orc_ip_table = __start_orc_unwind_ip;
+static struct orc_entry *cur_orc_table = __start_orc_unwind;
+
 static void orc_sort_swap(void *_a, void *_b, int size)
 {
 	struct orc_entry *orc_a, *orc_b;
-- 
2.21.1


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

* Re: [PATCH] x86/unwind/orc: Move ORC sorting variables under CONFIG_MODULE
  2020-04-28  7:16 ` [PATCH] x86/unwind/orc: Move ORC sorting variables under CONFIG_MODULE Josh Poimboeuf
@ 2020-04-28  7:20   ` Josh Poimboeuf
  2020-05-03 11:29   ` [tip: x86/urgent] x86/unwind/orc: Move ORC sorting variables under !CONFIG_MODULES tip-bot2 for Josh Poimboeuf
  1 sibling, 0 replies; 4+ messages in thread
From: Josh Poimboeuf @ 2020-04-28  7:20 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, Peter Zijlstra,
	Linux Next Mailing List, Linux Kernel Mailing List

On Tue, Apr 28, 2020 at 02:16:43AM -0500, Josh Poimboeuf wrote:
> Fix the following warnings seen with !CONFIG_MODULE:

s/MODULE/MODULES/ here and $SUBJECT.

-- 
Josh


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

* [tip: x86/urgent] x86/unwind/orc: Move ORC sorting variables under !CONFIG_MODULES
  2020-04-28  7:16 ` [PATCH] x86/unwind/orc: Move ORC sorting variables under CONFIG_MODULE Josh Poimboeuf
  2020-04-28  7:20   ` Josh Poimboeuf
@ 2020-05-03 11:29   ` tip-bot2 for Josh Poimboeuf
  1 sibling, 0 replies; 4+ messages in thread
From: tip-bot2 for Josh Poimboeuf @ 2020-05-03 11:29 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: Stephen Rothwell, Josh Poimboeuf, Ingo Molnar, H. Peter Anvin,
	Linux Next Mailing List, Peter Zijlstra, Thomas Gleixner, x86,
	LKML

The following commit has been merged into the x86/urgent branch of tip:

Commit-ID:     fb9cbbc895eb6e986dc90c928a35c793d75f435a
Gitweb:        https://git.kernel.org/tip/fb9cbbc895eb6e986dc90c928a35c793d75f435a
Author:        Josh Poimboeuf <jpoimboe@redhat.com>
AuthorDate:    Tue, 28 Apr 2020 02:16:40 -05:00
Committer:     Ingo Molnar <mingo@kernel.org>
CommitterDate: Sun, 03 May 2020 13:23:28 +02:00

x86/unwind/orc: Move ORC sorting variables under !CONFIG_MODULES

Fix the following warnings seen with !CONFIG_MODULES:

  arch/x86/kernel/unwind_orc.c:29:26: warning: 'cur_orc_table' defined but not used [-Wunused-variable]
     29 | static struct orc_entry *cur_orc_table = __start_orc_unwind;
        |                          ^~~~~~~~~~~~~
  arch/x86/kernel/unwind_orc.c:28:13: warning: 'cur_orc_ip_table' defined but not used [-Wunused-variable]
     28 | static int *cur_orc_ip_table = __start_orc_unwind_ip;
        |             ^~~~~~~~~~~~~~~~

Fixes: 153eb2223c79 ("x86/unwind/orc: Convert global variables to static")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Linux Next Mailing List <linux-next@vger.kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/r/20200428071640.psn5m7eh3zt2in4v@treble
---
 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 0ebc11a..5b0bd85 100644
--- a/arch/x86/kernel/unwind_orc.c
+++ b/arch/x86/kernel/unwind_orc.c
@@ -24,10 +24,6 @@ extern struct orc_entry __stop_orc_unwind[];
 static bool orc_init __ro_after_init;
 static unsigned int lookup_num_blocks __ro_after_init;
 
-static DEFINE_MUTEX(sort_mutex);
-static int *cur_orc_ip_table = __start_orc_unwind_ip;
-static struct orc_entry *cur_orc_table = __start_orc_unwind;
-
 static inline unsigned long orc_ip(const int *ip)
 {
 	return (unsigned long)ip + *ip;
@@ -192,6 +188,10 @@ static struct orc_entry *orc_find(unsigned long ip)
 
 #ifdef CONFIG_MODULES
 
+static DEFINE_MUTEX(sort_mutex);
+static int *cur_orc_ip_table = __start_orc_unwind_ip;
+static struct orc_entry *cur_orc_table = __start_orc_unwind;
+
 static void orc_sort_swap(void *_a, void *_b, int size)
 {
 	struct orc_entry *orc_a, *orc_b;

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

end of thread, other threads:[~2020-05-03 11:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-28  6:29 linux-next: build warning after merge of the tip tree Stephen Rothwell
2020-04-28  7:16 ` [PATCH] x86/unwind/orc: Move ORC sorting variables under CONFIG_MODULE Josh Poimboeuf
2020-04-28  7:20   ` Josh Poimboeuf
2020-05-03 11:29   ` [tip: x86/urgent] x86/unwind/orc: Move ORC sorting variables under !CONFIG_MODULES tip-bot2 for Josh Poimboeuf

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