diff options
author | Weijie Gao | 2020-04-21 09:28:25 +0200 |
---|---|---|
committer | Daniel Schwierzeck | 2020-04-27 20:29:33 +0200 |
commit | 71059736b854462a474bc329a366c3392cf92462 (patch) | |
tree | edbc20d4ceefa85a0d269e3e52c877556a39facf /arch/mips/Kconfig | |
parent | 56ed625ba288faaca0c8b8cbd81e777548b6f7de (diff) |
mips: add support to restore exception vector base before booting linux
In U-Boot the exception vector base will be moved to top of memory, to be
used to display register dump when exception occurs.
But some old linux kernel does not honor the base set in CP0_EBASE. A
modified exception vector base will cause kernel crash.
This patch adds an option to enable reset exception vector base to its
previous value, or a user configured value before booting linux kernel.
Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
Diffstat (limited to 'arch/mips/Kconfig')
-rw-r--r-- | arch/mips/Kconfig | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index a3ae6030448..5e20feeefb8 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig @@ -287,6 +287,36 @@ config MIPS_RELOCATION_TABLE_SIZE If unsure, leave at the default value. +config RESTORE_EXCEPTION_VECTOR_BASE + bool "Restore exception vector base before booting linux kernel" + default n + help + In U-Boot the exception vector base will be moved to top of memory, + to be used to display register dump when exception occurs. + But some old linux kernel does not honor the base set in CP0_EBASE. + A modified exception vector base will cause kernel crash. + + This option will restore the exception vector base to its previous + value. + + If unsure, say N. + +config OVERRIDE_EXCEPTION_VECTOR_BASE + bool "Override the exception vector base to be restored" + depends on RESTORE_EXCEPTION_VECTOR_BASE + default n + help + Enable this option if you want to use a different exception vector + base rather than the previously saved one. + +config NEW_EXCEPTION_VECTOR_BASE + hex "New exception vector base" + depends on OVERRIDE_EXCEPTION_VECTOR_BASE + range 0x80000000 0xbffff000 + default 0x80000000 + help + The exception vector base to be restored before booting linux kernel + endmenu menu "OS boot interface" |