]> git.baikalelectronics.ru Git - kernel.git/commit
MIPS: atomic: Use _atomic barriers in atomic_sub_if_positive()
authorPaul Burton <paul.burton@mips.com>
Tue, 1 Oct 2019 21:53:21 +0000 (21:53 +0000)
committerPaul Burton <paul.burton@mips.com>
Mon, 7 Oct 2019 16:42:32 +0000 (09:42 -0700)
commitec221926d3629f19f24c31eae701060aceaaab4f
tree0b2c440703c058cc6fe3e41923a9a9318a86d5e3
parent1dc77154571a6b38614437653c15e4b2dc5640a6
MIPS: atomic: Use _atomic barriers in atomic_sub_if_positive()

Use smp_mb__before_atomic() & smp_mb__after_atomic() in
atomic_sub_if_positive() rather than the equivalent
smp_mb__before_llsc() & smp_llsc_mb(). The former are more standard &
this preps us for avoiding redundant duplicate barriers on Loongson3 in
a later patch.

Signed-off-by: Paul Burton <paul.burton@mips.com>
Cc: linux-mips@vger.kernel.org
Cc: Huacai Chen <chenhc@lemote.com>
Cc: Jiaxun Yang <jiaxun.yang@flygoat.com>
Cc: linux-kernel@vger.kernel.org
arch/mips/include/asm/atomic.h