This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
[PATCH 0/3] stat syscall family: support modern 32-bit ABI requirements
- From: Yury Norov <ynorov at caviumnetworks dot com>
- To: <libc-alpha at sourceware dot org>, <joseph at codesourcery dot com>, <schwab at suse dot de>
- Cc: <arnd at arndb dot de>, <catalin dot marinas at arm dot com>, <davem at davemloft dot net>, <szabolcs dot nagy at arm dot com>, <maxim dot kuvyrkov at linaro dot org>, <pinskia at gmail dot com>, <bamvor dot zhangjian at huawei dot com>, <fweimer at redhat dot com>, <Prasun dot Kapoor at cavium dot com>, <adhemerval dot zanella at linaro dot org>, Yury Norov <ynorov at caviumnetworks dot com>
- Date: Thu, 4 Aug 2016 13:02:36 +0300
- Subject: [PATCH 0/3] stat syscall family: support modern 32-bit ABI requirements
- Authentication-results: sourceware.org; auth=none
- Authentication-results: spf=none (sender IP is ) smtp.mailfrom=Yuri dot Norov at caviumnetworks dot com;
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
In modern APIs stat and statfs structures has their layouts identical
to 64-bit version after changing off_t, ino_t etc sizes to 64-bit.
It means we can pass it to kernel same way as 64-bit ABI does. The only
exception is time_t-related fields. It can be handled by introducing
pads where needed.
Patch 1 is helper for patch 2 that does all the work by introducing paddings
where needed in structures stat and statfs. Patch 3 enables new ABI for
aarch64/ilp32 and should be applied with the rest of ilp32 series:
https://github.com/norov/glibc/tree/ilp32-2.24
Yury Norov (3):
endian.h: introduce __type3264() macro
32-bit ABIs: support stat syscall family
[AARCH64] ILP32: redirect stat syscall family to 64-bit handlers
string/endian.h | 12 +++++
sysdeps/unix/sysv/linux/aarch64/bits/typesizes.h | 6 +++
sysdeps/unix/sysv/linux/aarch64/ilp32/fstatfs64.c | 35 +++++++++++++
sysdeps/unix/sysv/linux/aarch64/ilp32/statfs64.c | 38 ++++++++++++++
sysdeps/unix/sysv/linux/fstatfs64.c | 7 +++
sysdeps/unix/sysv/linux/fxstat64.c | 11 ++++
sysdeps/unix/sysv/linux/fxstatat64.c | 15 +++++-
sysdeps/unix/sysv/linux/generic/bits/stat.h | 58 ++++++++++++++++------
sysdeps/unix/sysv/linux/generic/bits/statfs.h | 40 +++++++--------
.../unix/sysv/linux/generic/wordsize-32/fstatfs.c | 3 ++
.../unix/sysv/linux/generic/wordsize-32/fxstat.c | 3 ++
.../unix/sysv/linux/generic/wordsize-32/fxstatat.c | 2 +
.../unix/sysv/linux/generic/wordsize-32/lxstat.c | 2 +
.../unix/sysv/linux/generic/wordsize-32/lxstat64.c | 20 +++++++-
.../unix/sysv/linux/generic/wordsize-32/statfs.c | 2 +
.../unix/sysv/linux/generic/wordsize-32/xstat.c | 2 +
.../unix/sysv/linux/generic/wordsize-32/xstat64.c | 16 +++++-
sysdeps/unix/sysv/linux/kernel-time.h | 45 +++++++++++++++++
sysdeps/unix/sysv/linux/statfs64.c | 8 +++
time/time.h | 12 ++++-
20 files changed, 298 insertions(+), 39 deletions(-)
create mode 100644 sysdeps/unix/sysv/linux/aarch64/ilp32/fstatfs64.c
create mode 100644 sysdeps/unix/sysv/linux/aarch64/ilp32/statfs64.c
create mode 100644 sysdeps/unix/sysv/linux/kernel-time.h
--
2.7.4