about summary refs log tree commit diff
path: root/sysdeps/unix/sysv/linux/posix_fadvise64.c
Commit message (Collapse)AuthorAgeFilesLines
* Update copyright dates with scripts/update-copyrights.Joseph Myers2017-01-011-1/+1
|
* Consolidate posix_fadvise implementationsAdhemerval Zanella2016-10-071-12/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch consolidates mostly of the Linux posix_fadvise{64} implementations on sysdeps/unix/sysv/linux/posix_fadvise{64}.c. It still keeps arch-specific files for: * S390-32: it uses a packed structure to pass all the arguments on syscall. It is the only supported port that implements __NR_fadvise64_64 in this way. * ARM: it does not implement __NR_fadvise64 (as other 32-bits ports), so posix_fadvise calls internal posix_fadvise64 symbol. * MIPS64 n64: it requires a different version number that other ports. The new macro SYSCALL_LL{64} is used to handle the offset argument and INTERNAL_SYSCALL_CALL to handle passing the correct number of expect arguments. The default Linux adds two new defines a port can use to control how __NR_fadvise64_64 passes the kernel arguments: * __ASSUME_FADVISE64_64_6ARG: the 'advise' argument is moved on second position. This is the case of powerpc32 and arm to avoid implement 7 argument syscall. * __ASSUME_FADVISE64_64_NO_ALIGN: for ABIs that defines __ASSUME_ALIGNED_REGISTER_PAIRS packs the offset without the leading '0'. This is the case of tile 32 bits. ARM also defines __NR_fadvise64_64 as __NR_arm_fadvise64_64 (which is also handled on arch kernel-feature.h). Tested on x86_64, x32, i686, armhf, and aarch64. * posix/Makefile (tests): Add tst-posix_fadvise and tst-posix_fadvise64. * posix/tst-posix_fadvise.c: New file. * posix/tst-posix_fadvise64.c: Likewise. * posix/tst-posix_fadvise-common.c: Likewise. * sysdeps/unix/sysv/linux/arm/kernel-features.h (__ASSUME_FADVISE64_64_6ARG): Define. * sysdeps/unix/sysv/linux/powerpc/kernel-features.h [!__powerpc64__] (__ASSUME_FADVISE64_64_6ARG): Add define. * sysdeps/unix/sysv/linux/arm/posix_fadvise64.c: Remove file. * sysdeps/unix/sysv/linux/generic/wordsize-32/posix_fadvise.c: Likewise. * sysdeps/unix/sysv/linux/i386/posix_fadvise64.S: Likewise. * sysdeps/unix/sysv/linux/mips/mips32/posix_fadvise.c: Likewise. * sysdeps/unix/sysv/linux/mips/mips32/posix_fadvise64.c: Likewise. * sysdeps/unix/sysv/linux/mips/mips64/n32/posix_fadvise.c: Likewise. * sysdeps/unix/sysv/linux/mips/mips64/n32/posix_fadvise64.c: Likewise. * sysdeps/unix/sysv/linux/mips/mips64/n64/posix_fadvise.c: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/posix_fadvise.c: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/posix_fadvise64.c: Likewise. * sysdeps/unix/sysv/linux/wordsize-64/posix_fadvise.c: Likewise. * sysdeps/unix/sysv/linux/wordsize-64/posix_fadvise64.c: Likewise. * sysdeps/unix/sysv/linux/mips/mips64/n64/posix_fadvise64.c (SHLIB_COMPAT(libc, GLIBC_2_2, GLIBC_2_3_3) [__posix_fadvise64_l64]: Alias to __posix_fadvise64_l32. (SHLIB_COMPAT(libc, GLIBC_2_2, GLIBC_2_3_3) [__posix_fadvise64_l32]: Add compat definition to posix_fadvise64. (SHLIB_COMPAT(libc, GLIBC_2_2, GLIBC_2_3_3) [__posix_fadvise64_l64]: Add versioned definition to posix_fadvise64. * sysdeps/unix/sysv/linux/posix_fadvise.c (posix_fadvise): Build iff __OFF_T_MATCHES_OFF64_T is defined, use INTERNAL_SYSCALL_CALL, add __ASSUME_FADVISE64_64_6ARG/__ASSUME_FADVISE64_64_NO_ALIGN support. * sysdeps/unix/sysv/linux/posix_fadvise64.c (posix_fadvise64): Add __ASSUME_FADVISE64_64_NO_ALIGN support and use INTERNAL_SYSCALL_CALL.
* Update copyright dates with scripts/update-copyrights.Joseph Myers2016-01-041-1/+1
|
* Update copyright dates with scripts/update-copyrights.Joseph Myers2015-01-021-1/+1
|
* Update copyright notices with scripts/update-copyrightsAllan McRae2014-01-011-1/+1
|
* Update copyright notices with scripts/update-copyrights.Joseph Myers2013-01-021-1/+1
|
* Remove __ASSUME_FADVISE64_64_SYSCALL.Joseph Myers2012-08-211-25/+2
|
* Replace FSF snail mail address with URLs.Paul Eggert2012-02-091-3/+2
|
* Update.Ulrich Drepper2004-03-101-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-03-10 Jakub Jelinek <jakub@redhat.com> * include/libc-symbols.h [__ASSEMBLY__] (compat_text_section, compat_data_section): Define. * sysdeps/unix/sysv/linux/alpha/adjtime.c (ADJTIME): Add attribute_compat_text_section. * sysdeps/unix/sysv/linux/alpha/wordexp.c (__old_wordexp): Likewise. * sysdeps/unix/sysv/linux/alpha/oldglob.c (__old_glob, __old_globfree): Likewise. * sysdeps/unix/sysv/linux/s390/s390-32/chown.c (__chown_is_lchown): Likewise. * sysdeps/unix/sysv/linux/s390/s390-32/posix_fadvise64.c (__posix_fadvise64_l32): Likewise. * sysdeps/unix/sysv/linux/msgctl.c (__old_msgctl): Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/posix_fadvise64.c (__posix_fadvise64_l32): Likewise. * sysdeps/unix/sysv/linux/sparc/sparc32/semctl.c (__old_semctl): Likewise. * sysdeps/unix/sysv/linux/semctl.c (__old_semctl): Likewise. * sysdeps/unix/sysv/linux/posix_fadvise64.c (__posix_fadvise64_l32): Likewise. * sysdeps/unix/sysv/linux/shmctl.c (__old_shmctl): Likewise. * hurd/compat-20.c (_hurd_proc_init_compat_20): Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S (__swapcontext, __novec_swapcontext): Use END instead of PSEUDO_END. (__novec_swapcontext, __swapcontext_stub): Add compat_text_section. * sysdeps/unix/sysv/linux/powerpc/powerpc32/makecontext.S (__makecontext_stub): Likewise. (__novec_makecontext): Likewise. Fix name in END () to match function name. * sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext.S (__setcontext): Use END instead of PSEUDO_END. (__novec_setcontext): Add compat_text_section. Use END instead of PSEUDO_END, fix the name in END () to match function name. * sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S (__getcontext, __novec_getcontext): Use END instead of PSEUDO_END. (__novec_getcontext, __getcontext_stub): Add compat_text_section. 2004-03-10 Kaz Kojima <kkojima@rr.iij4u.or.jp> * sysdeps/sh/dl-machine.h: Don't use GL macro if not appropriate. (COPY_UNALIGNED_WORD): Remove cast used as lvalue. 2004-03-10 Ulrich Drepper <drepper@redhat.com> * sysdeps/i386/dl-procinfo.h (HWCAP_IMPORTANT): Remove mmx, add sse2.
* Fix formatting.Andreas Jaeger2003-09-021-3/+6
|
* * sysdeps/unix/sysv/linux/posix_fadvise64.c: Cast arguments of Andreas Jaeger2003-08-251-3/+3
| | | | | | | | __LONG_LONG_PAIR to long. 2003-08-25 Andreas Jaeger <aj@suse.de> * sysdeps/unix/sysv/linux/posix_fadvise64.c: Cast arguments of __LONG_LONG_PAIR to long.
* Update.Ulrich Drepper2003-08-171-0/+78
2003-08-16 Jakub Jelinek <jakub@redhat.com> * sysdeps/powerpc/powerpc32/sysdep.h (PSEUDO_ERRVAL, PSEUDO_RET_ERRVAL, ret_ERRVAL, PSEUDO_END_ERRVAL): Define. * sysdeps/powerpc/powerpc64/sysdep.h (PSEUDO_ERRVAL, PSEUDO_RET_ERRVAL, ret_ERRVAL, PSEUDO_END_ERRVAL): Define. * sysdeps/unix/alpha/sysdep.h (PSEUDO_ERRVAL, ret_ERRVAL, PSEUDO_END_ERRVAL): Define. * sysdeps/unix/mips/sysdep.h (PSEUDO_ERRVAL, ret_ERRVAL, PSEUDO_END_ERRVAL): Define. * sysdeps/unix/sparc/sysdep.h (PSEUDO_ERRVAL, ret_ERRVAL): Define. * sysdeps/unix/sysv/linux/s390/s390-32/sysdep.h (PSEUDO_ERRVAL, PSEUDO_END_ERRVAL, ret_ERRVAL): Define. * sysdeps/unix/sysv/linux/s390/s390-64/sysdep.h (PSEUDO_ERRVAL, PSEUDO_END_ERRVAL, ret_ERRVAL): Define. * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h (PSEUDO_ERRVAL): Define. * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h (PSEUDO_ERRVAL, PSEUDO_END_ERRVAL, ret_ERRVAL): Define. * sysdeps/unix/sysdep.h (PSEUDO_END_ERRVAL): Define. * sysdeps/unix/sysv/linux/syscalls.list (posix_fadvise64, posix_fadvise64_64): Remove. * sysdeps/unix/sysv/linux/alpha/syscalls.list (posix_fadvise64): Add V flag. * sysdeps/unix/sysv/linux/ia64/syscalls.list (posix_fadvise64): Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc64/syscalls.list (posix_fadvise64): Likewise. * sysdeps/unix/sysv/linux/s390/s390-64/syscalls.list (posix_fadvise64): Likewise. * sysdeps/unix/sysv/linux/sparc/sparc64/syscalls.list (posix_fadvise64): Likewise. * sysdeps/unix/sysv/linux/x86_64/syscalls.list (posix_fadvise64): Likewise. * sysdeps/unix/sysv/linux/i386/posix_fadvise64_64.S: Moved to... * sysdeps/unix/sysv/linux/i386/posix_fadvise64.S: ...here. (__posix_fadvise64_l64): Fix a typo in fadvise64 syscall invocation. (__posix_fadvise64_l32): New function. * sysdeps/unix/sysv/linux/i386/Makefile: Revert last change. * sysdeps/unix/sysv/linux/powerpc/powerpc32/Versions (libc): Export posix_fadvise64@@GLIBC_2.3.3. * sysdeps/unix/sysv/linux/s390/s390-32/Versions (libc): Likewise. * sysdeps/unix/sysv/linux/sparc/sparc32/Versions (libc): Likewise. * sysdeps/unix/sysv/linux/posix_fadvise.c (posix_fadvise): Return error value. * sysdeps/unix/sysv/linux/posix_fadvise64.c: New file. * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h (SYSCALL_ERROR_HANDLER): Use TLS errno/__libc_errno if USE___THREAD. 2003-08-15 Jakub Jelinek <jakub@redhat.com> * sysdeps/sparc/sparc32/dl-machine.h (WEAKADDR): Remove. (elf_machine_matches_host): Remove weak extern stuff. Use GL(dl_hwcap) unconditionally and GL(dl_hwcap_mask) if SHARED. (elf_machine_runtime_setup, sparc_fixup_plt): Remove weak extern stuff. Use GL(dl_hwcap) unconditionally.