Kaynağa Gözat

MIPS: Fix write_gc0_* macros when writing zero

The versions of the __write_{32,64}bit_gc0_register() macros for when
there is no virt support in the assembler use the "J" inline asm
constraint to allow integer zero, but this needs to be accompanied by
the "z" formatting string so that it turns into $0. Fix both macros to
do this.

Fixes: bad50d79255a ("MIPS: Fix VZ probe gas errors with binutils <2.24")
Signed-off-by: James Hogan <james.hogan@imgtec.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/13289/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
James Hogan 9 yıl önce
ebeveyn
işleme
f03984ca4f
1 değiştirilmiş dosya ile 2 ekleme ve 2 silme
  1. 2 2
      arch/mips/include/asm/mipsregs.h

+ 2 - 2
arch/mips/include/asm/mipsregs.h

@@ -1773,7 +1773,7 @@ do {									\
 	__asm__ __volatile__(						\
 	__asm__ __volatile__(						\
 		".set\tpush\n\t"					\
 		".set\tpush\n\t"					\
 		".set\tnoat\n\t"					\
 		".set\tnoat\n\t"					\
-		"move\t$1, %0\n\t"					\
+		"move\t$1, %z0\n\t"					\
 		"# mtgc0\t$1, $%1, %2\n\t"				\
 		"# mtgc0\t$1, $%1, %2\n\t"				\
 		".word\t(0x40610200 | %1 << 11 | %2)\n\t"		\
 		".word\t(0x40610200 | %1 << 11 | %2)\n\t"		\
 		".set\tpop"						\
 		".set\tpop"						\
@@ -1786,7 +1786,7 @@ do {									\
 	__asm__ __volatile__(						\
 	__asm__ __volatile__(						\
 		".set\tpush\n\t"					\
 		".set\tpush\n\t"					\
 		".set\tnoat\n\t"					\
 		".set\tnoat\n\t"					\
-		"move\t$1, %0\n\t"					\
+		"move\t$1, %z0\n\t"					\
 		"# dmtgc0\t$1, $%1, %2\n\t"				\
 		"# dmtgc0\t$1, $%1, %2\n\t"				\
 		".word\t(0x40610300 | %1 << 11 | %2)\n\t"		\
 		".word\t(0x40610300 | %1 << 11 | %2)\n\t"		\
 		".set\tpop"						\
 		".set\tpop"						\