Skip to contentSkip to conversation

x86: jump_label.c: move 'inline' keyword placement

PATCH Applied Randy Dunlap 2 participants 2 messages Mar 26, 2020 – Mar 27, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 x86: jump_label.c: move 'inline' keyword placement

From: Randy Dunlap <[email protected]>

Fix gcc warning when -Wextra is used by moving the keyword:

../arch/x86/kernel/jump_label.c:61:1: warning: ‘inline’ is not at beginning of declaration [-Wold-style-declaration]
static void inline __jump_label_transform(struct jump_entry *entry,
^~~~~~

---
v2: use Reported-by:

 arch/x86/kernel/jump_label.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/kernel/jump_label.c +1 -1
@@ -58,7 +58,7 @@ __jump_label_set_jump_code(struct jump_e
 	return code;
 }
 
-static void inline __jump_label_transform(struct jump_entry *entry,
+static inline void __jump_label_transform(struct jump_entry *entry,
 					  enum jump_label_type type,
 					  int init)
 {
merge bot Applied
#1 lore raw

[tip: x86/cleanups] x86/jump_label: Move 'inline' keyword placement

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

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

Commit-ID:     4de4952c0abcb490039cdc946e49ed7f237285a2
Gitweb:        https://git.kernel.org/tip/4de4952c0abcb490039cdc946e49ed7f237285a2
Author:        Randy Dunlap <[email protected]>
AuthorDate:    Thu, 26 Mar 2020 14:16:58 -07:00
Committer:     Borislav Petkov <[email protected]>
CommitterDate: Fri, 27 Mar 2020 11:05:41 +01:00

x86/jump_label: Move 'inline' keyword placement

Fix gcc warning when -Wextra is used by moving the keyword:

arch/x86/kernel/jump_label.c:61:1: warning: ‘inline’ is not at \
beginning of declaration [-Wold-style-declaration]
static void inline __jump_label_transform(struct jump_entry *entry, ^~~~~~

---
 arch/x86/kernel/jump_label.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/kernel/jump_label.c +1 -1
index 9c4498e..5ba8477 100644
@@ -58,7 +58,7 @@ __jump_label_set_jump_code(struct jump_entry *entry, enum jump_label_type type, 
 	return code;
 }
 
-static void inline __jump_label_transform(struct jump_entry *entry,
+static inline void __jump_label_transform(struct jump_entry *entry,
 					  enum jump_label_type type,
 					  int init)
 {