summaryrefslogtreecommitdiff
path: root/ldso
diff options
context:
space:
mode:
Diffstat (limited to 'ldso')
-rw-r--r--ldso/include/dl-syscall.h10
-rw-r--r--ldso/ldso/arc/elfinterp.c4
-rw-r--r--ldso/ldso/sh/dl-syscalls.h2
3 files changed, 14 insertions, 2 deletions
diff --git a/ldso/include/dl-syscall.h b/ldso/include/dl-syscall.h
index ac4c57e4e..4749d7abd 100644
--- a/ldso/include/dl-syscall.h
+++ b/ldso/include/dl-syscall.h
@@ -48,7 +48,15 @@ extern int _dl_errno;
dynamic linking at all, so we cannot return any error codes.
We just punt if there is an error. */
#define __NR__dl_exit __NR_exit
-static __always_inline _syscall1(void, _dl_exit, int, status)
+static __always_inline attribute_noreturn __cold void _dl_exit(int status)
+{
+ INLINE_SYSCALL(_dl_exit, 1, status);
+#if defined __GNUC__
+ __builtin_unreachable(); /* shut up warning: 'noreturn' function does return*/
+#else
+ while (1);
+#endif
+}
#define __NR__dl_close __NR_close
static __always_inline _syscall1(int, _dl_close, int, fd)
diff --git a/ldso/ldso/arc/elfinterp.c b/ldso/ldso/arc/elfinterp.c
index 7c31d3ac7..2f0cf7f66 100644
--- a/ldso/ldso/arc/elfinterp.c
+++ b/ldso/ldso/arc/elfinterp.c
@@ -144,6 +144,8 @@ _dl_do_reloc(struct elf_resolve *tpnt, struct r_scope_elem *scope,
#endif
switch (reloc_type) {
+ case R_ARC_NONE:
+ break;
case R_ARC_32:
*reloc_addr += symbol_addr + rpnt->r_addend;
break;
@@ -202,6 +204,8 @@ _dl_do_lazy_reloc(struct elf_resolve *tpnt, struct r_scope_elem *scope,
#endif
switch (reloc_type) {
+ case R_ARC_NONE:
+ break;
case R_ARC_JMP_SLOT:
*reloc_addr += tpnt->loadaddr;
break;
diff --git a/ldso/ldso/sh/dl-syscalls.h b/ldso/ldso/sh/dl-syscalls.h
index f9f13c7fa..b99a9b5a0 100644
--- a/ldso/ldso/sh/dl-syscalls.h
+++ b/ldso/ldso/sh/dl-syscalls.h
@@ -1,4 +1,4 @@
-#if __GNUC_PREREQ (4, 1)
+#if __GNUC_PREREQ (4, 1) && !__GNUC_PREREQ (4, 9)
#warning !!! gcc 4.1 and later have problems with __always_inline so redefined as inline
# ifdef __always_inline
# undef __always_inline