Skip to content

Commit f2c6c22

Browse files
nathanchancetsbogend
authored andcommitted
MIPS: Loongson64: Use three arguments for slti
LLVM's integrated assembler does not support 'slti <reg>, <imm>': <instantiation>:16:12: error: invalid operand for instruction slti $12, (0x6300 | 0x0008) ^ arch/mips/kernel/head.S:86:2: note: while in macro instantiation kernel_entry_setup # cpu specific setup ^ <instantiation>:16:12: error: invalid operand for instruction slti $12, (0x6300 | 0x0008) ^ arch/mips/kernel/head.S:150:2: note: while in macro instantiation smp_slave_setup ^ To increase compatibility with LLVM's integrated assembler, use the full form of 'slti <reg>, <reg>, <imm>', which matches the rest of arch/mips/. This does not result in any change for GNU as. Link: ClangBuiltLinux/linux#1526 Reported-by: Ryutaroh Matsumoto <[email protected]> Signed-off-by: Nathan Chancellor <[email protected]> Signed-off-by: Thomas Bogendoerfer <[email protected]>
1 parent 13ceb48 commit f2c6c22

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

arch/mips/include/asm/mach-loongson64/kernel-entry-init.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
nop
3333
/* Loongson-3A R2/R3 */
3434
andi t0, (PRID_IMP_MASK | PRID_REV_MASK)
35-
slti t0, (PRID_IMP_LOONGSON_64C | PRID_REV_LOONGSON3A_R2_0)
35+
slti t0, t0, (PRID_IMP_LOONGSON_64C | PRID_REV_LOONGSON3A_R2_0)
3636
bnez t0, 2f
3737
nop
3838
1:
@@ -63,7 +63,7 @@
6363
nop
6464
/* Loongson-3A R2/R3 */
6565
andi t0, (PRID_IMP_MASK | PRID_REV_MASK)
66-
slti t0, (PRID_IMP_LOONGSON_64C | PRID_REV_LOONGSON3A_R2_0)
66+
slti t0, t0, (PRID_IMP_LOONGSON_64C | PRID_REV_LOONGSON3A_R2_0)
6767
bnez t0, 2f
6868
nop
6969
1:

0 commit comments

Comments
 (0)