about summary refs log tree commit diff
path: root/nptl/pthread_mutex_lock.c
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-11-21 17:39:44 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-11-25 10:43:18 -0300
commita3e7aead03d558e77fc8b9dc4d567b7bb8619545 (patch)
tree14222d7756f1ad6547d429f8f59a353475b85a6f /nptl/pthread_mutex_lock.c
parenta52665818adb76df1563ae7aa45e74e92d9acd59 (diff)
downloadglibc-a3e7aead03d558e77fc8b9dc4d567b7bb8619545.tar.gz
glibc-a3e7aead03d558e77fc8b9dc4d567b7bb8619545.tar.xz
glibc-a3e7aead03d558e77fc8b9dc4d567b7bb8619545.zip
nptl: Replace __futex_clocklock_wait64 with __futex_abstimed_wait64
For non null timeouts, the __futex_clocklock_wait64 creates an a
relative timeout by subtracting the current time from the input
argument.  The same behavior can be obtained with FUTEX_WAIT_BITSET
without the need to calculate the relative timeout.  Besides consolidate
the code it also avoid the possible relative timeout issues [1].

The __futex_abstimed_wait64 needs also to return EINVAL syscall
errors.

Checked on x86_64-linux-gnu and i686-linux-gnu.

[1] https://sourceware.org/pipermail/libc-alpha/2020-November/119881.html

Reviewed-by: Lukasz Majewski <lukma@denx.de>
Diffstat (limited to 'nptl/pthread_mutex_lock.c')
0 files changed, 0 insertions, 0 deletions