1 // SPDX-License-Identifier: GPL-2.0
3 * Copyright (C) 2020-2022 Loongson Technology Corporation Limited
5 #include <linux/extable.h>
6 #include <linux/spinlock.h>
7 #include <asm/branch.h>
8 #include <linux/uaccess.h>
10 int fixup_exception(struct pt_regs *regs)
12 const struct exception_table_entry *fixup;
14 fixup = search_exception_tables(exception_era(regs));
16 regs->csr_era = fixup->fixup;