diff options
author | Max Filippov <jcmvbkbc@gmail.com> | 2017-01-04 10:40:49 -0800 |
---|---|---|
committer | Max Filippov <jcmvbkbc@gmail.com> | 2017-03-01 12:32:50 -0800 |
commit | b46dcfa378b0cdea1ee832802c9e36750e0fffa9 (patch) | |
tree | 38f96eb95db4e95c8240c80c352a29ba49c7e846 /arch/xtensa/kernel/setup.c | |
parent | 9a736fcb096b43b68af8329eb12abc8256dceaba (diff) |
xtensa: allow merging vectors into .text section
Currently code for exception/IRQ vectors is stored in kernel image as
initialization data and is copied to its working addresses during
startup. It doesn't always make sense. In many cases vectors location
can be automatically decided at kernel link time and code can be placed
right there. This is especially useful for XIP kernel.
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Diffstat (limited to 'arch/xtensa/kernel/setup.c')
-rw-r--r-- | arch/xtensa/kernel/setup.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/xtensa/kernel/setup.c b/arch/xtensa/kernel/setup.c index 23f2e034ba46..7fc7bb9f3b84 100644 --- a/arch/xtensa/kernel/setup.c +++ b/arch/xtensa/kernel/setup.c @@ -455,6 +455,7 @@ void __init setup_arch(char **cmdline_p) mem_reserve(__pa(&_stext), __pa(&_end)); +#ifdef CONFIG_VECTORS_OFFSET mem_reserve(__pa(&_WindowVectors_text_start), __pa(&_WindowVectors_text_end)); @@ -491,6 +492,8 @@ void __init setup_arch(char **cmdline_p) __pa(&_Level6InterruptVector_text_end)); #endif +#endif /* CONFIG_VECTORS_OFFSET */ + #ifdef CONFIG_SMP mem_reserve(__pa(&_SecondaryResetVector_text_start), __pa(&_SecondaryResetVector_text_end)); |