On Tue, May 03, 2016 at 08:41:25PM +0800, Zhangjian (Bamvor) wrote:
[...]

> After apply this patch with my small testcase, the vsyscall of gettimeofday in
> ilp32 works in both big endian and small endian. In this patch, I use the
> different register and offset for ilp32 and lp64. Actually, the
> COMPAT_TVAL_TV_SEC is same as TVAL_TV_SEC(so as to COMPAT_TSPEC_TV_SEC and
> TSPEC_TV_SEC). I add it to keep the logic clear. I also change the version
> of vdso to 4.6. It should change to 2.6.39 if glibc is not update.
> 
> diff --git a/arch/arm64/kernel/asm-offsets.c b/arch/arm64/kernel/asm-offsets.c
> index 574081f..c8e32eb 100644
> --- a/arch/arm64/kernel/asm-offsets.c
> +++ b/arch/arm64/kernel/asm-offsets.c
> @@ -101,6 +101,11 @@ int main(void)
>    DEFINE(TSPEC_TV_SEC,               offsetof(struct timespec, tv_sec));
>    DEFINE(TSPEC_TV_NSEC,              offsetof(struct timespec, tv_nsec));
>    BLANK();
> +  DEFINE(COMPAT_TVAL_TV_SEC, offsetof(struct compat_timeval, tv_sec));
> +  DEFINE(COMPAT_TVAL_TV_USEC,        offsetof(struct compat_timeval, 
> tv_usec));
> +  DEFINE(COMPAT_TSPEC_TV_SEC,        offsetof(struct compat_timespec, 
> tv_sec));
> +  DEFINE(COMPAT_TSPEC_TV_NSEC,       offsetof(struct compat_timespec, 
> tv_nsec));
> +  BLANK();

Hi Bamvor,

We just found this lines break build if ILP32 is disabled. I think we
need to wrap them with #ifdef CONFIG_ARM64_ILP32

Yury

Reply via email to