This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 18/23] [AARCH64] ILP32: support stat syscall family
- From: Andreas Schwab <schwab at suse dot de>
- To: Yury Norov <ynorov at caviumnetworks dot com>
- Cc: <libc-alpha at sourceware dot org>, <linux-kernel at vger dot kernel dot org>, <arnd at arndb dot de>, <catalin dot marinas at arm dot com>, <marcus dot shawcroft at arm dot com>, <philb at gnu dot org>, <davem at davemloft dot net>, <szabolcs dot nagy at arm dot com>, <maxim dot kuvyrkov at linaro dot org>, <joseph at codesourcery dot com>, <pinskia at gmail dot com>, <bamvor dot zhangjian at huawei dot com>, <fweimer at redhat dot com>, <Prasun dot Kapoor at cavium dot com>, <cmetcalf at mellanox dot com>, <hjl dot tools at gmail dot com>, <adhemerval dot zanella at linaro dot org>, Yury Norov <yury dot norov at gmail dot com>
- Date: Wed, 29 Jun 2016 08:57:19 +0200
- Subject: Re: [PATCH 18/23] [AARCH64] ILP32: support stat syscall family
- Authentication-results: sourceware.org; auth=none
- References: <1467131978-669-1-git-send-email-ynorov at caviumnetworks dot com> <1467131978-669-19-git-send-email-ynorov at caviumnetworks dot com>
Yury Norov <ynorov@caviumnetworks.com> writes:
> +#ifdef __ILP32__
> +#include <endian.h>
> +struct __kernel_timespec
> + {
> + unsigned long long tv_sec; /* Seconds. */
> + long long tv_nsec; /* Nanoseconds. */
> + };
> +#define conv_timespec(u, k) do { \
> + (u)->tv_sec = (k)->tv_sec; \
> + (u)->tv_nsec = (k)->tv_nsec; \
> +} while (0)
> +#if __BYTE_ORDER == __LITTLE_ENDIAN
> +#define __type3264(type, name) \
> + type (name); type name##_pad
> +#else
> +#define __type3264(type, name) \
> + type name##_pad; type name
> +#endif
> +
> +#else
> +#define __kernel_timespec timespec
> +#define conv_timespec(u, k)
> +#define __type3264(type, name) type name
> +#endif /* __ILP32__ */
Surely conv_timespec needs to be put in an internal header.
Andreas.
--
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."