From c86f875f07f2e2ef54ce3741914a5cc74f7ddd3c Mon Sep 17 00:00:00 2001 From: Christophe Lyon Date: Wed, 4 Jul 2018 17:55:20 +0200 Subject: Fix bug in _dl_pread when using pread64 syscall MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In ARM_EABI mode, the pread64 syscall parameters are aligned on 64-bits. This syscall is used in rtld when processing FDPIC relocations. * ldso/include/dl-syscall.h (__syscall_pread): Fix definition. (__dl_pread): Fix syscall invocation. * ldso/ldso/fdpic/dl-sysdep.h (__DL_PREAD): Handle __NR_pread64. Signed-off-by: Mickaël Guêné Signed-off-by: Christophe Lyon --- ldso/ldso/fdpic/dl-sysdep.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ldso/ldso/fdpic/dl-sysdep.h') diff --git a/ldso/ldso/fdpic/dl-sysdep.h b/ldso/ldso/fdpic/dl-sysdep.h index 546811ad0..6ab303b37 100644 --- a/ldso/ldso/fdpic/dl-sysdep.h +++ b/ldso/ldso/fdpic/dl-sysdep.h @@ -96,7 +96,7 @@ struct funcdesc_ht; elfinterp.c. */ #define DL_SKIP_BOOTSTRAP_RELOC(SYMTAB, INDEX, STRTAB) 0 -#ifdef __NR_pread +#if defined(__NR_pread) || defined(__NR_pread64) #define _DL_PREAD(FD, BUF, SIZE, OFFSET) \ (_dl_pread((FD), (BUF), (SIZE), (OFFSET))) #endif -- cgit v1.2.3