glibc/sysdeps/unix/sysv/linux/generic
Alistair Francis 1c634e677f sysv: Define __KERNEL_OLD_TIMEVAL_MATCHES_TIMEVAL64
On y2038 safe 32-bit systems the Linux kernel expects itimerval
and rusage to use a 32-bit time_t, even though the other time_t's
are 64-bit. There are currently no plans to make 64-bit time_t versions
of these structs.

There are also other occurrences where the time passed to the kernel via
timeval doesn't match the wordsize.

To handle these cases let's define a new macro
__KERNEL_OLD_TIMEVAL_MATCHES_TIMEVAL64. This macro specifies if the
kernel's old_timeval matches the new timeval64. This should be 1 for
64-bit architectures except for Alpha's osf syscalls. The define should
be 0 for 32-bit architectures and Alpha's osf syscalls.

Reviewed-by: Lukasz Majewski <lukma@denx.de>
Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2020-04-02 09:21:05 -07:00
..
bits sysv: Define __KERNEL_OLD_TIMEVAL_MATCHES_TIMEVAL64 2020-04-02 09:21:05 -07:00
wordsize-32 Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
____longjmp_chk.c linux: Remove INTERNAL_SYSCALL_DECL 2020-02-14 21:12:45 -03:00
brk.c linux: Remove INTERNAL_SYSCALL_DECL 2020-02-14 21:12:45 -03:00
chmod.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
chown.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
dl-origin.c linux: Remove INTERNAL_SYSCALL_DECL 2020-02-14 21:12:45 -03:00
dup2.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
epoll_create.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
futimesat.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
inotify_init.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
kernel_stat.h Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
lchown.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
link.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
lxstat.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
Makefile sysdeps/stat: Handle 64-bit ino_t types on 32-bit hosts 2019-10-23 12:43:31 -07:00
mkdir.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
pipe.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
readlink.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
README linux-generic: add a README 2015-03-19 13:33:01 -04:00
rmdir.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
stat-check.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
symlink.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
syscalls.list Consolidate Linux sendto implementation 2017-03-09 15:22:06 +01:00
sysctl.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
sysdep.h Linux: Clean up pread64/pwrite64 system call names 2020-03-03 12:14:40 +01:00
unlink.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
utimes.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
xmknod.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
xstat.c Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00

This hierarchy supports Linux systems using the new
asm-generic/unistd.h, which removes many familiar old syscalls.  For
example, to implement open(), newer Linux architectures require glibc
to invoke the __NR_openat syscall with AT_FDCWD.  This hierarchy
provides all those implementations.

It also provides support for 32-bit platforms using the 64-bit kernel
syscall APIs, as the 32-bit ones are no longer provided.  Note that
newer ILP32 environments (x32 or AArch64:ILP32, for example) are
converting to use more 64-bit types in kernel syscalls, so that aspect
of this support is in more flux as of this writing.