[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250827105854.DwmcsKlC@linutronix.de>
Date: Wed, 27 Aug 2025 12:58:54 +0200
From: Sebastian Andrzej Siewior <bigeasy@...utronix.de>
To: Dan Carpenter <dan.carpenter@...aro.org>
Cc: Thomas Gleixner <tglx@...utronix.de>, Ingo Molnar <mingo@...hat.com>,
Peter Zijlstra <peterz@...radead.org>,
Darren Hart <dvhart@...radead.org>,
Davidlohr Bueso <dave@...olabs.net>,
André Almeida <andrealmeid@...lia.com>,
Shuah Khan <shuah@...nel.org>,
Cynthia Huang <cynthia@...estech.com>,
Ben Zong-You Xie <ben717@...estech.com>,
Muhammad Usama Anjum <usama.anjum@...labora.com>,
linux-kernel@...r.kernel.org, linux-kselftest@...r.kernel.org
Subject: Re: [PATCH] selftests/futex: fix futex_wait() for 32bit ARM
On 2025-08-26 17:25:11 [+0300], Dan Carpenter wrote:
> On 32bit ARM systems gcc-12 will use 32bit timestamps while gcc-13 and
> later will use 64bit timestamps. The problem is that SYS_futex will
> continue pointing at the 32bit system call. This makes the futex_wait
> test fail like this:
>
> waiter failed errno 110
> not ok 1 futex_wake private returned: 0 Success
> waiter failed errno 110
> not ok 2 futex_wake shared (page anon) returned: 0 Success
> waiter failed errno 110
> not ok 3 futex_wake shared (file backed) returned: 0 Success
>
> Instead of compiling differently depending on the gcc version, use the
> -D_FILE_OFFSET_BITS=64 -D_TIME_BITS=64 options to ensure that we are
> building with 64bit timestamps. Then use ifdefs to make SYS_futex point
> to the 64bit system call.
>
> Signed-off-by: Dan Carpenter <dan.carpenter@...aro.org>
> Tested-by: Anders Roxell <anders.roxell@...aro.org>
It appears glibc uses the 64bit syscall by default. So that is fine.
Sebastian
Powered by blists - more mailing lists