Commit 6fb97eff authored by Kevin Cernekee's avatar Kevin Cernekee Committed by Ralf Baechle

MIPS: Add board_ebase_setup()

Some systems need to relocate the MIPS exception vector base during
trap initialization.  Add a hook to make this possible.
Signed-off-by: default avatarKevin Cernekee <cernekee@gmail.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/2959/Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
parent 34bd92e2
...@@ -24,6 +24,7 @@ extern int (*board_be_handler)(struct pt_regs *regs, int is_fixup); ...@@ -24,6 +24,7 @@ extern int (*board_be_handler)(struct pt_regs *regs, int is_fixup);
extern void (*board_nmi_handler_setup)(void); extern void (*board_nmi_handler_setup)(void);
extern void (*board_ejtag_handler_setup)(void); extern void (*board_ejtag_handler_setup)(void);
extern void (*board_bind_eic_interrupt)(int irq, int regset); extern void (*board_bind_eic_interrupt)(int irq, int regset);
extern void (*board_ebase_setup)(void);
extern int register_nmi_notifier(struct notifier_block *nb); extern int register_nmi_notifier(struct notifier_block *nb);
......
...@@ -91,6 +91,7 @@ int (*board_be_handler)(struct pt_regs *regs, int is_fixup); ...@@ -91,6 +91,7 @@ int (*board_be_handler)(struct pt_regs *regs, int is_fixup);
void (*board_nmi_handler_setup)(void); void (*board_nmi_handler_setup)(void);
void (*board_ejtag_handler_setup)(void); void (*board_ejtag_handler_setup)(void);
void (*board_bind_eic_interrupt)(int irq, int regset); void (*board_bind_eic_interrupt)(int irq, int regset);
void (*board_ebase_setup)(void);
static void show_raw_backtrace(unsigned long reg29) static void show_raw_backtrace(unsigned long reg29)
...@@ -1691,6 +1692,8 @@ void __init trap_init(void) ...@@ -1691,6 +1692,8 @@ void __init trap_init(void)
ebase += (read_c0_ebase() & 0x3ffff000); ebase += (read_c0_ebase() & 0x3ffff000);
} }
if (board_ebase_setup)
board_ebase_setup();
per_cpu_trap_init(); per_cpu_trap_init();
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment