aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJian Cai <[email protected]>2020-07-14 16:30:21 -0700
committerThomas Gleixner <[email protected]>2020-07-16 17:25:09 +0200
commit6ee93f8df09c470da1a4af11e394c52d7b62418c (patch)
treeabb7da7932664cac251ad817628884ea1363d55d
parentbd87e6f6610aa96fde01ee6653e162213f7ec836 (diff)
x86/entry: Add compatibility with IAS
Clang's integrated assembler does not allow symbols with non-absolute values to be reassigned. Modify the interrupt entry loop macro to be compatible with IAS by using a label and an offset. Reported-by: Nick Desaulniers <[email protected]> Reported-by: Sedat Dilek <[email protected]> Suggested-by: Nick Desaulniers <[email protected]> Suggested-by: Brian Gerst <[email protected]> Suggested-by: Arvind Sankar <[email protected]> Signed-off-by: Jian Cai <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Tested-by: Sedat Dilek <[email protected]> # Link: https://github.com/ClangBuiltLinux/linux/issues/1043 Link: https://lkml.kernel.org/r/[email protected]
-rw-r--r--arch/x86/include/asm/idtentry.h14
1 files changed, 6 insertions, 8 deletions
diff --git a/arch/x86/include/asm/idtentry.h b/arch/x86/include/asm/idtentry.h
index f3d70830bf2a..5efaaed34eda 100644
--- a/arch/x86/include/asm/idtentry.h
+++ b/arch/x86/include/asm/idtentry.h
@@ -469,16 +469,15 @@ __visible noinstr void func(struct pt_regs *regs, \
.align 8
SYM_CODE_START(irq_entries_start)
vector=FIRST_EXTERNAL_VECTOR
- pos = .
.rept (FIRST_SYSTEM_VECTOR - FIRST_EXTERNAL_VECTOR)
UNWIND_HINT_IRET_REGS
+0 :
.byte 0x6a, vector
jmp asm_common_interrupt
nop
/* Ensure that the above is 8 bytes max */
- . = pos + 8
- pos=pos+8
- vector=vector+1
+ . = 0b + 8
+ vector = vector+1
.endr
SYM_CODE_END(irq_entries_start)
@@ -486,16 +485,15 @@ SYM_CODE_END(irq_entries_start)
.align 8
SYM_CODE_START(spurious_entries_start)
vector=FIRST_SYSTEM_VECTOR
- pos = .
.rept (NR_VECTORS - FIRST_SYSTEM_VECTOR)
UNWIND_HINT_IRET_REGS
+0 :
.byte 0x6a, vector
jmp asm_spurious_interrupt
nop
/* Ensure that the above is 8 bytes max */
- . = pos + 8
- pos=pos+8
- vector=vector+1
+ . = 0b + 8
+ vector = vector+1
.endr
SYM_CODE_END(spurious_entries_start)
#endif