extable.c 369 B

12345678910111213141516171819202122
  1. /*
  2. * linux/arch/sh/mm/extable.c
  3. * Taken from:
  4. * linux/arch/i386/mm/extable.c
  5. */
  6. #include <linux/config.h>
  7. #include <linux/module.h>
  8. #include <asm/uaccess.h>
  9. int fixup_exception(struct pt_regs *regs)
  10. {
  11. const struct exception_table_entry *fixup;
  12. fixup = search_exception_tables(regs->pc);
  13. if (fixup) {
  14. regs->pc = fixup->fixup;
  15. return 1;
  16. }
  17. return 0;
  18. }