[patch, mips, elf.h] Fix elf.h values for MIPS archs.
Steve Ellcey
sellcey@mips.com
Thu Jan 10 22:25:00 GMT 2013
I have noticed that the values for some of the MIPS architecture levels listed
in elf/elf.h from glibc do not match the ones in include/elf/mips.h from
binutils. Since the ones in binutils are what the GNU assembler and
linker and other tools are actually using, this patch is to change glibc
to match these values.
I am sending this to the libc-alpha mailing list instead of libc-ports since
elf/elf.h is in the main glibc area but this change would, of course, only
affect MIPS targets.
OK to checkin?
Steve Ellcey
sellcey@mips.com
2013-01-10 Steve Ellcey <sellcey@mips.com>
* elf/elf.h (EF_MIPS_ARCH_32): Fix value.
(EF_MIPS_ARCH_64): Fix value.
(E_MIPS_ARCH_32): Fix value.
(E_MIPS_ARCH_64): Fix value.
(EF_MIPS_ARCH_32R2): New.
(EF_MIPS_ARCH_64R2): New.
(E_MIPS_ARCH_32R2): New.
(E_MIPS_ARCH_32R2): New.
diff --git a/elf/elf.h b/elf/elf.h
index 233b763..a2074e0 100644
--- a/elf/elf.h
+++ b/elf/elf.h
@@ -1388,8 +1388,10 @@ typedef struct
#define EF_MIPS_ARCH_3 0x20000000 /* -mips3 code. */
#define EF_MIPS_ARCH_4 0x30000000 /* -mips4 code. */
#define EF_MIPS_ARCH_5 0x40000000 /* -mips5 code. */
-#define EF_MIPS_ARCH_32 0x60000000 /* MIPS32 code. */
-#define EF_MIPS_ARCH_64 0x70000000 /* MIPS64 code. */
+#define EF_MIPS_ARCH_32 0x50000000 /* MIPS32 code. */
+#define EF_MIPS_ARCH_64 0x60000000 /* MIPS64 code. */
+#define EF_MIPS_ARCH_32R2 0x70000000 /* MIPS32r2 code. */
+#define EF_MIPS_ARCH_64R2 0x80000000 /* MIPS64r2 code. */
/* The following are non-official names and should not be used. */
@@ -1398,8 +1400,10 @@ typedef struct
#define E_MIPS_ARCH_3 0x20000000 /* -mips3 code. */
#define E_MIPS_ARCH_4 0x30000000 /* -mips4 code. */
#define E_MIPS_ARCH_5 0x40000000 /* -mips5 code. */
-#define E_MIPS_ARCH_32 0x60000000 /* MIPS32 code. */
-#define E_MIPS_ARCH_64 0x70000000 /* MIPS64 code. */
+#define E_MIPS_ARCH_32 0x50000000 /* MIPS32 code. */
+#define E_MIPS_ARCH_64 0x60000000 /* MIPS64 code. */
+#define E_MIPS_ARCH_32R2 0x70000000 /* MIPS32r2 code. */
+#define E_MIPS_ARCH_64R2 0x80000000 /* MIPS64r2 code. */
/* Special section indices. */
More information about the Libc-alpha
mailing list