]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
x86/alternatives: Make the x86nops[] symbol static
authorPavel Skripkin <paskripkin@gmail.com>
Thu, 6 May 2021 19:07:26 +0000 (22:07 +0300)
committerIngo Molnar <mingo@kernel.org>
Wed, 12 May 2021 10:22:56 +0000 (12:22 +0200)
Sparse says:

  arch/x86/kernel/alternative.c:78:21: warning: symbol 'x86nops' was not declared. Should it be static?

Since x86nops[] is not used outside this file, Sparse is right and it can be made static.

Signed-off-by: Pavel Skripkin <paskripkin@gmail.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/20210506190726.15575-1-paskripkin@gmail.com
arch/x86/kernel/alternative.c

index 6974b517449552c2725972263730ec6162b56936..75c752b0628c12a87fb6a455fa6e7a1d285060c3 100644 (file)
@@ -75,7 +75,7 @@ do {                                                                  \
        }                                                               \
 } while (0)
 
-const unsigned char x86nops[] =
+static const unsigned char x86nops[] =
 {
        BYTES_NOP1,
        BYTES_NOP2,