xref: /dflybsd-src/contrib/binutils-2.34/include/elf/mn10300.h (revision b52ef7118d1621abed722c5bbbd542210290ecef)
1*fae548d3Szrj /* MN10300 ELF support for BFD.
2*fae548d3Szrj    Copyright (C) 1998-2020 Free Software Foundation, Inc.
3*fae548d3Szrj 
4*fae548d3Szrj    This file is part of BFD, the Binary File Descriptor library.
5*fae548d3Szrj 
6*fae548d3Szrj    This program is free software; you can redistribute it and/or modify
7*fae548d3Szrj    it under the terms of the GNU General Public License as published by
8*fae548d3Szrj    the Free Software Foundation; either version 3 of the License, or
9*fae548d3Szrj    (at your option) any later version.
10*fae548d3Szrj 
11*fae548d3Szrj    This program is distributed in the hope that it will be useful,
12*fae548d3Szrj    but WITHOUT ANY WARRANTY; without even the implied warranty of
13*fae548d3Szrj    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14*fae548d3Szrj    GNU General Public License for more details.
15*fae548d3Szrj 
16*fae548d3Szrj    You should have received a copy of the GNU General Public License
17*fae548d3Szrj    along with this program; if not, write to the Free Software
18*fae548d3Szrj    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
19*fae548d3Szrj    MA 02110-1301, USA.  */
20*fae548d3Szrj 
21*fae548d3Szrj /* This file holds definitions specific to the MN10300 ELF ABI.  */
22*fae548d3Szrj 
23*fae548d3Szrj #ifndef _ELF_MN10300_H
24*fae548d3Szrj #define _ELF_MN10300_H
25*fae548d3Szrj 
26*fae548d3Szrj #include "elf/reloc-macros.h"
27*fae548d3Szrj 
28*fae548d3Szrj /* Relocations.  */
29*fae548d3Szrj START_RELOC_NUMBERS (elf_mn10300_reloc_type)
30*fae548d3Szrj   RELOC_NUMBER (R_MN10300_NONE, 0)
31*fae548d3Szrj   RELOC_NUMBER (R_MN10300_32, 1)
32*fae548d3Szrj   RELOC_NUMBER (R_MN10300_16, 2)
33*fae548d3Szrj   RELOC_NUMBER (R_MN10300_8, 3)
34*fae548d3Szrj   RELOC_NUMBER (R_MN10300_PCREL32, 4)
35*fae548d3Szrj   RELOC_NUMBER (R_MN10300_PCREL16, 5)
36*fae548d3Szrj   RELOC_NUMBER (R_MN10300_PCREL8, 6)
37*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GNU_VTINHERIT, 7)
38*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GNU_VTENTRY, 8)
39*fae548d3Szrj   RELOC_NUMBER (R_MN10300_24, 9)
40*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GOTPC32, 10)
41*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GOTPC16, 11)
42*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GOTOFF32, 12)
43*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GOTOFF24, 13)
44*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GOTOFF16, 14)
45*fae548d3Szrj   RELOC_NUMBER (R_MN10300_PLT32, 15)
46*fae548d3Szrj   RELOC_NUMBER (R_MN10300_PLT16, 16)
47*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GOT32, 17)
48*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GOT24, 18)
49*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GOT16, 19)
50*fae548d3Szrj   RELOC_NUMBER (R_MN10300_COPY, 20)
51*fae548d3Szrj   RELOC_NUMBER (R_MN10300_GLOB_DAT, 21)
52*fae548d3Szrj   RELOC_NUMBER (R_MN10300_JMP_SLOT, 22)
53*fae548d3Szrj   RELOC_NUMBER (R_MN10300_RELATIVE, 23)
54*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_GD, 24)
55*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_LD, 25)
56*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_LDO, 26)
57*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_GOTIE, 27)
58*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_IE, 28)
59*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_LE, 29)
60*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_DTPMOD, 30)
61*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_DTPOFF, 31)
62*fae548d3Szrj   RELOC_NUMBER (R_MN10300_TLS_TPOFF, 32)
63*fae548d3Szrj   RELOC_NUMBER (R_MN10300_SYM_DIFF, 33)
64*fae548d3Szrj   RELOC_NUMBER (R_MN10300_ALIGN, 34)
65*fae548d3Szrj END_RELOC_NUMBERS (R_MN10300_MAX)
66*fae548d3Szrj 
67*fae548d3Szrj /* Machine variant if we know it.  This field was invented at Cygnus,
68*fae548d3Szrj    but it is hoped that other vendors will adopt it.  If some standard
69*fae548d3Szrj    is developed, this code should be changed to follow it.  */
70*fae548d3Szrj 
71*fae548d3Szrj #define EF_MN10300_MACH		0x00FF0000
72*fae548d3Szrj 
73*fae548d3Szrj /* Cygnus is choosing values between 80 and 9F;
74*fae548d3Szrj    00 - 7F should be left for a future standard;
75*fae548d3Szrj    the rest are open.  */
76*fae548d3Szrj 
77*fae548d3Szrj #define E_MN10300_MACH_MN10300	0x00810000
78*fae548d3Szrj #define E_MN10300_MACH_AM33	0x00820000
79*fae548d3Szrj #define E_MN10300_MACH_AM33_2   0x00830000
80*fae548d3Szrj #endif /* _ELF_MN10300_H */
81