2012-03-05 19:49:27 +08:00
|
|
|
/*
|
|
|
|
* Based on arch/arm/mm/extable.c
|
|
|
|
*/
|
|
|
|
|
2016-09-20 05:38:55 +08:00
|
|
|
#include <linux/extable.h>
|
2012-03-05 19:49:27 +08:00
|
|
|
#include <linux/uaccess.h>
|
|
|
|
|
|
|
|
int fixup_exception(struct pt_regs *regs)
|
|
|
|
{
|
|
|
|
const struct exception_table_entry *fixup;
|
|
|
|
|
|
|
|
fixup = search_exception_tables(instruction_pointer(regs));
|
|
|
|
if (fixup)
|
2016-01-01 22:02:12 +08:00
|
|
|
regs->pc = (unsigned long)&fixup->fixup + fixup->fixup;
|
2012-03-05 19:49:27 +08:00
|
|
|
|
|
|
|
return fixup != NULL;
|
|
|
|
}
|