Skip to content

Commit 2afa90b

Browse files
committed
Merge tag 'objtool_urgent_for_v5.16_rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull objtool fixes from Borislav Petkov: - Prevent clang from reordering the reachable annotation in an inline asm statement without inputs - Fix objtool builds on non-glibc systems due to undefined __always_inline * tag 'objtool_urgent_for_v5.16_rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: compiler.h: Fix annotation macro misplacement with Clang uapi: Fix undefined __always_inline on non-glibc systems
2 parents 4386451 + dcce50e commit 2afa90b

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

include/linux/compiler.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,15 +121,15 @@ void ftrace_likely_update(struct ftrace_likely_data *f, int val,
121121
asm volatile(__stringify_label(c) ":\n\t" \
122122
".pushsection .discard.reachable\n\t" \
123123
".long " __stringify_label(c) "b - .\n\t" \
124-
".popsection\n\t"); \
124+
".popsection\n\t" : : "i" (c)); \
125125
})
126126
#define annotate_reachable() __annotate_reachable(__COUNTER__)
127127

128128
#define __annotate_unreachable(c) ({ \
129129
asm volatile(__stringify_label(c) ":\n\t" \
130130
".pushsection .discard.unreachable\n\t" \
131131
".long " __stringify_label(c) "b - .\n\t" \
132-
".popsection\n\t"); \
132+
".popsection\n\t" : : "i" (c)); \
133133
})
134134
#define annotate_unreachable() __annotate_unreachable(__COUNTER__)
135135

include/linux/instrumentation.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
asm volatile(__stringify(c) ": nop\n\t" \
1212
".pushsection .discard.instr_begin\n\t" \
1313
".long " __stringify(c) "b - .\n\t" \
14-
".popsection\n\t"); \
14+
".popsection\n\t" : : "i" (c)); \
1515
})
1616
#define instrumentation_begin() __instrumentation_begin(__COUNTER__)
1717

@@ -50,7 +50,7 @@
5050
asm volatile(__stringify(c) ": nop\n\t" \
5151
".pushsection .discard.instr_end\n\t" \
5252
".long " __stringify(c) "b - .\n\t" \
53-
".popsection\n\t"); \
53+
".popsection\n\t" : : "i" (c)); \
5454
})
5555
#define instrumentation_end() __instrumentation_end(__COUNTER__)
5656
#else

include/uapi/linux/byteorder/big_endian.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
#define __BIG_ENDIAN_BITFIELD
1010
#endif
1111

12+
#include <linux/stddef.h>
1213
#include <linux/types.h>
1314
#include <linux/swab.h>
1415

include/uapi/linux/byteorder/little_endian.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
#define __LITTLE_ENDIAN_BITFIELD
1010
#endif
1111

12+
#include <linux/stddef.h>
1213
#include <linux/types.h>
1314
#include <linux/swab.h>
1415

0 commit comments

Comments
 (0)