summary refs log tree commit diff
path: root/arch/mips/include/asm
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2020-03-31 10:44:53 -0400
committerPaolo Bonzini <pbonzini@redhat.com>2020-03-31 10:44:53 -0400
commitcf39d37539068d53e015d8b4f1dcf42c65306b0d (patch)
treec8dcbbc3a5c92beee82e83e2a2b597f328a919a6 /arch/mips/include/asm
parent830948eb68265ac7f3f364aa9801550feafec0d6 (diff)
parent463050599742a89e0508355e626e032e8d0dab8d (diff)
downloadlinux-cf39d37539068d53e015d8b4f1dcf42c65306b0d.tar.gz
Merge tag 'kvmarm-5.7' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into HEAD
KVM/arm updates for Linux 5.7

- GICv4.1 support
- 32bit host removal
Diffstat (limited to 'arch/mips/include/asm')
-rw-r--r--arch/mips/include/asm/sync.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/mips/include/asm/sync.h b/arch/mips/include/asm/sync.h
index 7c6a1095f556..aabd097933fe 100644
--- a/arch/mips/include/asm/sync.h
+++ b/arch/mips/include/asm/sync.h
@@ -155,9 +155,11 @@
  * effective barrier as noted by commit 6b07d38aaa52 ("MIPS: Octeon: Use
  * optimized memory barrier primitives."). Here we specify that the affected
  * sync instructions should be emitted twice.
+ * Note that this expression is evaluated by the assembler (not the compiler),
+ * and that the assembler evaluates '==' as 0 or -1, not 0 or 1.
  */
 #ifdef CONFIG_CPU_CAVIUM_OCTEON
-# define __SYNC_rpt(type)	(1 + (type == __SYNC_wmb))
+# define __SYNC_rpt(type)	(1 - (type == __SYNC_wmb))
 #else
 # define __SYNC_rpt(type)	1
 #endif