diff options
author | emaste <emaste@FreeBSD.org> | 2015-09-24 12:44:02 +0000 |
---|---|---|
committer | emaste <emaste@FreeBSD.org> | 2015-09-24 12:44:02 +0000 |
commit | 09f805e3141a9cd471d5c7060ce033e1caaf796e (patch) | |
tree | b2008df2d6b33f0d3b81f8b8c74b4c82b48bc2d2 | |
parent | 09e4cb51449bc109373705136be9e3da7ecd740f (diff) | |
download | FreeBSD-src-09f805e3141a9cd471d5c7060ce033e1caaf796e.zip FreeBSD-src-09f805e3141a9cd471d5c7060ce033e1caaf796e.tar.gz |
MFC r285841: Add RISC-V ELF machine type definition
EM_RISCV is now officially registered as e_machine 243.
Sponsored by: The FreeBSD Foundation
-rw-r--r-- | sys/sys/elf_common.h | 1 | ||||
-rw-r--r-- | usr.bin/elfdump/elfdump.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/sys/sys/elf_common.h b/sys/sys/elf_common.h index 889b65c..25e016c 100644 --- a/sys/sys/elf_common.h +++ b/sys/sys/elf_common.h @@ -238,6 +238,7 @@ typedef struct { #define EM_UNICORE 110 /* Microprocessor series from PKU-Unity Ltd. and MPRC of Peking University */ #define EM_AARCH64 183 /* AArch64 (64-bit ARM) */ +#define EM_RISCV 243 /* RISC-V */ /* Non-standard or deprecated. */ #define EM_486 6 /* Intel i486. */ diff --git a/usr.bin/elfdump/elfdump.c b/usr.bin/elfdump/elfdump.c index 9640dd5..3670f88 100644 --- a/usr.bin/elfdump/elfdump.c +++ b/usr.bin/elfdump/elfdump.c @@ -271,6 +271,7 @@ e_machines(u_int mach) case EM_IA_64: return "EM_IA_64"; case EM_X86_64: return "EM_X86_64"; case EM_AARCH64:return "EM_AARCH64"; + case EM_RISCV: return "EM_RISCV"; } snprintf(machdesc, sizeof(machdesc), "(unknown machine) -- type 0x%x", mach); |