#define __ASM_ARC_ELF_H
 
 #include <linux/types.h>
+#include <linux/elf-em.h>
 #include <uapi/asm/elf.h>
 
-/* These ELF defines belong to uapi but libc elf.h already defines them */
-#define EM_ARCOMPACT           93
-
-#define EM_ARCV2               195     /* ARCv2 Cores */
-
 #define EM_ARC_INUSE           (IS_ENABLED(CONFIG_ISA_ARCOMPACT) ? \
                                        EM_ARCOMPACT : EM_ARCV2)
 
 
 #define EM_M32R                88      /* Renesas M32R */
 #define EM_MN10300     89      /* Panasonic/MEI MN10300, AM33 */
 #define EM_OPENRISC     92     /* OpenRISC 32-bit embedded processor */
+#define EM_ARCOMPACT   93      /* ARCompact processor */
 #define EM_XTENSA      94      /* Tensilica Xtensa Architecture */
 #define EM_BLACKFIN     106     /* ADI Blackfin Processor */
 #define EM_ALTERA_NIOS2        113     /* Altera Nios II soft-core processor */
 #define EM_TILEPRO     188     /* Tilera TILEPro */
 #define EM_MICROBLAZE  189     /* Xilinx MicroBlaze */
 #define EM_TILEGX      191     /* Tilera TILE-Gx */
+#define EM_ARCV2       195     /* ARCv2 Cores */
 #define EM_RISCV       243     /* RISC-V */
 #define EM_BPF         247     /* Linux BPF - in-kernel virtual machine */
 #define EM_CSKY                252     /* C-SKY */