mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-16 23:45:31 +08:00
MIPS: Clear Cause.BD in instruction_pointer_set
[ Upstream commit 9d6e21ddf2
]
Clear Cause.BD after we use instruction_pointer_set to override
EPC.
This can prevent exception_epc check against instruction code at
new return address.
It won't be considered as "in delay slot" after epc being overridden
anyway.
Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
a9bbb05c0c
commit
ab63a80996
@ -60,6 +60,7 @@ static inline void instruction_pointer_set(struct pt_regs *regs,
|
|||||||
unsigned long val)
|
unsigned long val)
|
||||||
{
|
{
|
||||||
regs->cp0_epc = val;
|
regs->cp0_epc = val;
|
||||||
|
regs->cp0_cause &= ~CAUSEF_BD;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Query offset/name of register from its name/offset */
|
/* Query offset/name of register from its name/offset */
|
||||||
|
Loading…
Reference in New Issue
Block a user