]> git.ipfire.org Git - thirdparty/glibc.git/blob - sysdeps/arm/dl-machine.h
Update ARM for ABIVERSION changes.
[thirdparty/glibc.git] / sysdeps / arm / dl-machine.h
1 /* Machine-dependent ELF dynamic relocation inline functions. ARM version.
2 Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,
3 2006, 2009, 2010 Free Software Foundation, Inc.
4 This file is part of the GNU C Library.
5
6 The GNU C Library is free software; you can redistribute it and/or
7 modify it under the terms of the GNU Lesser General Public
8 License as published by the Free Software Foundation; either
9 version 2.1 of the License, or (at your option) any later version.
10
11 The GNU C Library is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 Lesser General Public License for more details.
15
16 You should have received a copy of the GNU Lesser General Public
17 License along with the GNU C Library; if not, write to the Free
18 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
19 02111-1307 USA. */
20
21 #ifndef dl_machine_h
22 #define dl_machine_h
23
24 #define ELF_MACHINE_NAME "ARM"
25
26 #include <sys/param.h>
27 #include <tls.h>
28
29 #define CLEAR_CACHE(BEG,END) \
30 INTERNAL_SYSCALL_ARM (cacheflush, , 3, (BEG), (END), 0)
31
32 /* Return nonzero iff ELF header is compatible with the running host. */
33 static inline int __attribute__ ((unused))
34 elf_machine_matches_host (const Elf32_Ehdr *ehdr)
35 {
36 return ehdr->e_machine == EM_ARM;
37 }
38
39
40 /* Return the link-time address of _DYNAMIC. Conveniently, this is the
41 first element of the GOT. We used to use the PIC register to do this
42 without a constant pool reference, but GCC 4.2 will use a pseudo-register
43 for the PIC base, so it may not be in r10. */
44 static inline Elf32_Addr __attribute__ ((unused))
45 elf_machine_dynamic (void)
46 {
47 Elf32_Addr dynamic;
48 #ifdef __thumb2__
49 long tmp;
50 asm ("ldr\t%0, 1f\n\t"
51 "adr\t%1, 1f\n\t"
52 "ldr\t%0, [%0, %1]\n\t"
53 "b 2f\n"
54 ".align 2\n"
55 "1: .word _GLOBAL_OFFSET_TABLE_ - 1b\n"
56 "2:" : "=r" (dynamic), "=r"(tmp));
57 #else
58 asm ("ldr %0, 2f\n"
59 "1: ldr %0, [pc, %0]\n"
60 "b 3f\n"
61 "2: .word _GLOBAL_OFFSET_TABLE_ - (1b+8)\n"
62 "3:" : "=r" (dynamic));
63 #endif
64 return dynamic;
65 }
66
67
68 /* Return the run-time load address of the shared object. */
69 static inline Elf32_Addr __attribute__ ((unused))
70 elf_machine_load_address (void)
71 {
72 extern void __dl_start asm ("_dl_start");
73 Elf32_Addr got_addr = (Elf32_Addr) &__dl_start;
74 Elf32_Addr pcrel_addr;
75 #ifdef __thumb__
76 /* Clear the low bit of the funciton address. */
77 got_addr &= ~(Elf32_Addr) 1;
78 #endif
79 asm ("adr %0, _dl_start" : "=r" (pcrel_addr));
80 return pcrel_addr - got_addr;
81 }
82
83
84 /* Set up the loaded object described by L so its unrelocated PLT
85 entries will jump to the on-demand fixup code in dl-runtime.c. */
86
87 static inline int __attribute__ ((unused))
88 elf_machine_runtime_setup (struct link_map *l, int lazy, int profile)
89 {
90 Elf32_Addr *got;
91 extern void _dl_runtime_resolve (Elf32_Word);
92 extern void _dl_runtime_profile (Elf32_Word);
93
94 if (l->l_info[DT_JMPREL] && lazy)
95 {
96 /* patb: this is different than i386 */
97 /* The GOT entries for functions in the PLT have not yet been filled
98 in. Their initial contents will arrange when called to push an
99 index into the .got section, load ip with &_GLOBAL_OFFSET_TABLE_[3],
100 and then jump to _GLOBAL_OFFSET_TABLE[2]. */
101 got = (Elf32_Addr *) D_PTR (l, l_info[DT_PLTGOT]);
102 /* If a library is prelinked but we have to relocate anyway,
103 we have to be able to undo the prelinking of .got.plt.
104 The prelinker saved us here address of .plt. */
105 if (got[1])
106 l->l_mach.plt = got[1] + l->l_addr;
107 got[1] = (Elf32_Addr) l; /* Identify this shared object. */
108
109 /* The got[2] entry contains the address of a function which gets
110 called to get the address of a so far unresolved function and
111 jump to it. The profiling extension of the dynamic linker allows
112 to intercept the calls to collect information. In this case we
113 don't store the address in the GOT so that all future calls also
114 end in this function. */
115 if (profile)
116 {
117 got[2] = (Elf32_Addr) &_dl_runtime_profile;
118
119 if (GLRO(dl_profile) != NULL
120 && _dl_name_match_p (GLRO(dl_profile), l))
121 /* Say that we really want profiling and the timers are
122 started. */
123 GL(dl_profile_map) = l;
124 }
125 else
126 /* This function will get called to fix up the GOT entry indicated by
127 the offset on the stack, and then jump to the resolved address. */
128 got[2] = (Elf32_Addr) &_dl_runtime_resolve;
129 }
130 return lazy;
131 }
132
133 #if defined(__USE_BX__)
134 #define BX(x) "bx\t" #x
135 #else
136 #define BX(x) "mov\tpc, " #x
137 #endif
138
139 /* Mask identifying addresses reserved for the user program,
140 where the dynamic linker should not map anything. */
141 #define ELF_MACHINE_USER_ADDRESS_MASK 0xf8000000UL
142
143 /* Initial entry point code for the dynamic linker.
144 The C function `_dl_start' is the real entry point;
145 its return value is the user program's entry point. */
146
147 #define RTLD_START asm ("\
148 .text\n\
149 .globl _start\n\
150 .type _start, %function\n\
151 .globl _dl_start_user\n\
152 .type _dl_start_user, %function\n\
153 _start:\n\
154 @ we are PIC code, so get global offset table\n\
155 ldr sl, .L_GET_GOT\n\
156 @ See if we were run as a command with the executable file\n\
157 @ name as an extra leading argument.\n\
158 ldr r4, .L_SKIP_ARGS\n\
159 @ at start time, all the args are on the stack\n\
160 mov r0, sp\n\
161 bl _dl_start\n\
162 @ returns user entry point in r0\n\
163 _dl_start_user:\n\
164 adr r6, .L_GET_GOT\n\
165 add sl, sl, r6\n\
166 ldr r4, [sl, r4]\n\
167 @ save the entry point in another register\n\
168 mov r6, r0\n\
169 @ get the original arg count\n\
170 ldr r1, [sp]\n\
171 @ get the argv address\n\
172 add r2, sp, #4\n\
173 @ Fix up the stack if necessary.\n\
174 cmp r4, #0\n\
175 bne .L_fixup_stack\n\
176 .L_done_fixup:\n\
177 @ compute envp\n\
178 add r3, r2, r1, lsl #2\n\
179 add r3, r3, #4\n\
180 @ now we call _dl_init\n\
181 ldr r0, .L_LOADED\n\
182 ldr r0, [sl, r0]\n\
183 @ call _dl_init\n\
184 bl _dl_init_internal(PLT)\n\
185 @ load the finalizer function\n\
186 ldr r0, .L_FINI_PROC\n\
187 add r0, sl, r0\n\
188 @ jump to the user_s entry point\n\
189 " BX(r6) "\n\
190 \n\
191 @ iWMMXt and EABI targets require the stack to be eight byte\n\
192 @ aligned - shuffle arguments etc.\n\
193 .L_fixup_stack:\n\
194 @ subtract _dl_skip_args from original arg count\n\
195 sub r1, r1, r4\n\
196 @ store the new argc in the new stack location\n\
197 str r1, [sp]\n\
198 @ find the first unskipped argument\n\
199 mov r3, r2\n\
200 add r4, r2, r4, lsl #2\n\
201 @ shuffle argv down\n\
202 1: ldr r5, [r4], #4\n\
203 str r5, [r3], #4\n\
204 cmp r5, #0\n\
205 bne 1b\n\
206 @ shuffle envp down\n\
207 1: ldr r5, [r4], #4\n\
208 str r5, [r3], #4\n\
209 cmp r5, #0\n\
210 bne 1b\n\
211 @ shuffle auxv down\n\
212 1: ldmia r4!, {r0, r5}\n\
213 stmia r3!, {r0, r5}\n\
214 cmp r0, #0\n\
215 bne 1b\n\
216 @ Update _dl_argv\n\
217 ldr r3, .L_ARGV\n\
218 str r2, [sl, r3]\n\
219 b .L_done_fixup\n\
220 \n\
221 .L_GET_GOT:\n\
222 .word _GLOBAL_OFFSET_TABLE_ - .L_GET_GOT\n\
223 .L_SKIP_ARGS:\n\
224 .word _dl_skip_args(GOTOFF)\n\
225 .L_FINI_PROC:\n\
226 .word _dl_fini(GOTOFF)\n\
227 .L_ARGV:\n\
228 .word _dl_argv(GOTOFF)\n\
229 .L_LOADED:\n\
230 .word _rtld_local(GOTOFF)\n\
231 .previous\n\
232 ");
233
234 /* ELF_RTYPE_CLASS_PLT iff TYPE describes relocation of a PLT entry or
235 TLS variable, so undefined references should not be allowed to
236 define the value.
237 ELF_RTYPE_CLASS_NOCOPY iff TYPE should not be allowed to resolve to one
238 of the main executable's symbols, as for a COPY reloc. */
239 #if defined USE_TLS && (!defined RTLD_BOOTSTRAP || USE___THREAD)
240 # define elf_machine_type_class(type) \
241 ((((type) == R_ARM_JUMP_SLOT || (type) == R_ARM_TLS_DTPMOD32 \
242 || (type) == R_ARM_TLS_DTPOFF32 || (type) == R_ARM_TLS_TPOFF32) \
243 * ELF_RTYPE_CLASS_PLT) \
244 | (((type) == R_ARM_COPY) * ELF_RTYPE_CLASS_COPY))
245 #else
246 #define elf_machine_type_class(type) \
247 ((((type) == R_ARM_JUMP_SLOT) * ELF_RTYPE_CLASS_PLT) \
248 | (((type) == R_ARM_COPY) * ELF_RTYPE_CLASS_COPY))
249 #endif
250
251 /* A reloc type used for ld.so cmdline arg lookups to reject PLT entries. */
252 #define ELF_MACHINE_JMP_SLOT R_ARM_JUMP_SLOT
253
254 /* ARM never uses Elf32_Rela relocations for the dynamic linker.
255 Prelinked libraries may use Elf32_Rela though. */
256 #define ELF_MACHINE_PLT_REL 1
257
258 /* We define an initialization functions. This is called very early in
259 _dl_sysdep_start. */
260 #define DL_PLATFORM_INIT dl_platform_init ()
261
262 static inline void __attribute__ ((unused))
263 dl_platform_init (void)
264 {
265 if (GLRO(dl_platform) != NULL && *GLRO(dl_platform) == '\0')
266 /* Avoid an empty string which would disturb us. */
267 GLRO(dl_platform) = NULL;
268 }
269
270 static inline Elf32_Addr
271 elf_machine_fixup_plt (struct link_map *map, lookup_t t,
272 const Elf32_Rel *reloc,
273 Elf32_Addr *reloc_addr, Elf32_Addr value)
274 {
275 return *reloc_addr = value;
276 }
277
278 /* Return the final value of a plt relocation. */
279 static inline Elf32_Addr
280 elf_machine_plt_value (struct link_map *map, const Elf32_Rel *reloc,
281 Elf32_Addr value)
282 {
283 return value;
284 }
285
286 #endif /* !dl_machine_h */
287
288
289 /* ARM never uses Elf32_Rela relocations for the dynamic linker.
290 Prelinked libraries may use Elf32_Rela though. */
291 #define ELF_MACHINE_NO_RELA defined RTLD_BOOTSTRAP
292
293 /* Names of the architecture-specific auditing callback functions. */
294 #define ARCH_LA_PLTENTER arm_gnu_pltenter
295 #define ARCH_LA_PLTEXIT arm_gnu_pltexit
296
297 #ifdef RESOLVE_MAP
298
299 /* Deal with an out-of-range PC24 reloc. */
300 auto Elf32_Addr
301 fix_bad_pc24 (Elf32_Addr *const reloc_addr, Elf32_Addr value)
302 {
303 static void *fix_page;
304 static unsigned int fix_offset;
305 static size_t pagesize;
306 Elf32_Word *fix_address;
307
308 if (! fix_page)
309 {
310 if (! pagesize)
311 pagesize = getpagesize ();
312 fix_page = mmap (NULL, pagesize, PROT_READ | PROT_WRITE | PROT_EXEC,
313 MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
314 if (! fix_page)
315 assert (! "could not map page for fixup");
316 fix_offset = 0;
317 }
318
319 fix_address = (Elf32_Word *)(fix_page + fix_offset);
320 fix_address[0] = 0xe51ff004; /* ldr pc, [pc, #-4] */
321 fix_address[1] = value;
322
323 fix_offset += 8;
324 if (fix_offset >= pagesize)
325 fix_page = NULL;
326
327 return (Elf32_Addr)fix_address;
328 }
329
330 /* Perform the relocation specified by RELOC and SYM (which is fully resolved).
331 MAP is the object containing the reloc. */
332
333 auto inline void
334 __attribute__ ((always_inline))
335 elf_machine_rel (struct link_map *map, const Elf32_Rel *reloc,
336 const Elf32_Sym *sym, const struct r_found_version *version,
337 void *const reloc_addr_arg)
338 {
339 Elf32_Addr *const reloc_addr = reloc_addr_arg;
340 const unsigned int r_type = ELF32_R_TYPE (reloc->r_info);
341
342 #if !defined RTLD_BOOTSTRAP || !defined HAVE_Z_COMBRELOC
343 if (__builtin_expect (r_type == R_ARM_RELATIVE, 0))
344 {
345 # if !defined RTLD_BOOTSTRAP && !defined HAVE_Z_COMBRELOC
346 /* This is defined in rtld.c, but nowhere in the static libc.a;
347 make the reference weak so static programs can still link.
348 This declaration cannot be done when compiling rtld.c
349 (i.e. #ifdef RTLD_BOOTSTRAP) because rtld.c contains the
350 common defn for _dl_rtld_map, which is incompatible with a
351 weak decl in the same file. */
352 # ifndef SHARED
353 weak_extern (_dl_rtld_map);
354 # endif
355 if (map != &GL(dl_rtld_map)) /* Already done in rtld itself. */
356 # endif
357 *reloc_addr += map->l_addr;
358 }
359 # ifndef RTLD_BOOTSTRAP
360 else if (__builtin_expect (r_type == R_ARM_NONE, 0))
361 return;
362 # endif
363 else
364 #endif
365 {
366 const Elf32_Sym *const refsym = sym;
367 struct link_map *sym_map = RESOLVE_MAP (&sym, version, r_type);
368 Elf32_Addr value = sym_map == NULL ? 0 : sym_map->l_addr + sym->st_value;
369
370 switch (r_type)
371 {
372 case R_ARM_COPY:
373 if (sym == NULL)
374 /* This can happen in trace mode if an object could not be
375 found. */
376 break;
377 if (sym->st_size > refsym->st_size
378 || (GLRO(dl_verbose) && sym->st_size < refsym->st_size))
379 {
380 const char *strtab;
381
382 strtab = (const void *) D_PTR (map, l_info[DT_STRTAB]);
383 _dl_error_printf ("\
384 %s: Symbol `%s' has different size in shared object, consider re-linking\n",
385 rtld_progname ?: "<program name unknown>",
386 strtab + refsym->st_name);
387 }
388 memcpy (reloc_addr_arg, (void *) value,
389 MIN (sym->st_size, refsym->st_size));
390 break;
391 case R_ARM_GLOB_DAT:
392 case R_ARM_JUMP_SLOT:
393 # ifdef RTLD_BOOTSTRAP
394 /* Fix weak undefined references. */
395 if (sym != NULL && sym->st_value == 0)
396 *reloc_addr = 0;
397 else
398 # endif
399 *reloc_addr = value;
400 break;
401 case R_ARM_ABS32:
402 {
403 # ifndef RTLD_BOOTSTRAP
404 /* This is defined in rtld.c, but nowhere in the static
405 libc.a; make the reference weak so static programs can
406 still link. This declaration cannot be done when
407 compiling rtld.c (i.e. #ifdef RTLD_BOOTSTRAP) because
408 rtld.c contains the common defn for _dl_rtld_map, which
409 is incompatible with a weak decl in the same file. */
410 # ifndef SHARED
411 weak_extern (_dl_rtld_map);
412 # endif
413 if (map == &GL(dl_rtld_map))
414 /* Undo the relocation done here during bootstrapping.
415 Now we will relocate it anew, possibly using a
416 binding found in the user program or a loaded library
417 rather than the dynamic linker's built-in definitions
418 used while loading those libraries. */
419 value -= map->l_addr + refsym->st_value;
420 # endif
421 *reloc_addr += value;
422 break;
423 }
424 case R_ARM_PC24:
425 {
426 Elf32_Sword addend;
427 Elf32_Addr newvalue, topbits;
428
429 addend = *reloc_addr & 0x00ffffff;
430 if (addend & 0x00800000) addend |= 0xff000000;
431
432 newvalue = value - (Elf32_Addr)reloc_addr + (addend << 2);
433 topbits = newvalue & 0xfe000000;
434 if (topbits != 0xfe000000 && topbits != 0x00000000)
435 {
436 newvalue = fix_bad_pc24(reloc_addr, value)
437 - (Elf32_Addr)reloc_addr + (addend << 2);
438 topbits = newvalue & 0xfe000000;
439 if (topbits != 0xfe000000 && topbits != 0x00000000)
440 {
441 _dl_signal_error (0, map->l_name, NULL,
442 "R_ARM_PC24 relocation out of range");
443 }
444 }
445 newvalue >>= 2;
446 value = (*reloc_addr & 0xff000000) | (newvalue & 0x00ffffff);
447 *reloc_addr = value;
448 }
449 break;
450 #if defined USE_TLS && !defined RTLD_BOOTSTRAP
451 case R_ARM_TLS_DTPMOD32:
452 /* Get the information from the link map returned by the
453 resolv function. */
454 if (sym_map != NULL)
455 *reloc_addr = sym_map->l_tls_modid;
456 break;
457
458 case R_ARM_TLS_DTPOFF32:
459 if (sym != NULL)
460 *reloc_addr += sym->st_value;
461 break;
462
463 case R_ARM_TLS_TPOFF32:
464 if (sym != NULL)
465 {
466 CHECK_STATIC_TLS (map, sym_map);
467 *reloc_addr += sym->st_value + sym_map->l_tls_offset;
468 }
469 break;
470 #endif
471 default:
472 _dl_reloc_bad_type (map, r_type, 0);
473 break;
474 }
475 }
476 }
477
478 # ifndef RTLD_BOOTSTRAP
479 auto inline void
480 __attribute__ ((always_inline))
481 elf_machine_rela (struct link_map *map, const Elf32_Rela *reloc,
482 const Elf32_Sym *sym, const struct r_found_version *version,
483 void *const reloc_addr_arg)
484 {
485 Elf32_Addr *const reloc_addr = reloc_addr_arg;
486 const unsigned int r_type = ELF32_R_TYPE (reloc->r_info);
487
488 if (__builtin_expect (r_type == R_ARM_RELATIVE, 0))
489 *reloc_addr = map->l_addr + reloc->r_addend;
490 else if (__builtin_expect (r_type == R_ARM_NONE, 0))
491 return;
492 else
493 {
494 # ifndef RESOLVE_CONFLICT_FIND_MAP
495 const Elf32_Sym *const refsym = sym;
496 # endif
497 struct link_map *sym_map = RESOLVE_MAP (&sym, version, r_type);
498 Elf32_Addr value = sym_map == NULL ? 0 : sym_map->l_addr + sym->st_value;
499
500 switch (r_type)
501 {
502 # ifndef RESOLVE_CONFLICT_FIND_MAP
503 /* Not needed for dl-conflict.c. */
504 case R_ARM_COPY:
505 if (sym == NULL)
506 /* This can happen in trace mode if an object could not be
507 found. */
508 break;
509 if (sym->st_size > refsym->st_size
510 || (GLRO(dl_verbose) && sym->st_size < refsym->st_size))
511 {
512 const char *strtab;
513
514 strtab = (const void *) D_PTR (map, l_info[DT_STRTAB]);
515 _dl_error_printf ("\
516 %s: Symbol `%s' has different size in shared object, consider re-linking\n",
517 rtld_progname ?: "<program name unknown>",
518 strtab + refsym->st_name);
519 }
520 memcpy (reloc_addr_arg, (void *) value,
521 MIN (sym->st_size, refsym->st_size));
522 break;
523 # endif /* !RESOLVE_CONFLICT_FIND_MAP */
524 case R_ARM_GLOB_DAT:
525 case R_ARM_JUMP_SLOT:
526 case R_ARM_ABS32:
527 *reloc_addr = value + reloc->r_addend;
528 break;
529 case R_ARM_PC24:
530 {
531 Elf32_Addr newvalue, topbits;
532
533 newvalue = value + reloc->r_addend - (Elf32_Addr)reloc_addr;
534 topbits = newvalue & 0xfe000000;
535 if (topbits != 0xfe000000 && topbits != 0x00000000)
536 {
537 newvalue = fix_bad_pc24(reloc_addr, value)
538 - (Elf32_Addr)reloc_addr + (reloc->r_addend << 2);
539 topbits = newvalue & 0xfe000000;
540 if (topbits != 0xfe000000 && topbits != 0x00000000)
541 {
542 _dl_signal_error (0, map->l_name, NULL,
543 "R_ARM_PC24 relocation out of range");
544 }
545 }
546 newvalue >>= 2;
547 value = (*reloc_addr & 0xff000000) | (newvalue & 0x00ffffff);
548 *reloc_addr = value;
549 }
550 break;
551 #if defined USE_TLS && !defined RTLD_BOOTSTRAP
552 case R_ARM_TLS_DTPMOD32:
553 /* Get the information from the link map returned by the
554 resolv function. */
555 if (sym_map != NULL)
556 *reloc_addr = sym_map->l_tls_modid;
557 break;
558
559 case R_ARM_TLS_DTPOFF32:
560 *reloc_addr = (sym == NULL ? 0 : sym->st_value) + reloc->r_addend;
561 break;
562
563 case R_ARM_TLS_TPOFF32:
564 if (sym != NULL)
565 {
566 CHECK_STATIC_TLS (map, sym_map);
567 *reloc_addr = (sym->st_value + sym_map->l_tls_offset
568 + reloc->r_addend);
569 }
570 break;
571 #endif
572 default:
573 _dl_reloc_bad_type (map, r_type, 0);
574 break;
575 }
576 }
577 }
578 # endif
579
580 auto inline void
581 __attribute__ ((always_inline))
582 elf_machine_rel_relative (Elf32_Addr l_addr, const Elf32_Rel *reloc,
583 void *const reloc_addr_arg)
584 {
585 Elf32_Addr *const reloc_addr = reloc_addr_arg;
586 *reloc_addr += l_addr;
587 }
588
589 # ifndef RTLD_BOOTSTRAP
590 auto inline void
591 __attribute__ ((always_inline))
592 elf_machine_rela_relative (Elf32_Addr l_addr, const Elf32_Rela *reloc,
593 void *const reloc_addr_arg)
594 {
595 Elf32_Addr *const reloc_addr = reloc_addr_arg;
596 *reloc_addr = l_addr + reloc->r_addend;
597 }
598 # endif
599
600 auto inline void
601 __attribute__ ((always_inline))
602 elf_machine_lazy_rel (struct link_map *map,
603 Elf32_Addr l_addr, const Elf32_Rel *reloc)
604 {
605 Elf32_Addr *const reloc_addr = (void *) (l_addr + reloc->r_offset);
606 const unsigned int r_type = ELF32_R_TYPE (reloc->r_info);
607 /* Check for unexpected PLT reloc type. */
608 if (__builtin_expect (r_type == R_ARM_JUMP_SLOT, 1))
609 {
610 if (__builtin_expect (map->l_mach.plt, 0) == 0)
611 *reloc_addr += l_addr;
612 else
613 *reloc_addr = map->l_mach.plt;
614 }
615 else
616 _dl_reloc_bad_type (map, r_type, 1);
617 }
618
619 #endif /* RESOLVE_MAP */