Commit 372c7209 authored by Michal Simek's avatar Michal Simek Committed by Linus Torvalds

microblaze: extable: sort the exception table at build time

Sort the exception table at build-time rather than during boot.

Microblaze is the same case as AARCH64 that's why EM_MICROBLAZE
conditional check was added to allow cross-compilation on machines which
are not running the latest libc-dev.

Inspired by AARCH64 commit adace895 ("arm64: extable: sort the
exception table at build time").
Signed-off-by: default avatarMichal Simek <michal.simek@xilinx.com>
Acked-by: default avatarDavid Daney <david.daney@cavium.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 3fdb38bd
...@@ -30,6 +30,7 @@ config MICROBLAZE ...@@ -30,6 +30,7 @@ config MICROBLAZE
select MODULES_USE_ELF_RELA select MODULES_USE_ELF_RELA
select CLONE_BACKWARDS3 select CLONE_BACKWARDS3
select CLKSRC_OF select CLKSRC_OF
select BUILDTIME_EXTABLE_SORT
config SWAP config SWAP
def_bool n def_bool n
......
...@@ -39,6 +39,10 @@ ...@@ -39,6 +39,10 @@
#define EM_AARCH64 183 #define EM_AARCH64 183
#endif #endif
#ifndef EM_MICROBLAZE
#define EM_MICROBLAZE 189
#endif
static int fd_map; /* File descriptor for file being modified. */ static int fd_map; /* File descriptor for file being modified. */
static int mmap_failed; /* Boolean flag. */ static int mmap_failed; /* Boolean flag. */
static void *ehdr_curr; /* current ElfXX_Ehdr * for resource cleanup */ static void *ehdr_curr; /* current ElfXX_Ehdr * for resource cleanup */
...@@ -275,6 +279,7 @@ do_file(char const *const fname) ...@@ -275,6 +279,7 @@ do_file(char const *const fname)
case EM_ARCOMPACT: case EM_ARCOMPACT:
case EM_ARM: case EM_ARM:
case EM_AARCH64: case EM_AARCH64:
case EM_MICROBLAZE:
case EM_MIPS: case EM_MIPS:
break; break;
} /* end switch */ } /* end switch */
......
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