summaryrefslogtreecommitdiffstats
path: root/recipes-devtools
diff options
context:
space:
mode:
authorMartin Borg <martin.borg@enea.com>2016-02-16 12:00:22 +0100
committerHuimin She <huimin.she@enea.com>2016-02-24 13:37:33 +0100
commit80bbbc804ccfd071fc8c365afe1a3a9f3f41dfaa (patch)
tree8edfe10a37155febe352cf13c7fd965ea0d8dcb0 /recipes-devtools
parente60b73ff643117137ca42534f013784b61d0f0fc (diff)
downloadmeta-nfv-access-common-80bbbc804ccfd071fc8c365afe1a3a9f3f41dfaa.tar.gz
binutils: drop the bbappends
This was a temporary fix for 64bit PPC kernel builds with binutils 2.24 [1]. The build problem was fixed in meta-fsl-ppc by backport of a kernel patch (commit a6c4175595b0f316e543cf93a8b6dc1a7f098997) and this backported patch was later removed when the kernel version was upgraded (commit e321cb35d66d31b4d7f10da989e7b94eea3337c3). binutils has also been upgraded to 2.25.1 on poky master ------- [1] https://lists.yoctoproject.org/pipermail/meta-freescale/2014-April/008083.html Signed-off-by: Martin Borg <martin.borg@enea.com> Signed-off-by: Huimin She <huimin.she@enea.com>
Diffstat (limited to 'recipes-devtools')
-rw-r--r--recipes-devtools/binutils/binutils-2.24.inc6
-rw-r--r--recipes-devtools/binutils/binutils-cross-canadian_2.24.bbappend1
-rw-r--r--recipes-devtools/binutils/binutils-cross_2.24.bbappend1
-rw-r--r--recipes-devtools/binutils/binutils-crosssdk_2.24.bbappend1
-rw-r--r--recipes-devtools/binutils/binutils_2.24.bbappend1
-rw-r--r--recipes-devtools/binutils/files/0001-Revert-Report-overflow-on-PowerPC64-h-and-ha-relocat.patch1087
6 files changed, 0 insertions, 1097 deletions
diff --git a/recipes-devtools/binutils/binutils-2.24.inc b/recipes-devtools/binutils/binutils-2.24.inc
deleted file mode 100644
index 3a1186c..0000000
--- a/recipes-devtools/binutils/binutils-2.24.inc
+++ /dev/null
@@ -1,6 +0,0 @@
1FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
2
3SRC_URI += "\
4 file://0001-Revert-Report-overflow-on-PowerPC64-h-and-ha-relocat.patch \
5 "
6
diff --git a/recipes-devtools/binutils/binutils-cross-canadian_2.24.bbappend b/recipes-devtools/binutils/binutils-cross-canadian_2.24.bbappend
deleted file mode 100644
index 0427595..0000000
--- a/recipes-devtools/binutils/binutils-cross-canadian_2.24.bbappend
+++ /dev/null
@@ -1 +0,0 @@
1require binutils-${PV}.inc
diff --git a/recipes-devtools/binutils/binutils-cross_2.24.bbappend b/recipes-devtools/binutils/binutils-cross_2.24.bbappend
deleted file mode 100644
index 0427595..0000000
--- a/recipes-devtools/binutils/binutils-cross_2.24.bbappend
+++ /dev/null
@@ -1 +0,0 @@
1require binutils-${PV}.inc
diff --git a/recipes-devtools/binutils/binutils-crosssdk_2.24.bbappend b/recipes-devtools/binutils/binutils-crosssdk_2.24.bbappend
deleted file mode 100644
index 0427595..0000000
--- a/recipes-devtools/binutils/binutils-crosssdk_2.24.bbappend
+++ /dev/null
@@ -1 +0,0 @@
1require binutils-${PV}.inc
diff --git a/recipes-devtools/binutils/binutils_2.24.bbappend b/recipes-devtools/binutils/binutils_2.24.bbappend
deleted file mode 100644
index 0427595..0000000
--- a/recipes-devtools/binutils/binutils_2.24.bbappend
+++ /dev/null
@@ -1 +0,0 @@
1require binutils-${PV}.inc
diff --git a/recipes-devtools/binutils/files/0001-Revert-Report-overflow-on-PowerPC64-h-and-ha-relocat.patch b/recipes-devtools/binutils/files/0001-Revert-Report-overflow-on-PowerPC64-h-and-ha-relocat.patch
deleted file mode 100644
index bda760f..0000000
--- a/recipes-devtools/binutils/files/0001-Revert-Report-overflow-on-PowerPC64-h-and-ha-relocat.patch
+++ /dev/null
@@ -1,1087 +0,0 @@
1From 269bee7df1abfdc230f1ed6a6de3150adffde962 Mon Sep 17 00:00:00 2001
2From: Alexandru-Cezar Sardan <alexandru.sardan@freescale.com>
3Date: Fri, 11 Apr 2014 16:15:36 +0300
4Subject: [PATCH] Revert 'Report overflow on PowerPC64 @h and @ha
5 relocations.' patch
6
7---
8 bfd/elf64-ppc.c | 183 +++++++++------------------------------------------
9 bfd/reloc.c | 12 ----
10 elfcpp/powerpc.h | 6 --
11 gas/config/tc-ppc.c | 139 ++++++++++----------------------------
12 gold/powerpc.cc | 130 +++++++++++-------------------------
13 include/elf/ppc64.h | 13 +---
14 6 files changed, 109 insertions(+), 374 deletions(-)
15
16diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
17index bf13a5d..ba3c655 100644
18--- a/bfd/elf64-ppc.c
19+++ b/bfd/elf64-ppc.c
20@@ -327,7 +327,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
21 16, /* bitsize */
22 FALSE, /* pc_relative */
23 0, /* bitpos */
24- complain_overflow_signed, /* complain_on_overflow */
25+ complain_overflow_dont, /* complain_on_overflow */
26 bfd_elf_generic_reloc, /* special_function */
27 "R_PPC64_ADDR16_HI", /* name */
28 FALSE, /* partial_inplace */
29@@ -343,7 +343,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
30 16, /* bitsize */
31 FALSE, /* pc_relative */
32 0, /* bitpos */
33- complain_overflow_signed, /* complain_on_overflow */
34+ complain_overflow_dont, /* complain_on_overflow */
35 ppc64_elf_ha_reloc, /* special_function */
36 "R_PPC64_ADDR16_HA", /* name */
37 FALSE, /* partial_inplace */
38@@ -505,7 +505,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
39 16, /* bitsize */
40 FALSE, /* pc_relative */
41 0, /* bitpos */
42- complain_overflow_signed,/* complain_on_overflow */
43+ complain_overflow_dont,/* complain_on_overflow */
44 ppc64_elf_unhandled_reloc, /* special_function */
45 "R_PPC64_GOT16_HI", /* name */
46 FALSE, /* partial_inplace */
47@@ -521,7 +521,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
48 16, /* bitsize */
49 FALSE, /* pc_relative */
50 0, /* bitpos */
51- complain_overflow_signed,/* complain_on_overflow */
52+ complain_overflow_dont,/* complain_on_overflow */
53 ppc64_elf_unhandled_reloc, /* special_function */
54 "R_PPC64_GOT16_HA", /* name */
55 FALSE, /* partial_inplace */
56@@ -698,7 +698,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
57 16, /* bitsize */
58 FALSE, /* pc_relative */
59 0, /* bitpos */
60- complain_overflow_signed, /* complain_on_overflow */
61+ complain_overflow_dont, /* complain_on_overflow */
62 ppc64_elf_unhandled_reloc, /* special_function */
63 "R_PPC64_PLT16_HI", /* name */
64 FALSE, /* partial_inplace */
65@@ -714,7 +714,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
66 16, /* bitsize */
67 FALSE, /* pc_relative */
68 0, /* bitpos */
69- complain_overflow_signed, /* complain_on_overflow */
70+ complain_overflow_dont, /* complain_on_overflow */
71 ppc64_elf_unhandled_reloc, /* special_function */
72 "R_PPC64_PLT16_HA", /* name */
73 FALSE, /* partial_inplace */
74@@ -759,7 +759,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
75 16, /* bitsize */
76 FALSE, /* pc_relative */
77 0, /* bitpos */
78- complain_overflow_signed, /* complain_on_overflow */
79+ complain_overflow_dont, /* complain_on_overflow */
80 ppc64_elf_sectoff_reloc, /* special_function */
81 "R_PPC64_SECTOFF_HI", /* name */
82 FALSE, /* partial_inplace */
83@@ -774,7 +774,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
84 16, /* bitsize */
85 FALSE, /* pc_relative */
86 0, /* bitpos */
87- complain_overflow_signed, /* complain_on_overflow */
88+ complain_overflow_dont, /* complain_on_overflow */
89 ppc64_elf_sectoff_ha_reloc, /* special_function */
90 "R_PPC64_SECTOFF_HA", /* name */
91 FALSE, /* partial_inplace */
92@@ -981,7 +981,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
93 16, /* bitsize */
94 FALSE, /* pc_relative */
95 0, /* bitpos */
96- complain_overflow_signed, /* complain_on_overflow */
97+ complain_overflow_dont, /* complain_on_overflow */
98 ppc64_elf_toc_reloc, /* special_function */
99 "R_PPC64_TOC16_HI", /* name */
100 FALSE, /* partial_inplace */
101@@ -1000,7 +1000,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
102 16, /* bitsize */
103 FALSE, /* pc_relative */
104 0, /* bitpos */
105- complain_overflow_signed, /* complain_on_overflow */
106+ complain_overflow_dont, /* complain_on_overflow */
107 ppc64_elf_toc_ha_reloc, /* special_function */
108 "R_PPC64_TOC16_HA", /* name */
109 FALSE, /* partial_inplace */
110@@ -1072,7 +1072,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
111 16, /* bitsize */
112 FALSE, /* pc_relative */
113 0, /* bitpos */
114- complain_overflow_signed, /* complain_on_overflow */
115+ complain_overflow_dont, /* complain_on_overflow */
116 ppc64_elf_unhandled_reloc, /* special_function */
117 "R_PPC64_PLTGOT16_HI", /* name */
118 FALSE, /* partial_inplace */
119@@ -1090,7 +1090,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
120 16, /* bitsize */
121 FALSE, /* pc_relative */
122 0, /* bitpos */
123- complain_overflow_signed, /* complain_on_overflow */
124+ complain_overflow_dont,/* complain_on_overflow */
125 ppc64_elf_unhandled_reloc, /* special_function */
126 "R_PPC64_PLTGOT16_HA", /* name */
127 FALSE, /* partial_inplace */
128@@ -1392,7 +1392,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
129 16, /* bitsize */
130 FALSE, /* pc_relative */
131 0, /* bitpos */
132- complain_overflow_signed, /* complain_on_overflow */
133+ complain_overflow_dont, /* complain_on_overflow */
134 ppc64_elf_unhandled_reloc, /* special_function */
135 "R_PPC64_DTPREL16_HI", /* name */
136 FALSE, /* partial_inplace */
137@@ -1407,7 +1407,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
138 16, /* bitsize */
139 FALSE, /* pc_relative */
140 0, /* bitpos */
141- complain_overflow_signed, /* complain_on_overflow */
142+ complain_overflow_dont, /* complain_on_overflow */
143 ppc64_elf_unhandled_reloc, /* special_function */
144 "R_PPC64_DTPREL16_HA", /* name */
145 FALSE, /* partial_inplace */
146@@ -1558,7 +1558,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
147 16, /* bitsize */
148 FALSE, /* pc_relative */
149 0, /* bitpos */
150- complain_overflow_signed, /* complain_on_overflow */
151+ complain_overflow_dont, /* complain_on_overflow */
152 ppc64_elf_unhandled_reloc, /* special_function */
153 "R_PPC64_TPREL16_HI", /* name */
154 FALSE, /* partial_inplace */
155@@ -1573,7 +1573,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
156 16, /* bitsize */
157 FALSE, /* pc_relative */
158 0, /* bitpos */
159- complain_overflow_signed, /* complain_on_overflow */
160+ complain_overflow_dont, /* complain_on_overflow */
161 ppc64_elf_unhandled_reloc, /* special_function */
162 "R_PPC64_TPREL16_HA", /* name */
163 FALSE, /* partial_inplace */
164@@ -1710,7 +1710,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
165 16, /* bitsize */
166 FALSE, /* pc_relative */
167 0, /* bitpos */
168- complain_overflow_signed, /* complain_on_overflow */
169+ complain_overflow_dont, /* complain_on_overflow */
170 ppc64_elf_unhandled_reloc, /* special_function */
171 "R_PPC64_GOT_TLSGD16_HI", /* name */
172 FALSE, /* partial_inplace */
173@@ -1725,7 +1725,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
174 16, /* bitsize */
175 FALSE, /* pc_relative */
176 0, /* bitpos */
177- complain_overflow_signed, /* complain_on_overflow */
178+ complain_overflow_dont, /* complain_on_overflow */
179 ppc64_elf_unhandled_reloc, /* special_function */
180 "R_PPC64_GOT_TLSGD16_HA", /* name */
181 FALSE, /* partial_inplace */
182@@ -1772,7 +1772,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
183 16, /* bitsize */
184 FALSE, /* pc_relative */
185 0, /* bitpos */
186- complain_overflow_signed, /* complain_on_overflow */
187+ complain_overflow_dont, /* complain_on_overflow */
188 ppc64_elf_unhandled_reloc, /* special_function */
189 "R_PPC64_GOT_TLSLD16_HI", /* name */
190 FALSE, /* partial_inplace */
191@@ -1787,7 +1787,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
192 16, /* bitsize */
193 FALSE, /* pc_relative */
194 0, /* bitpos */
195- complain_overflow_signed, /* complain_on_overflow */
196+ complain_overflow_dont, /* complain_on_overflow */
197 ppc64_elf_unhandled_reloc, /* special_function */
198 "R_PPC64_GOT_TLSLD16_HA", /* name */
199 FALSE, /* partial_inplace */
200@@ -1833,7 +1833,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
201 16, /* bitsize */
202 FALSE, /* pc_relative */
203 0, /* bitpos */
204- complain_overflow_signed, /* complain_on_overflow */
205+ complain_overflow_dont, /* complain_on_overflow */
206 ppc64_elf_unhandled_reloc, /* special_function */
207 "R_PPC64_GOT_DTPREL16_HI", /* name */
208 FALSE, /* partial_inplace */
209@@ -1848,7 +1848,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
210 16, /* bitsize */
211 FALSE, /* pc_relative */
212 0, /* bitpos */
213- complain_overflow_signed, /* complain_on_overflow */
214+ complain_overflow_dont, /* complain_on_overflow */
215 ppc64_elf_unhandled_reloc, /* special_function */
216 "R_PPC64_GOT_DTPREL16_HA", /* name */
217 FALSE, /* partial_inplace */
218@@ -1894,7 +1894,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
219 16, /* bitsize */
220 FALSE, /* pc_relative */
221 0, /* bitpos */
222- complain_overflow_signed, /* complain_on_overflow */
223+ complain_overflow_dont, /* complain_on_overflow */
224 ppc64_elf_unhandled_reloc, /* special_function */
225 "R_PPC64_GOT_TPREL16_HI", /* name */
226 FALSE, /* partial_inplace */
227@@ -1909,7 +1909,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
228 16, /* bitsize */
229 FALSE, /* pc_relative */
230 0, /* bitpos */
231- complain_overflow_signed, /* complain_on_overflow */
232+ complain_overflow_dont, /* complain_on_overflow */
233 ppc64_elf_unhandled_reloc, /* special_function */
234 "R_PPC64_GOT_TPREL16_HA", /* name */
235 FALSE, /* partial_inplace */
236@@ -1982,7 +1982,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
237 16, /* bitsize */
238 TRUE, /* pc_relative */
239 0, /* bitpos */
240- complain_overflow_signed, /* complain_on_overflow */
241+ complain_overflow_dont, /* complain_on_overflow */
242 bfd_elf_generic_reloc, /* special_function */
243 "R_PPC64_REL16_HI", /* name */
244 FALSE, /* partial_inplace */
245@@ -1998,7 +1998,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
246 16, /* bitsize */
247 TRUE, /* pc_relative */
248 0, /* bitpos */
249- complain_overflow_signed, /* complain_on_overflow */
250+ complain_overflow_dont, /* complain_on_overflow */
251 ppc64_elf_ha_reloc, /* special_function */
252 "R_PPC64_REL16_HA", /* name */
253 FALSE, /* partial_inplace */
254@@ -2006,96 +2006,6 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
255 0xffff, /* dst_mask */
256 TRUE), /* pcrel_offset */
257
258- /* Like R_PPC64_ADDR16_HI, but no overflow. */
259- HOWTO (R_PPC64_ADDR16_HIGH, /* type */
260- 16, /* rightshift */
261- 1, /* size (0 = byte, 1 = short, 2 = long) */
262- 16, /* bitsize */
263- FALSE, /* pc_relative */
264- 0, /* bitpos */
265- complain_overflow_dont, /* complain_on_overflow */
266- bfd_elf_generic_reloc, /* special_function */
267- "R_PPC64_ADDR16_HIGH", /* name */
268- FALSE, /* partial_inplace */
269- 0, /* src_mask */
270- 0xffff, /* dst_mask */
271- FALSE), /* pcrel_offset */
272-
273- /* Like R_PPC64_ADDR16_HA, but no overflow. */
274- HOWTO (R_PPC64_ADDR16_HIGHA, /* type */
275- 16, /* rightshift */
276- 1, /* size (0 = byte, 1 = short, 2 = long) */
277- 16, /* bitsize */
278- FALSE, /* pc_relative */
279- 0, /* bitpos */
280- complain_overflow_dont, /* complain_on_overflow */
281- ppc64_elf_ha_reloc, /* special_function */
282- "R_PPC64_ADDR16_HIGHA", /* name */
283- FALSE, /* partial_inplace */
284- 0, /* src_mask */
285- 0xffff, /* dst_mask */
286- FALSE), /* pcrel_offset */
287-
288- /* Like R_PPC64_DTPREL16_HI, but no overflow. */
289- HOWTO (R_PPC64_DTPREL16_HIGH,
290- 16, /* rightshift */
291- 1, /* size (0 = byte, 1 = short, 2 = long) */
292- 16, /* bitsize */
293- FALSE, /* pc_relative */
294- 0, /* bitpos */
295- complain_overflow_dont, /* complain_on_overflow */
296- ppc64_elf_unhandled_reloc, /* special_function */
297- "R_PPC64_DTPREL16_HIGH", /* name */
298- FALSE, /* partial_inplace */
299- 0, /* src_mask */
300- 0xffff, /* dst_mask */
301- FALSE), /* pcrel_offset */
302-
303- /* Like R_PPC64_DTPREL16_HA, but no overflow. */
304- HOWTO (R_PPC64_DTPREL16_HIGHA,
305- 16, /* rightshift */
306- 1, /* size (0 = byte, 1 = short, 2 = long) */
307- 16, /* bitsize */
308- FALSE, /* pc_relative */
309- 0, /* bitpos */
310- complain_overflow_dont, /* complain_on_overflow */
311- ppc64_elf_unhandled_reloc, /* special_function */
312- "R_PPC64_DTPREL16_HIGHA", /* name */
313- FALSE, /* partial_inplace */
314- 0, /* src_mask */
315- 0xffff, /* dst_mask */
316- FALSE), /* pcrel_offset */
317-
318- /* Like R_PPC64_TPREL16_HI, but no overflow. */
319- HOWTO (R_PPC64_TPREL16_HIGH,
320- 16, /* rightshift */
321- 1, /* size (0 = byte, 1 = short, 2 = long) */
322- 16, /* bitsize */
323- FALSE, /* pc_relative */
324- 0, /* bitpos */
325- complain_overflow_dont, /* complain_on_overflow */
326- ppc64_elf_unhandled_reloc, /* special_function */
327- "R_PPC64_TPREL16_HIGH", /* name */
328- FALSE, /* partial_inplace */
329- 0, /* src_mask */
330- 0xffff, /* dst_mask */
331- FALSE), /* pcrel_offset */
332-
333- /* Like R_PPC64_TPREL16_HA, but no overflow. */
334- HOWTO (R_PPC64_TPREL16_HIGHA,
335- 16, /* rightshift */
336- 1, /* size (0 = byte, 1 = short, 2 = long) */
337- 16, /* bitsize */
338- FALSE, /* pc_relative */
339- 0, /* bitpos */
340- complain_overflow_dont, /* complain_on_overflow */
341- ppc64_elf_unhandled_reloc, /* special_function */
342- "R_PPC64_TPREL16_HIGHA", /* name */
343- FALSE, /* partial_inplace */
344- 0, /* src_mask */
345- 0xffff, /* dst_mask */
346- FALSE), /* pcrel_offset */
347-
348 /* GNU extension to record C++ vtable hierarchy. */
349 HOWTO (R_PPC64_GNU_VTINHERIT, /* type */
350 0, /* rightshift */
351@@ -2174,12 +2084,8 @@ ppc64_elf_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
352 break;
353 case BFD_RELOC_HI16: r = R_PPC64_ADDR16_HI;
354 break;
355- case BFD_RELOC_PPC64_ADDR16_HIGH: r = R_PPC64_ADDR16_HIGH;
356- break;
357 case BFD_RELOC_HI16_S: r = R_PPC64_ADDR16_HA;
358 break;
359- case BFD_RELOC_PPC64_ADDR16_HIGHA: r = R_PPC64_ADDR16_HIGHA;
360- break;
361 case BFD_RELOC_PPC_BA16: r = R_PPC64_ADDR14;
362 break;
363 case BFD_RELOC_PPC_BA16_BRTAKEN: r = R_PPC64_ADDR14_BRTAKEN;
364@@ -2298,12 +2204,8 @@ ppc64_elf_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
365 break;
366 case BFD_RELOC_PPC_TPREL16_HI: r = R_PPC64_TPREL16_HI;
367 break;
368- case BFD_RELOC_PPC64_TPREL16_HIGH: r = R_PPC64_TPREL16_HIGH;
369- break;
370 case BFD_RELOC_PPC_TPREL16_HA: r = R_PPC64_TPREL16_HA;
371 break;
372- case BFD_RELOC_PPC64_TPREL16_HIGHA: r = R_PPC64_TPREL16_HIGHA;
373- break;
374 case BFD_RELOC_PPC_TPREL: r = R_PPC64_TPREL64;
375 break;
376 case BFD_RELOC_PPC_DTPREL16: r = R_PPC64_DTPREL16;
377@@ -2312,12 +2214,8 @@ ppc64_elf_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
378 break;
379 case BFD_RELOC_PPC_DTPREL16_HI: r = R_PPC64_DTPREL16_HI;
380 break;
381- case BFD_RELOC_PPC64_DTPREL16_HIGH: r = R_PPC64_DTPREL16_HIGH;
382- break;
383 case BFD_RELOC_PPC_DTPREL16_HA: r = R_PPC64_DTPREL16_HA;
384 break;
385- case BFD_RELOC_PPC64_DTPREL16_HIGHA: r = R_PPC64_DTPREL16_HIGHA;
386- break;
387 case BFD_RELOC_PPC_DTPREL: r = R_PPC64_DTPREL64;
388 break;
389 case BFD_RELOC_PPC_GOT_TLSGD16: r = R_PPC64_GOT_TLSGD16;
390@@ -3662,8 +3560,6 @@ must_be_dyn_reloc (struct bfd_link_info *info,
391 case R_PPC64_TPREL16_HA:
392 case R_PPC64_TPREL16_DS:
393 case R_PPC64_TPREL16_LO_DS:
394- case R_PPC64_TPREL16_HIGH:
395- case R_PPC64_TPREL16_HIGHA:
396 case R_PPC64_TPREL16_HIGHER:
397 case R_PPC64_TPREL16_HIGHERA:
398 case R_PPC64_TPREL16_HIGHEST:
399@@ -5394,8 +5290,6 @@ ppc64_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
400 case R_PPC64_DTPREL16_HA:
401 case R_PPC64_DTPREL16_DS:
402 case R_PPC64_DTPREL16_LO_DS:
403- case R_PPC64_DTPREL16_HIGH:
404- case R_PPC64_DTPREL16_HIGHA:
405 case R_PPC64_DTPREL16_HIGHER:
406 case R_PPC64_DTPREL16_HIGHERA:
407 case R_PPC64_DTPREL16_HIGHEST:
408@@ -5556,8 +5450,6 @@ ppc64_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
409 case R_PPC64_TPREL16_HA:
410 case R_PPC64_TPREL16_DS:
411 case R_PPC64_TPREL16_LO_DS:
412- case R_PPC64_TPREL16_HIGH:
413- case R_PPC64_TPREL16_HIGHA:
414 case R_PPC64_TPREL16_HIGHER:
415 case R_PPC64_TPREL16_HIGHERA:
416 case R_PPC64_TPREL16_HIGHEST:
417@@ -5605,8 +5497,6 @@ ppc64_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
418 case R_PPC64_ADDR16_DS:
419 case R_PPC64_ADDR16_HA:
420 case R_PPC64_ADDR16_HI:
421- case R_PPC64_ADDR16_HIGH:
422- case R_PPC64_ADDR16_HIGHA:
423 case R_PPC64_ADDR16_HIGHER:
424 case R_PPC64_ADDR16_HIGHERA:
425 case R_PPC64_ADDR16_HIGHEST:
426@@ -7363,8 +7253,6 @@ dec_dynrel_count (bfd_vma r_info,
427 case R_PPC64_TPREL16_HA:
428 case R_PPC64_TPREL16_DS:
429 case R_PPC64_TPREL16_LO_DS:
430- case R_PPC64_TPREL16_HIGH:
431- case R_PPC64_TPREL16_HIGHA:
432 case R_PPC64_TPREL16_HIGHER:
433 case R_PPC64_TPREL16_HIGHERA:
434 case R_PPC64_TPREL16_HIGHEST:
435@@ -7386,8 +7274,6 @@ dec_dynrel_count (bfd_vma r_info,
436 case R_PPC64_ADDR16_DS:
437 case R_PPC64_ADDR16_HA:
438 case R_PPC64_ADDR16_HI:
439- case R_PPC64_ADDR16_HIGH:
440- case R_PPC64_ADDR16_HIGHA:
441 case R_PPC64_ADDR16_HIGHER:
442 case R_PPC64_ADDR16_HIGHERA:
443 case R_PPC64_ADDR16_HIGHEST:
444@@ -14091,8 +13977,6 @@ ppc64_elf_relocate_section (bfd *output_bfd,
445 case R_PPC64_TPREL16_HA:
446 case R_PPC64_TPREL16_DS:
447 case R_PPC64_TPREL16_LO_DS:
448- case R_PPC64_TPREL16_HIGH:
449- case R_PPC64_TPREL16_HIGHA:
450 case R_PPC64_TPREL16_HIGHER:
451 case R_PPC64_TPREL16_HIGHERA:
452 case R_PPC64_TPREL16_HIGHEST:
453@@ -14127,8 +14011,6 @@ ppc64_elf_relocate_section (bfd *output_bfd,
454 case R_PPC64_DTPREL16_HA:
455 case R_PPC64_DTPREL16_DS:
456 case R_PPC64_DTPREL16_LO_DS:
457- case R_PPC64_DTPREL16_HIGH:
458- case R_PPC64_DTPREL16_HIGHA:
459 case R_PPC64_DTPREL16_HIGHER:
460 case R_PPC64_DTPREL16_HIGHERA:
461 case R_PPC64_DTPREL16_HIGHEST:
462@@ -14161,8 +14043,6 @@ ppc64_elf_relocate_section (bfd *output_bfd,
463 case R_PPC64_ADDR16_DS:
464 case R_PPC64_ADDR16_HA:
465 case R_PPC64_ADDR16_HI:
466- case R_PPC64_ADDR16_HIGH:
467- case R_PPC64_ADDR16_HIGHA:
468 case R_PPC64_ADDR16_HIGHER:
469 case R_PPC64_ADDR16_HIGHERA:
470 case R_PPC64_ADDR16_HIGHEST:
471@@ -14477,20 +14357,21 @@ ppc64_elf_relocate_section (bfd *output_bfd,
472 default:
473 break;
474
475- case R_PPC64_REL16_HA:
476 case R_PPC64_ADDR16_HA:
477- case R_PPC64_ADDR16_HIGHA:
478+ case R_PPC64_REL16_HA:
479 case R_PPC64_ADDR16_HIGHERA:
480 case R_PPC64_ADDR16_HIGHESTA:
481 case R_PPC64_TOC16_HA:
482 case R_PPC64_SECTOFF_HA:
483 case R_PPC64_TPREL16_HA:
484- case R_PPC64_TPREL16_HIGHA:
485+ case R_PPC64_DTPREL16_HA:
486+ case R_PPC64_TPREL16_HIGHER:
487 case R_PPC64_TPREL16_HIGHERA:
488+ case R_PPC64_TPREL16_HIGHEST:
489 case R_PPC64_TPREL16_HIGHESTA:
490- case R_PPC64_DTPREL16_HA:
491- case R_PPC64_DTPREL16_HIGHA:
492+ case R_PPC64_DTPREL16_HIGHER:
493 case R_PPC64_DTPREL16_HIGHERA:
494+ case R_PPC64_DTPREL16_HIGHEST:
495 case R_PPC64_DTPREL16_HIGHESTA:
496 /* It's just possible that this symbol is a weak symbol
497 that's not actually defined anywhere. In that case,
498diff --git a/bfd/reloc.c b/bfd/reloc.c
499index 77a04f8..cc34760 100644
500--- a/bfd/reloc.c
501+++ b/bfd/reloc.c
502@@ -2895,10 +2895,6 @@ ENUMX
503 BFD_RELOC_PPC64_PLTGOT16_DS
504 ENUMX
505 BFD_RELOC_PPC64_PLTGOT16_LO_DS
506-ENUMX
507- BFD_RELOC_PPC64_ADDR16_HIGH
508-ENUMX
509- BFD_RELOC_PPC64_ADDR16_HIGHA
510 ENUMDOC
511 Power(rs6000) and PowerPC relocations.
512
513@@ -2986,14 +2982,6 @@ ENUMX
514 BFD_RELOC_PPC64_DTPREL16_HIGHEST
515 ENUMX
516 BFD_RELOC_PPC64_DTPREL16_HIGHESTA
517-ENUMX
518- BFD_RELOC_PPC64_TPREL16_HIGH
519-ENUMX
520- BFD_RELOC_PPC64_TPREL16_HIGHA
521-ENUMX
522- BFD_RELOC_PPC64_DTPREL16_HIGH
523-ENUMX
524- BFD_RELOC_PPC64_DTPREL16_HIGHA
525 ENUMDOC
526 PowerPC and PowerPC64 thread-local storage relocations.
527
528diff --git a/elfcpp/powerpc.h b/elfcpp/powerpc.h
529index 98354a2..0f13eda 100644
530--- a/elfcpp/powerpc.h
531+++ b/elfcpp/powerpc.h
532@@ -164,17 +164,11 @@ enum
533 R_PPC_EMB_SDA21 = 109,
534 R_PPC64_TOCSAVE = 109,
535 R_PPC_EMB_MRKREF = 110,
536- R_PPC64_ADDR16_HIGH = 110,
537 R_PPC_EMB_RELSEC16 = 111,
538- R_PPC64_ADDR16_HIGHA = 111,
539 R_PPC_EMB_RELST_LO = 112,
540- R_PPC64_TPREL16_HIGH = 112,
541 R_PPC_EMB_RELST_HI = 113,
542- R_PPC64_TPREL16_HIGHA = 113,
543 R_PPC_EMB_RELST_HA = 114,
544- R_PPC64_DTPREL16_HIGH = 114,
545 R_PPC_EMB_BIT_FLD = 115,
546- R_PPC64_DTPREL16_HIGHA = 115,
547 R_PPC_EMB_RELSDA = 116,
548
549 R_PPC_VLE_REL8 = 216,
550diff --git a/gas/config/tc-ppc.c b/gas/config/tc-ppc.c
551index 7c99e43..d888aee 100644
552--- a/gas/config/tc-ppc.c
553+++ b/gas/config/tc-ppc.c
554@@ -87,11 +87,7 @@ static int set_target_endian = 0;
555 compensating for #lo being treated as a signed number. */
556 #define PPC_HIGHESTA(v) PPC_HIGHEST ((v) + 0x8000)
557
558-#define SEX16(val) (((val) ^ 0x8000) - 0x8000)
559-
560-/* For the time being on ppc64, don't report overflow on @h and @ha
561- applied to constants. */
562-#define REPORT_OVERFLOW_HI 0
563+#define SEX16(val) ((((val) & 0xffff) ^ 0x8000) - 0x8000)
564
565 static bfd_boolean reg_names_p = TARGET_REG_NAMES_P;
566
567@@ -1935,8 +1931,6 @@ ppc_elf_suffix (char **str_p, expressionS *exp_p)
568 MAP32 ("bitfld", BFD_RELOC_PPC_EMB_BIT_FLD),
569 MAP32 ("relsda", BFD_RELOC_PPC_EMB_RELSDA),
570 MAP32 ("xgot", BFD_RELOC_PPC_TOC16),
571- MAP64 ("high", BFD_RELOC_PPC64_ADDR16_HIGH),
572- MAP64 ("higha", BFD_RELOC_PPC64_ADDR16_HIGHA),
573 MAP64 ("higher", BFD_RELOC_PPC64_HIGHER),
574 MAP64 ("highera", BFD_RELOC_PPC64_HIGHER_S),
575 MAP64 ("highest", BFD_RELOC_PPC64_HIGHEST),
576@@ -1946,14 +1940,10 @@ ppc_elf_suffix (char **str_p, expressionS *exp_p)
577 MAP64 ("toc@l", BFD_RELOC_PPC64_TOC16_LO),
578 MAP64 ("toc@h", BFD_RELOC_PPC64_TOC16_HI),
579 MAP64 ("toc@ha", BFD_RELOC_PPC64_TOC16_HA),
580- MAP64 ("dtprel@high", BFD_RELOC_PPC64_DTPREL16_HIGH),
581- MAP64 ("dtprel@higha", BFD_RELOC_PPC64_DTPREL16_HIGHA),
582 MAP64 ("dtprel@higher", BFD_RELOC_PPC64_DTPREL16_HIGHER),
583 MAP64 ("dtprel@highera", BFD_RELOC_PPC64_DTPREL16_HIGHERA),
584 MAP64 ("dtprel@highest", BFD_RELOC_PPC64_DTPREL16_HIGHEST),
585 MAP64 ("dtprel@highesta", BFD_RELOC_PPC64_DTPREL16_HIGHESTA),
586- MAP64 ("tprel@high", BFD_RELOC_PPC64_TPREL16_HIGH),
587- MAP64 ("tprel@higha", BFD_RELOC_PPC64_TPREL16_HIGHA),
588 MAP64 ("tprel@higher", BFD_RELOC_PPC64_TPREL16_HIGHER),
589 MAP64 ("tprel@highera", BFD_RELOC_PPC64_TPREL16_HIGHERA),
590 MAP64 ("tprel@highest", BFD_RELOC_PPC64_TPREL16_HIGHEST),
591@@ -2923,76 +2913,55 @@ md_assemble (char *str)
592 break;
593
594 case BFD_RELOC_LO16:
595- ex.X_add_number &= 0xffff;
596- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
597+ /* X_unsigned is the default, so if the user has done
598+ something which cleared it, we always produce a
599+ signed value. */
600+ if (ex.X_unsigned && ! (operand->flags & PPC_OPERAND_SIGNED))
601+ ex.X_add_number &= 0xffff;
602+ else
603 ex.X_add_number = SEX16 (ex.X_add_number);
604 break;
605
606 case BFD_RELOC_HI16:
607- if (REPORT_OVERFLOW_HI && ppc_obj64)
608- {
609- /* PowerPC64 @h is tested for overflow. */
610- ex.X_add_number = (addressT) ex.X_add_number >> 16;
611- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
612- {
613- addressT sign = (((addressT) -1 >> 16) + 1) >> 1;
614- ex.X_add_number
615- = ((addressT) ex.X_add_number ^ sign) - sign;
616- }
617- break;
618- }
619- /* Fall thru */
620-
621- case BFD_RELOC_PPC64_ADDR16_HIGH:
622- ex.X_add_number = PPC_HI (ex.X_add_number);
623- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
624- ex.X_add_number = SEX16 (ex.X_add_number);
625+ if (ex.X_unsigned && ! (operand->flags & PPC_OPERAND_SIGNED))
626+ ex.X_add_number = PPC_HI (ex.X_add_number);
627+ else
628+ ex.X_add_number = SEX16 (PPC_HI (ex.X_add_number));
629 break;
630
631 case BFD_RELOC_HI16_S:
632- if (REPORT_OVERFLOW_HI && ppc_obj64)
633- {
634- /* PowerPC64 @ha is tested for overflow. */
635- ex.X_add_number
636- = ((addressT) ex.X_add_number + 0x8000) >> 16;
637- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
638- {
639- addressT sign = (((addressT) -1 >> 16) + 1) >> 1;
640- ex.X_add_number
641- = ((addressT) ex.X_add_number ^ sign) - sign;
642- }
643- break;
644- }
645- /* Fall thru */
646-
647- case BFD_RELOC_PPC64_ADDR16_HIGHA:
648- ex.X_add_number = PPC_HA (ex.X_add_number);
649- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
650- ex.X_add_number = SEX16 (ex.X_add_number);
651+ if (ex.X_unsigned && ! (operand->flags & PPC_OPERAND_SIGNED))
652+ ex.X_add_number = PPC_HA (ex.X_add_number);
653+ else
654+ ex.X_add_number = SEX16 (PPC_HA (ex.X_add_number));
655 break;
656
657 case BFD_RELOC_PPC64_HIGHER:
658- ex.X_add_number = PPC_HIGHER (ex.X_add_number);
659- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
660- ex.X_add_number = SEX16 (ex.X_add_number);
661+ if (ex.X_unsigned && ! (operand->flags & PPC_OPERAND_SIGNED))
662+ ex.X_add_number = PPC_HIGHER (ex.X_add_number);
663+ else
664+ ex.X_add_number = SEX16 (PPC_HIGHER (ex.X_add_number));
665 break;
666
667 case BFD_RELOC_PPC64_HIGHER_S:
668- ex.X_add_number = PPC_HIGHERA (ex.X_add_number);
669- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
670- ex.X_add_number = SEX16 (ex.X_add_number);
671+ if (ex.X_unsigned && ! (operand->flags & PPC_OPERAND_SIGNED))
672+ ex.X_add_number = PPC_HIGHERA (ex.X_add_number);
673+ else
674+ ex.X_add_number = SEX16 (PPC_HIGHERA (ex.X_add_number));
675 break;
676
677 case BFD_RELOC_PPC64_HIGHEST:
678- ex.X_add_number = PPC_HIGHEST (ex.X_add_number);
679- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
680- ex.X_add_number = SEX16 (ex.X_add_number);
681+ if (ex.X_unsigned && ! (operand->flags & PPC_OPERAND_SIGNED))
682+ ex.X_add_number = PPC_HIGHEST (ex.X_add_number);
683+ else
684+ ex.X_add_number = SEX16 (PPC_HIGHEST (ex.X_add_number));
685 break;
686
687 case BFD_RELOC_PPC64_HIGHEST_S:
688- ex.X_add_number = PPC_HIGHESTA (ex.X_add_number);
689- if ((operand->flags & PPC_OPERAND_SIGNED) != 0)
690- ex.X_add_number = SEX16 (ex.X_add_number);
691+ if (ex.X_unsigned && ! (operand->flags & PPC_OPERAND_SIGNED))
692+ ex.X_add_number = PPC_HIGHESTA (ex.X_add_number);
693+ else
694+ ex.X_add_number = SEX16 (PPC_HIGHESTA (ex.X_add_number));
695 break;
696 }
697 #endif /* OBJ_ELF */
698@@ -6566,51 +6535,25 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
699 fieldval = value & 0xffff;
700 sign_extend_16:
701 if (operand != NULL && (operand->flags & PPC_OPERAND_SIGNED) != 0)
702- fieldval = SEX16 (fieldval);
703+ fieldval = (fieldval ^ 0x8000) - 0x8000;
704 fixP->fx_no_overflow = 1;
705 break;
706
707- case BFD_RELOC_HI16:
708- case BFD_RELOC_HI16_PCREL:
709 #ifdef OBJ_ELF
710- if (REPORT_OVERFLOW_HI && ppc_obj64)
711- {
712- fieldval = value >> 16;
713- if (operand != NULL && (operand->flags & PPC_OPERAND_SIGNED) != 0)
714- {
715- valueT sign = (((valueT) -1 >> 16) + 1) >> 1;
716- fieldval = ((valueT) fieldval ^ sign) - sign;
717- }
718- break;
719- }
720- /* Fall thru */
721-
722 case BFD_RELOC_PPC_VLE_HI16A:
723 case BFD_RELOC_PPC_VLE_HI16D:
724- case BFD_RELOC_PPC64_ADDR16_HIGH:
725 #endif
726+ case BFD_RELOC_HI16:
727+ case BFD_RELOC_HI16_PCREL:
728 fieldval = PPC_HI (value);
729 goto sign_extend_16;
730
731- case BFD_RELOC_HI16_S:
732- case BFD_RELOC_HI16_S_PCREL:
733 #ifdef OBJ_ELF
734- if (REPORT_OVERFLOW_HI && ppc_obj64)
735- {
736- fieldval = (value + 0x8000) >> 16;
737- if (operand != NULL && (operand->flags & PPC_OPERAND_SIGNED) != 0)
738- {
739- valueT sign = (((valueT) -1 >> 16) + 1) >> 1;
740- fieldval = ((valueT) fieldval ^ sign) - sign;
741- }
742- break;
743- }
744- /* Fall thru */
745-
746 case BFD_RELOC_PPC_VLE_HA16A:
747 case BFD_RELOC_PPC_VLE_HA16D:
748- case BFD_RELOC_PPC64_ADDR16_HIGHA:
749 #endif
750+ case BFD_RELOC_HI16_S:
751+ case BFD_RELOC_HI16_S_PCREL:
752 fieldval = PPC_HA (value);
753 goto sign_extend_16;
754
755@@ -6673,14 +6616,10 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
756 case BFD_RELOC_PPC_GOT_DTPREL16_HA:
757 case BFD_RELOC_PPC64_TPREL16_DS:
758 case BFD_RELOC_PPC64_TPREL16_LO_DS:
759- case BFD_RELOC_PPC64_TPREL16_HIGH:
760- case BFD_RELOC_PPC64_TPREL16_HIGHA:
761 case BFD_RELOC_PPC64_TPREL16_HIGHER:
762 case BFD_RELOC_PPC64_TPREL16_HIGHERA:
763 case BFD_RELOC_PPC64_TPREL16_HIGHEST:
764 case BFD_RELOC_PPC64_TPREL16_HIGHESTA:
765- case BFD_RELOC_PPC64_DTPREL16_HIGH:
766- case BFD_RELOC_PPC64_DTPREL16_HIGHA:
767 case BFD_RELOC_PPC64_DTPREL16_DS:
768 case BFD_RELOC_PPC64_DTPREL16_LO_DS:
769 case BFD_RELOC_PPC64_DTPREL16_HIGHER:
770@@ -6866,8 +6805,6 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
771 case BFD_RELOC_PPC64_HIGHER_S:
772 case BFD_RELOC_PPC64_HIGHEST:
773 case BFD_RELOC_PPC64_HIGHEST_S:
774- case BFD_RELOC_PPC64_ADDR16_HIGH:
775- case BFD_RELOC_PPC64_ADDR16_HIGHA:
776 break;
777
778 case BFD_RELOC_PPC_DTPMOD:
779@@ -6944,14 +6881,10 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
780 case BFD_RELOC_PPC64_TOC16_LO:
781 case BFD_RELOC_PPC64_TOC16_HI:
782 case BFD_RELOC_PPC64_TOC16_HA:
783- case BFD_RELOC_PPC64_DTPREL16_HIGH:
784- case BFD_RELOC_PPC64_DTPREL16_HIGHA:
785 case BFD_RELOC_PPC64_DTPREL16_HIGHER:
786 case BFD_RELOC_PPC64_DTPREL16_HIGHERA:
787 case BFD_RELOC_PPC64_DTPREL16_HIGHEST:
788 case BFD_RELOC_PPC64_DTPREL16_HIGHESTA:
789- case BFD_RELOC_PPC64_TPREL16_HIGH:
790- case BFD_RELOC_PPC64_TPREL16_HIGHA:
791 case BFD_RELOC_PPC64_TPREL16_HIGHER:
792 case BFD_RELOC_PPC64_TPREL16_HIGHERA:
793 case BFD_RELOC_PPC64_TPREL16_HIGHEST:
794diff --git a/gold/powerpc.cc b/gold/powerpc.cc
795index 1aa4791..b8e932e 100644
796--- a/gold/powerpc.cc
797+++ b/gold/powerpc.cc
798@@ -5168,8 +5168,6 @@ Target_powerpc<size, big_endian>::Scan::check_non_pic(Relobj* object,
799 case elfcpp::R_PPC64_JMP_IREL:
800 case elfcpp::R_PPC64_ADDR16_DS:
801 case elfcpp::R_PPC64_ADDR16_LO_DS:
802- case elfcpp::R_PPC64_ADDR16_HIGH:
803- case elfcpp::R_PPC64_ADDR16_HIGHA:
804 case elfcpp::R_PPC64_ADDR16_HIGHER:
805 case elfcpp::R_PPC64_ADDR16_HIGHEST:
806 case elfcpp::R_PPC64_ADDR16_HIGHERA:
807@@ -5178,8 +5176,6 @@ Target_powerpc<size, big_endian>::Scan::check_non_pic(Relobj* object,
808 case elfcpp::R_POWERPC_ADDR30:
809 case elfcpp::R_PPC64_TPREL16_DS:
810 case elfcpp::R_PPC64_TPREL16_LO_DS:
811- case elfcpp::R_PPC64_TPREL16_HIGH:
812- case elfcpp::R_PPC64_TPREL16_HIGHA:
813 case elfcpp::R_PPC64_TPREL16_HIGHER:
814 case elfcpp::R_PPC64_TPREL16_HIGHEST:
815 case elfcpp::R_PPC64_TPREL16_HIGHERA:
816@@ -5354,6 +5350,7 @@ Target_powerpc<size, big_endian>::Scan::local(
817 case elfcpp::R_POWERPC_GNU_VTINHERIT:
818 case elfcpp::R_POWERPC_GNU_VTENTRY:
819 case elfcpp::R_PPC64_TOCSAVE:
820+ case elfcpp::R_PPC_EMB_MRKREF:
821 case elfcpp::R_POWERPC_TLS:
822 break;
823
824@@ -5391,8 +5388,6 @@ Target_powerpc<size, big_endian>::Scan::local(
825 case elfcpp::R_POWERPC_ADDR16_HI:
826 case elfcpp::R_POWERPC_ADDR16_HA:
827 case elfcpp::R_POWERPC_UADDR16:
828- case elfcpp::R_PPC64_ADDR16_HIGH:
829- case elfcpp::R_PPC64_ADDR16_HIGHA:
830 case elfcpp::R_PPC64_ADDR16_HIGHER:
831 case elfcpp::R_PPC64_ADDR16_HIGHERA:
832 case elfcpp::R_PPC64_ADDR16_HIGHEST:
833@@ -5451,35 +5446,31 @@ Target_powerpc<size, big_endian>::Scan::local(
834 case elfcpp::R_POWERPC_REL16_HI:
835 case elfcpp::R_POWERPC_REL16_HA:
836 case elfcpp::R_POWERPC_SECTOFF:
837- case elfcpp::R_POWERPC_SECTOFF_LO:
838- case elfcpp::R_POWERPC_SECTOFF_HI:
839- case elfcpp::R_POWERPC_SECTOFF_HA:
840- case elfcpp::R_PPC64_SECTOFF_DS:
841- case elfcpp::R_PPC64_SECTOFF_LO_DS:
842 case elfcpp::R_POWERPC_TPREL16:
843+ case elfcpp::R_POWERPC_DTPREL16:
844+ case elfcpp::R_POWERPC_SECTOFF_LO:
845 case elfcpp::R_POWERPC_TPREL16_LO:
846+ case elfcpp::R_POWERPC_DTPREL16_LO:
847+ case elfcpp::R_POWERPC_SECTOFF_HI:
848 case elfcpp::R_POWERPC_TPREL16_HI:
849+ case elfcpp::R_POWERPC_DTPREL16_HI:
850+ case elfcpp::R_POWERPC_SECTOFF_HA:
851 case elfcpp::R_POWERPC_TPREL16_HA:
852- case elfcpp::R_PPC64_TPREL16_DS:
853- case elfcpp::R_PPC64_TPREL16_LO_DS:
854- case elfcpp::R_PPC64_TPREL16_HIGH:
855- case elfcpp::R_PPC64_TPREL16_HIGHA:
856+ case elfcpp::R_POWERPC_DTPREL16_HA:
857+ case elfcpp::R_PPC64_DTPREL16_HIGHER:
858 case elfcpp::R_PPC64_TPREL16_HIGHER:
859+ case elfcpp::R_PPC64_DTPREL16_HIGHERA:
860 case elfcpp::R_PPC64_TPREL16_HIGHERA:
861+ case elfcpp::R_PPC64_DTPREL16_HIGHEST:
862 case elfcpp::R_PPC64_TPREL16_HIGHEST:
863+ case elfcpp::R_PPC64_DTPREL16_HIGHESTA:
864 case elfcpp::R_PPC64_TPREL16_HIGHESTA:
865- case elfcpp::R_POWERPC_DTPREL16:
866- case elfcpp::R_POWERPC_DTPREL16_LO:
867- case elfcpp::R_POWERPC_DTPREL16_HI:
868- case elfcpp::R_POWERPC_DTPREL16_HA:
869+ case elfcpp::R_PPC64_TPREL16_DS:
870+ case elfcpp::R_PPC64_TPREL16_LO_DS:
871 case elfcpp::R_PPC64_DTPREL16_DS:
872 case elfcpp::R_PPC64_DTPREL16_LO_DS:
873- case elfcpp::R_PPC64_DTPREL16_HIGH:
874- case elfcpp::R_PPC64_DTPREL16_HIGHA:
875- case elfcpp::R_PPC64_DTPREL16_HIGHER:
876- case elfcpp::R_PPC64_DTPREL16_HIGHERA:
877- case elfcpp::R_PPC64_DTPREL16_HIGHEST:
878- case elfcpp::R_PPC64_DTPREL16_HIGHESTA:
879+ case elfcpp::R_PPC64_SECTOFF_DS:
880+ case elfcpp::R_PPC64_SECTOFF_LO_DS:
881 case elfcpp::R_PPC64_TLSGD:
882 case elfcpp::R_PPC64_TLSLD:
883 break;
884@@ -5713,6 +5704,7 @@ Target_powerpc<size, big_endian>::Scan::global(
885 case elfcpp::R_POWERPC_GNU_VTINHERIT:
886 case elfcpp::R_POWERPC_GNU_VTENTRY:
887 case elfcpp::R_PPC_LOCAL24PC:
888+ case elfcpp::R_PPC_EMB_MRKREF:
889 case elfcpp::R_POWERPC_TLS:
890 break;
891
892@@ -5762,8 +5754,6 @@ Target_powerpc<size, big_endian>::Scan::global(
893 case elfcpp::R_POWERPC_ADDR16_HI:
894 case elfcpp::R_POWERPC_ADDR16_HA:
895 case elfcpp::R_POWERPC_UADDR16:
896- case elfcpp::R_PPC64_ADDR16_HIGH:
897- case elfcpp::R_PPC64_ADDR16_HIGHA:
898 case elfcpp::R_PPC64_ADDR16_HIGHER:
899 case elfcpp::R_PPC64_ADDR16_HIGHERA:
900 case elfcpp::R_PPC64_ADDR16_HIGHEST:
901@@ -5897,35 +5887,31 @@ Target_powerpc<size, big_endian>::Scan::global(
902 case elfcpp::R_POWERPC_REL16_HI:
903 case elfcpp::R_POWERPC_REL16_HA:
904 case elfcpp::R_POWERPC_SECTOFF:
905- case elfcpp::R_POWERPC_SECTOFF_LO:
906- case elfcpp::R_POWERPC_SECTOFF_HI:
907- case elfcpp::R_POWERPC_SECTOFF_HA:
908- case elfcpp::R_PPC64_SECTOFF_DS:
909- case elfcpp::R_PPC64_SECTOFF_LO_DS:
910 case elfcpp::R_POWERPC_TPREL16:
911+ case elfcpp::R_POWERPC_DTPREL16:
912+ case elfcpp::R_POWERPC_SECTOFF_LO:
913 case elfcpp::R_POWERPC_TPREL16_LO:
914+ case elfcpp::R_POWERPC_DTPREL16_LO:
915+ case elfcpp::R_POWERPC_SECTOFF_HI:
916 case elfcpp::R_POWERPC_TPREL16_HI:
917+ case elfcpp::R_POWERPC_DTPREL16_HI:
918+ case elfcpp::R_POWERPC_SECTOFF_HA:
919 case elfcpp::R_POWERPC_TPREL16_HA:
920- case elfcpp::R_PPC64_TPREL16_DS:
921- case elfcpp::R_PPC64_TPREL16_LO_DS:
922- case elfcpp::R_PPC64_TPREL16_HIGH:
923- case elfcpp::R_PPC64_TPREL16_HIGHA:
924+ case elfcpp::R_POWERPC_DTPREL16_HA:
925+ case elfcpp::R_PPC64_DTPREL16_HIGHER:
926 case elfcpp::R_PPC64_TPREL16_HIGHER:
927+ case elfcpp::R_PPC64_DTPREL16_HIGHERA:
928 case elfcpp::R_PPC64_TPREL16_HIGHERA:
929+ case elfcpp::R_PPC64_DTPREL16_HIGHEST:
930 case elfcpp::R_PPC64_TPREL16_HIGHEST:
931+ case elfcpp::R_PPC64_DTPREL16_HIGHESTA:
932 case elfcpp::R_PPC64_TPREL16_HIGHESTA:
933- case elfcpp::R_POWERPC_DTPREL16:
934- case elfcpp::R_POWERPC_DTPREL16_LO:
935- case elfcpp::R_POWERPC_DTPREL16_HI:
936- case elfcpp::R_POWERPC_DTPREL16_HA:
937+ case elfcpp::R_PPC64_TPREL16_DS:
938+ case elfcpp::R_PPC64_TPREL16_LO_DS:
939 case elfcpp::R_PPC64_DTPREL16_DS:
940 case elfcpp::R_PPC64_DTPREL16_LO_DS:
941- case elfcpp::R_PPC64_DTPREL16_HIGH:
942- case elfcpp::R_PPC64_DTPREL16_HIGHA:
943- case elfcpp::R_PPC64_DTPREL16_HIGHER:
944- case elfcpp::R_PPC64_DTPREL16_HIGHERA:
945- case elfcpp::R_PPC64_DTPREL16_HIGHEST:
946- case elfcpp::R_PPC64_DTPREL16_HIGHESTA:
947+ case elfcpp::R_PPC64_SECTOFF_DS:
948+ case elfcpp::R_PPC64_SECTOFF_LO_DS:
949 case elfcpp::R_PPC64_TLSGD:
950 case elfcpp::R_PPC64_TLSLD:
951 break;
952@@ -7098,10 +7084,8 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
953
954 case elfcpp::R_PPC64_TPREL16_DS:
955 case elfcpp::R_PPC64_TPREL16_LO_DS:
956- case elfcpp::R_PPC64_TPREL16_HIGH:
957- case elfcpp::R_PPC64_TPREL16_HIGHA:
958 if (size != 64)
959- // R_PPC_TLSGD, R_PPC_TLSLD, R_PPC_EMB_RELST_LO, R_PPC_EMB_RELST_HI
960+ // R_PPC_TLSGD and R_PPC_TLSLD
961 break;
962 case elfcpp::R_POWERPC_TPREL16:
963 case elfcpp::R_POWERPC_TPREL16_LO:
964@@ -7131,8 +7115,6 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
965 case elfcpp::R_POWERPC_DTPREL16_HI:
966 case elfcpp::R_POWERPC_DTPREL16_HA:
967 case elfcpp::R_POWERPC_DTPREL:
968- case elfcpp::R_PPC64_DTPREL16_HIGH:
969- case elfcpp::R_PPC64_DTPREL16_HIGHA:
970 // tls symbol values are relative to tls_segment()->vaddr()
971 value -= dtp_offset;
972 break;
973@@ -7273,34 +7255,6 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
974 overflow = Reloc::CHECK_BITFIELD;
975 break;
976
977- case elfcpp::R_POWERPC_ADDR16_HI:
978- case elfcpp::R_POWERPC_ADDR16_HA:
979- case elfcpp::R_POWERPC_GOT16_HI:
980- case elfcpp::R_POWERPC_GOT16_HA:
981- case elfcpp::R_POWERPC_PLT16_HI:
982- case elfcpp::R_POWERPC_PLT16_HA:
983- case elfcpp::R_POWERPC_SECTOFF_HI:
984- case elfcpp::R_POWERPC_SECTOFF_HA:
985- case elfcpp::R_PPC64_TOC16_HI:
986- case elfcpp::R_PPC64_TOC16_HA:
987- case elfcpp::R_PPC64_PLTGOT16_HI:
988- case elfcpp::R_PPC64_PLTGOT16_HA:
989- case elfcpp::R_POWERPC_TPREL16_HI:
990- case elfcpp::R_POWERPC_TPREL16_HA:
991- case elfcpp::R_POWERPC_DTPREL16_HI:
992- case elfcpp::R_POWERPC_DTPREL16_HA:
993- case elfcpp::R_POWERPC_GOT_TLSGD16_HI:
994- case elfcpp::R_POWERPC_GOT_TLSGD16_HA:
995- case elfcpp::R_POWERPC_GOT_TLSLD16_HI:
996- case elfcpp::R_POWERPC_GOT_TLSLD16_HA:
997- case elfcpp::R_POWERPC_GOT_TPREL16_HI:
998- case elfcpp::R_POWERPC_GOT_TPREL16_HA:
999- case elfcpp::R_POWERPC_GOT_DTPREL16_HI:
1000- case elfcpp::R_POWERPC_GOT_DTPREL16_HA:
1001- case elfcpp::R_POWERPC_REL16_HI:
1002- case elfcpp::R_POWERPC_REL16_HA:
1003- if (size == 32)
1004- break;
1005 case elfcpp::R_POWERPC_REL24:
1006 case elfcpp::R_PPC_PLTREL24:
1007 case elfcpp::R_PPC_LOCAL24PC:
1008@@ -7334,6 +7288,7 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
1009 case elfcpp::R_POWERPC_TLS:
1010 case elfcpp::R_POWERPC_GNU_VTINHERIT:
1011 case elfcpp::R_POWERPC_GNU_VTENTRY:
1012+ case elfcpp::R_PPC_EMB_MRKREF:
1013 break;
1014
1015 case elfcpp::R_PPC64_ADDR64:
1016@@ -7404,12 +7359,6 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
1017 status = Reloc::addr16_u(view, value, overflow);
1018 break;
1019
1020- case elfcpp::R_PPC64_ADDR16_HIGH:
1021- case elfcpp::R_PPC64_TPREL16_HIGH:
1022- case elfcpp::R_PPC64_DTPREL16_HIGH:
1023- if (size == 32)
1024- // R_PPC_EMB_MRKREF, R_PPC_EMB_RELST_LO, R_PPC_EMB_RELST_HA
1025- goto unsupp;
1026 case elfcpp::R_POWERPC_ADDR16_HI:
1027 case elfcpp::R_POWERPC_REL16_HI:
1028 case elfcpp::R_PPC64_TOC16_HI:
1029@@ -7424,12 +7373,6 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
1030 Reloc::addr16_hi(view, value);
1031 break;
1032
1033- case elfcpp::R_PPC64_ADDR16_HIGHA:
1034- case elfcpp::R_PPC64_TPREL16_HIGHA:
1035- case elfcpp::R_PPC64_DTPREL16_HIGHA:
1036- if (size == 32)
1037- // R_PPC_EMB_RELSEC16, R_PPC_EMB_RELST_HI, R_PPC_EMB_BIT_FLD
1038- goto unsupp;
1039 case elfcpp::R_POWERPC_ADDR16_HA:
1040 case elfcpp::R_POWERPC_REL16_HA:
1041 case elfcpp::R_PPC64_TOC16_HA:
1042@@ -7554,6 +7497,11 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
1043 case elfcpp::R_PPC64_PLT16_LO_DS:
1044 case elfcpp::R_PPC64_PLTGOT16_DS:
1045 case elfcpp::R_PPC64_PLTGOT16_LO_DS:
1046+ case elfcpp::R_PPC_EMB_RELSEC16:
1047+ case elfcpp::R_PPC_EMB_RELST_LO:
1048+ case elfcpp::R_PPC_EMB_RELST_HI:
1049+ case elfcpp::R_PPC_EMB_RELST_HA:
1050+ case elfcpp::R_PPC_EMB_BIT_FLD:
1051 case elfcpp::R_PPC_EMB_RELSDA:
1052 case elfcpp::R_PPC_TOC16:
1053 default:
1054diff --git a/include/elf/ppc64.h b/include/elf/ppc64.h
1055index 78d947b..5888460 100644
1056--- a/include/elf/ppc64.h
1057+++ b/include/elf/ppc64.h
1058@@ -141,14 +141,6 @@ START_RELOC_NUMBERS (elf_ppc64_reloc_type)
1059 RELOC_NUMBER (R_PPC64_TLSLD, 108)
1060 RELOC_NUMBER (R_PPC64_TOCSAVE, 109)
1061
1062-/* Added when HA and HI relocs were changed to report overflows. */
1063- RELOC_NUMBER (R_PPC64_ADDR16_HIGH, 110)
1064- RELOC_NUMBER (R_PPC64_ADDR16_HIGHA, 111)
1065- RELOC_NUMBER (R_PPC64_TPREL16_HIGH, 112)
1066- RELOC_NUMBER (R_PPC64_TPREL16_HIGHA, 113)
1067- RELOC_NUMBER (R_PPC64_DTPREL16_HIGH, 114)
1068- RELOC_NUMBER (R_PPC64_DTPREL16_HIGHA, 115)
1069-
1070 #ifndef RELOC_MACROS_GEN_FUNC
1071 /* Fake relocation only used internally by ld. */
1072 RELOC_NUMBER (R_PPC64_LO_DS_OPT, 128)
1073@@ -169,9 +161,8 @@ START_RELOC_NUMBERS (elf_ppc64_reloc_type)
1074
1075 END_RELOC_NUMBERS (R_PPC64_max)
1076
1077-#define IS_PPC64_TLS_RELOC(R) \
1078- (((R) >= R_PPC64_TLS && (R) <= R_PPC64_DTPREL16_HIGHESTA) \
1079- || ((R) >= R_PPC64_TPREL16_HIGH && (R) <= R_PPC64_DTPREL16_HIGHA))
1080+#define IS_PPC64_TLS_RELOC(R) \
1081+ ((R) >= R_PPC64_TLS && (R) <= R_PPC64_DTPREL16_HIGHESTA)
1082
1083
1084 /* e_flags bits specifying ABI.
1085--
10861.7.9.5
1087