linux-user: getpriority errno fix
[qemu] / elf.h
diff --git a/elf.h b/elf.h
index 0c03f03..11674d7 100644 (file)
--- a/elf.h
+++ b/elf.h
@@ -119,6 +119,8 @@ typedef int64_t  Elf64_Sxword;
  */
 #define EM_S390_OLD     0xA390
 
+#define EM_XILINX_MICROBLAZE    0xBAAB
+
 /* This is the info that is needed to parse the dynamic section of the file */
 #define DT_NULL                0
 #define DT_NEEDED      1
@@ -452,7 +454,9 @@ typedef struct {
 #define R_PPC_SECTOFF_HI       35
 #define R_PPC_SECTOFF_HA       36
 /* Keep this the last entry.  */
+#ifndef R_PPC_NUM
 #define R_PPC_NUM              37
+#endif
 
 /* ARM specific declarations */
 
@@ -1079,7 +1083,23 @@ typedef struct elf64_shdr {
 #define        EI_CLASS        4
 #define        EI_DATA         5
 #define        EI_VERSION      6
-#define        EI_PAD          7
+#define        EI_OSABI        7
+#define        EI_PAD          8
+
+#define ELFOSABI_NONE           0       /* UNIX System V ABI */
+#define ELFOSABI_SYSV           0       /* Alias.  */
+#define ELFOSABI_HPUX           1       /* HP-UX */
+#define ELFOSABI_NETBSD         2       /* NetBSD.  */
+#define ELFOSABI_LINUX          3       /* Linux.  */
+#define ELFOSABI_SOLARIS        6       /* Sun Solaris.  */
+#define ELFOSABI_AIX            7       /* IBM AIX.  */
+#define ELFOSABI_IRIX           8       /* SGI Irix.  */
+#define ELFOSABI_FREEBSD        9       /* FreeBSD.  */
+#define ELFOSABI_TRU64          10      /* Compaq TRU64 UNIX.  */
+#define ELFOSABI_MODESTO        11      /* Novell Modesto.  */
+#define ELFOSABI_OPENBSD        12      /* OpenBSD.  */
+#define ELFOSABI_ARM            97      /* ARM */
+#define ELFOSABI_STANDALONE     255     /* Standalone (embedded) application */
 
 #define        ELFMAG0         0x7f            /* EI_MAG */
 #define        ELFMAG1         'E'
@@ -1106,6 +1126,7 @@ typedef struct elf64_shdr {
 #define NT_PRFPREG     2
 #define NT_PRPSINFO    3
 #define NT_TASKSTRUCT  4
+#define NT_AUXV                6
 #define NT_PRXFPREG     0x46e62b7f      /* copied from gdb5.1/include/elf/common.h */
 
 
@@ -1123,6 +1144,7 @@ typedef struct elf64_note {
   Elf64_Word n_type;   /* Content type */
 } Elf64_Nhdr;
 
+#ifdef ELF_CLASS
 #if ELF_CLASS == ELFCLASS32
 
 #define elfhdr         elf32_hdr
@@ -1130,6 +1152,7 @@ typedef struct elf64_note {
 #define elf_note       elf32_note
 #define elf_shdr       elf32_shdr
 #define elf_sym                elf32_sym
+#define elf_addr_t     Elf32_Off
 
 #ifdef ELF_USES_RELOCA
 # define ELF_RELOC      Elf32_Rela
@@ -1144,6 +1167,7 @@ typedef struct elf64_note {
 #define elf_note       elf64_note
 #define elf_shdr       elf64_shdr
 #define elf_sym                elf64_sym
+#define elf_addr_t     Elf64_Off
 
 #ifdef ELF_USES_RELOCA
 # define ELF_RELOC      Elf64_Rela
@@ -1163,5 +1187,7 @@ typedef struct elf64_note {
 # endif
 #endif
 
+#endif /* ELF_CLASS */
+
 
 #endif /* _QEMU_ELF_H */