aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2025-01-12 22:39:20 +0100
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2025-01-12 22:47:00 +0100
commit15b345935cfca09c24d3e5414de22bb2b7aa5857 (patch)
treedfbde94edad423dd4b9fae93cbebd61546abac31
parent3782ffaf3e6c2a071df029b96712e596b5229838 (diff)
downloadglibc-15b345935cfca09c24d3e5414de22bb2b7aa5857.zip
glibc-15b345935cfca09c24d3e5414de22bb2b7aa5857.tar.gz
glibc-15b345935cfca09c24d3e5414de22bb2b7aa5857.tar.bz2
hurd: Add CLOCK_MONOTONIC support to lll
-rw-r--r--hurd/hurdlock.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/hurd/hurdlock.c b/hurd/hurdlock.c
index a971443..374e4d1 100644
--- a/hurd/hurdlock.c
+++ b/hurd/hurdlock.c
@@ -47,7 +47,7 @@ int
__lll_abstimed_wait (void *ptr, int val,
const struct timespec *tsp, int flags, int clk)
{
- if (clk != CLOCK_REALTIME)
+ if (clk != CLOCK_REALTIME && clk != CLOCK_MONOTONIC)
return EINVAL;
int mlsec = compute_reltime (tsp, clk);
@@ -58,7 +58,7 @@ int
__lll_abstimed_wait_intr (void *ptr, int val,
const struct timespec *tsp, int flags, int clk)
{
- if (clk != CLOCK_REALTIME)
+ if (clk != CLOCK_REALTIME && clk != CLOCK_MONOTONIC)
return EINVAL;
int mlsec = compute_reltime (tsp, clk);
@@ -69,7 +69,7 @@ int
__lll_abstimed_xwait (void *ptr, int lo, int hi,
const struct timespec *tsp, int flags, int clk)
{
- if (clk != CLOCK_REALTIME)
+ if (clk != CLOCK_REALTIME && clk != CLOCK_MONOTONIC)
return EINVAL;
int mlsec = compute_reltime (tsp, clk);
@@ -81,7 +81,7 @@ int
__lll_abstimed_lock (void *ptr,
const struct timespec *tsp, int flags, int clk)
{
- if (clk != CLOCK_REALTIME)
+ if (clk != CLOCK_REALTIME && clk != CLOCK_MONOTONIC)
return EINVAL;
if (__lll_trylock (ptr) == 0)
@@ -167,7 +167,7 @@ __lll_robust_abstimed_lock (void *ptr,
int wait_time = 25;
unsigned int val;
- if (clk != CLOCK_REALTIME)
+ if (clk != CLOCK_REALTIME && clk != CLOCK_MONOTONIC)
return EINVAL;
while (1)