]> git.baikalelectronics.ru Git - kernel.git/commit
MIPS: cmpxchg64() and HAVE_VIRT_CPU_ACCOUNTING_GEN don't work for 32-bit SMP
authorBen Hutchings <ben@decadent.org.uk>
Wed, 4 Oct 2017 02:46:14 +0000 (03:46 +0100)
committerJames Hogan <jhogan@kernel.org>
Mon, 13 Nov 2017 16:49:01 +0000 (16:49 +0000)
commitdb9eda54a84b69aa19bebaaf39004a2c9a015066
tree54b5775c98fe42831ad7f50f99d1ac22da5df65c
parent23ed9b34c5a3a2fef49885149f3c0797630641a6
MIPS: cmpxchg64() and HAVE_VIRT_CPU_ACCOUNTING_GEN don't work for 32-bit SMP

__cmpxchg64_local_generic() is atomic only w.r.t tasks and interrupts
on the same CPU (that's what the 'local' means).  We can't use it to
implement cmpxchg64() in SMP configurations.

So, for 32-bit SMP configurations:

- Don't define cmpxchg64()
- Don't enable HAVE_VIRT_CPU_ACCOUNTING_GEN, which requires it

Fixes: c1d21d9612f7 ("MIPS: Fall back to generic implementation of ...")
Fixes: b2199c1e7511 ("MIPS: Add support for full dynticks CPU time accounting")
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Deng-Cheng Zhu <dengcheng.zhu@mips.com>
Cc: linux-mips@linux-mips.org
Cc: <stable@vger.kernel.org> # 4.1+
Patchwork: https://patchwork.linux-mips.org/patch/17413/
Signed-off-by: James Hogan <jhogan@kernel.org>
arch/mips/Kconfig
arch/mips/include/asm/cmpxchg.h