MIPS: fix local_irq_{disable,enable} in asmmacro.h
authorHuang Pei <huangpei@loongson.cn>
Tue, 23 Mar 2021 02:34:02 +0000 (10:34 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 14 May 2021 07:50:30 +0000 (09:50 +0200)
commit536175f0065cb49da7caf245e9352b341894c46a
tree0f69d412fe957eab88b25c2a059a1727f324fc16
parent4c45556db31c58e25c7e9e9c396c8a1ac8a936e8
MIPS: fix local_irq_{disable,enable} in asmmacro.h

[ Upstream commit 05c4e2721d7af0df7bc1378a23712a0fd16947b5 ]

commit ba9196d2e005 ("MIPS: Make DIEI support as a config option")
use CPU_HAS_DIEI to indicate whether di/ei is implemented correctly,
without this patch, "local_irq_disable" from entry.S in 3A1000
(with buggy di/ei) lose protection of commit e97c5b609880 ("MIPS:
Make irqflags.h functions preempt-safe for non-mipsr2 cpus")

Fixes: ba9196d2e005 ("MIPS: Make DIEI support as a config option")
Signed-off-by: Huang Pei <huangpei@loongson.cn>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
arch/mips/include/asm/asmmacro.h