summaryrefslogtreecommitdiff
path: root/ldso/ldso/xtensa/dl-startup.h
diff options
context:
space:
mode:
Diffstat (limited to 'ldso/ldso/xtensa/dl-startup.h')
-rw-r--r--ldso/ldso/xtensa/dl-startup.h15
1 files changed, 4 insertions, 11 deletions
diff --git a/ldso/ldso/xtensa/dl-startup.h b/ldso/ldso/xtensa/dl-startup.h
index db223fead..c9350c0f2 100644
--- a/ldso/ldso/xtensa/dl-startup.h
+++ b/ldso/ldso/xtensa/dl-startup.h
@@ -7,6 +7,7 @@
* Parts taken from glibc/sysdeps/xtensa/dl-machine.h.
*/
+#ifndef L_rcrt1
__asm__ (
" .text\n"
" .align 4\n"
@@ -81,6 +82,7 @@ __asm__ (
" addi a5, a5, 8\n"
" bnez a6, 3b\n"
" j .Lfixup_stack_ret");
+#endif
/* Get a pointer to the argv value. */
#define GET_ARGV(ARGVP, ARGS) ARGVP = (((unsigned long *) ARGS) + 1)
@@ -88,12 +90,11 @@ __asm__ (
/* Function calls are not safe until the GOT relocations have been done. */
#define NO_FUNCS_BEFORE_BOOTSTRAP
+#if defined(__ARCH_USE_MMU__)
#define PERFORM_BOOTSTRAP_GOT(tpnt) \
do { \
xtensa_got_location *got_loc; \
unsigned long l_addr = tpnt->loadaddr; \
- Elf32_Word relative_count; \
- unsigned long rel_addr; \
Elf32_Addr prev_got_start = 0, prev_got_end = 0; \
int x; \
\
@@ -125,13 +126,5 @@ do { \
prev_got_end - prev_got_start, \
PROT_READ | PROT_WRITE | PROT_EXEC); \
} \
-\
- /* The following is a stripped down version of the code following \
- the invocation of PERFORM_BOOTSTRAP_GOT in dl-startup.c. That \
- code is skipped when PERFORM_BOOTSTRAP_GOT is defined, so it has \
- to be done here instead. */ \
- relative_count = tpnt->dynamic_info[DT_RELCONT_IDX]; \
- rel_addr = tpnt->dynamic_info[DT_RELOC_TABLE_ADDR]; \
- if (rel_addr) \
- elf_machine_relative(load_addr, rel_addr, relative_count); \
} while (0)
+#endif