* [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable}
@ 2020-12-01 12:17 Lukasz Majewski
2020-12-01 12:17 ` [PATCH 2/2] lowlevellock-futex: Remove not used macros Lukasz Majewski
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Lukasz Majewski @ 2020-12-01 12:17 UTC (permalink / raw)
To: Joseph Myers, Paul Eggert, Adhemerval Zanella
Cc: Alistair Francis, Arnd Bergmann, Alistair Francis, GNU C Library,
Florian Weimer, Carlos O'Donell, Stepan Golosunov,
Andreas Schwab, Zack Weinberg, Lukasz Majewski
After gai_suspend and aio_suspend conversion to support 64 bit time and
hence rewriting the code to use only absolute variants of futex wait
functions (i.e. __futex_abstimed_wait64 and __futex_abstimed_wait_cancelable64)
futex_reltimed_wait{_cancelable} are not needed anymore and can be removed.
Build tests:
./src/scripts/build-many-glibcs.py glibcs
---
sysdeps/nptl/futex-internal.h | 61 -----------------------------------
1 file changed, 61 deletions(-)
diff --git a/sysdeps/nptl/futex-internal.h b/sysdeps/nptl/futex-internal.h
index 1640da0ce8..31c5fad7d6 100644
--- a/sysdeps/nptl/futex-internal.h
+++ b/sysdeps/nptl/futex-internal.h
@@ -177,67 +177,6 @@ futex_wait_simple (unsigned int *futex_word, unsigned int expected,
ignore_value (futex_wait (futex_word, expected, private));
}
-/* Like futex_wait, but will eventually time out (i.e., stop being
- blocked) after the duration of time provided (i.e., RELTIME) has
- passed. The caller must provide a normalized RELTIME. RELTIME can also
- equal NULL, in which case this function behaves equivalent to futex_wait.
-
- Returns the same values as futex_wait under those same conditions;
- additionally, returns ETIMEDOUT if the timeout expired.
- */
-static __always_inline int
-futex_reltimed_wait (unsigned int* futex_word, unsigned int expected,
- const struct timespec* reltime, int private)
-{
- int err = lll_futex_timed_wait (futex_word, expected, reltime, private);
- switch (err)
- {
- case 0:
- case -EAGAIN:
- case -EINTR:
- case -ETIMEDOUT:
- return -err;
-
- case -EFAULT: /* Must have been caused by a glibc or application bug. */
- case -EINVAL: /* Either due to wrong alignment or due to the timeout not
- being normalized. Must have been caused by a glibc or
- application bug. */
- case -ENOSYS: /* Must have been caused by a glibc bug. */
- /* No other errors are documented at this time. */
- default:
- futex_fatal_error ();
- }
-}
-
-/* Like futex_reltimed_wait but is a POSIX cancellation point. */
-static __always_inline int
-futex_reltimed_wait_cancelable (unsigned int* futex_word,
- unsigned int expected,
- const struct timespec* reltime, int private)
-{
- int oldtype;
- oldtype = LIBC_CANCEL_ASYNC ();
- int err = lll_futex_timed_wait (futex_word, expected, reltime, private);
- LIBC_CANCEL_RESET (oldtype);
- switch (err)
- {
- case 0:
- case -EAGAIN:
- case -EINTR:
- case -ETIMEDOUT:
- return -err;
-
- case -EFAULT: /* Must have been caused by a glibc or application bug. */
- case -EINVAL: /* Either due to wrong alignment or due to the timeout not
- being normalized. Must have been caused by a glibc or
- application bug. */
- case -ENOSYS: /* Must have been caused by a glibc bug. */
- /* No other errors are documented at this time. */
- default:
- futex_fatal_error ();
- }
-}
-
/* Check whether the specified clockid is supported by
futex_abstimed_wait and futex_abstimed_wait_cancelable. */
static __always_inline int
--
2.20.1
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 2/2] lowlevellock-futex: Remove not used macros
2020-12-01 12:17 [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable} Lukasz Majewski
@ 2020-12-01 12:17 ` Lukasz Majewski
2020-12-01 12:52 ` Adhemerval Zanella
2020-12-01 16:47 ` Alistair Francis
2020-12-01 12:52 ` [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable} Adhemerval Zanella
2020-12-01 16:39 ` Alistair Francis
2 siblings, 2 replies; 6+ messages in thread
From: Lukasz Majewski @ 2020-12-01 12:17 UTC (permalink / raw)
To: Joseph Myers, Paul Eggert, Adhemerval Zanella
Cc: Alistair Francis, Arnd Bergmann, Alistair Francis, GNU C Library,
Florian Weimer, Carlos O'Donell, Stepan Golosunov,
Andreas Schwab, Zack Weinberg, Lukasz Majewski
Following macros: lll_futex_timed_lock_pi, lll_futex_clock_wait_bitset,
lll_futex_wait_requeue_pi, lll_futex_timed_wait_requeue_pi are not
used anymore so are eligible for removal.
Build tests:
./src/scripts/build-many-glibcs.py glibcs
---
sysdeps/nptl/lowlevellock-futex.h | 43 -------------------------------
1 file changed, 43 deletions(-)
diff --git a/sysdeps/nptl/lowlevellock-futex.h b/sysdeps/nptl/lowlevellock-futex.h
index 2209ca76a1..d09e9a8749 100644
--- a/sysdeps/nptl/lowlevellock-futex.h
+++ b/sysdeps/nptl/lowlevellock-futex.h
@@ -94,28 +94,6 @@
# define lll_futex_supported_clockid(clockid) \
((clockid) == CLOCK_REALTIME || (clockid) == CLOCK_MONOTONIC)
-/* The kernel currently only supports CLOCK_MONOTONIC or
- CLOCK_REALTIME timeouts for FUTEX_WAIT_BITSET. We could attempt to
- convert others here but currently do not. */
-# define lll_futex_clock_wait_bitset(futexp, val, clockid, timeout, private) \
- ({ \
- long int __ret; \
- if (lll_futex_supported_clockid (clockid)) \
- { \
- const unsigned int clockbit = \
- (clockid == CLOCK_REALTIME) ? FUTEX_CLOCK_REALTIME : 0; \
- const int op = \
- __lll_private_flag (FUTEX_WAIT_BITSET | clockbit, private); \
- \
- __ret = lll_futex_syscall (6, futexp, op, val, \
- timeout, NULL /* Unused. */, \
- FUTEX_BITSET_MATCH_ANY); \
- } \
- else \
- __ret = -EINVAL; \
- __ret; \
- })
-
/* Wake up up to NR waiters on FUTEXP. */
# define lll_futex_wake(futexp, nr, private) \
lll_futex_syscall (4, futexp, \
@@ -138,32 +116,11 @@
FUTEX_OP_CLEAR_WAKE_IF_GT_ONE)
-/* Priority Inheritance support. */
-#define lll_futex_timed_lock_pi(futexp, abstime, private) \
- lll_futex_syscall (4, futexp, \
- __lll_private_flag (FUTEX_LOCK_PI, private), \
- 0, abstime)
-
#define lll_futex_timed_unlock_pi(futexp, private) \
lll_futex_syscall (4, futexp, \
__lll_private_flag (FUTEX_UNLOCK_PI, private), \
0, 0)
-/* Like lll_futex_wait (FUTEXP, VAL, PRIVATE) but with the expectation
- that lll_futex_cmp_requeue_pi (FUTEXP, _, _, MUTEX, _, PRIVATE) will
- be used to do the wakeup. Confers priority-inheritance behavior on
- the waiter. */
-# define lll_futex_wait_requeue_pi(futexp, val, mutex, private) \
- lll_futex_timed_wait_requeue_pi (futexp, val, NULL, 0, mutex, private)
-
-/* Like lll_futex_wait_requeue_pi, but with a timeout. */
-# define lll_futex_timed_wait_requeue_pi(futexp, val, timeout, clockbit, \
- mutex, private) \
- lll_futex_syscall (5, futexp, \
- __lll_private_flag (FUTEX_WAIT_REQUEUE_PI \
- | (clockbit), private), \
- val, timeout, mutex)
-
/* Like lll_futex_requeue, but pairs with lll_futex_wait_requeue_pi
and inherits priority from the waiter. */
# define lll_futex_cmp_requeue_pi(futexp, nr_wake, nr_move, mutex, \
--
2.20.1
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable}
2020-12-01 12:17 [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable} Lukasz Majewski
2020-12-01 12:17 ` [PATCH 2/2] lowlevellock-futex: Remove not used macros Lukasz Majewski
@ 2020-12-01 12:52 ` Adhemerval Zanella
2020-12-01 16:39 ` Alistair Francis
2 siblings, 0 replies; 6+ messages in thread
From: Adhemerval Zanella @ 2020-12-01 12:52 UTC (permalink / raw)
To: Lukasz Majewski, Joseph Myers, Paul Eggert
Cc: Alistair Francis, Arnd Bergmann, Alistair Francis, GNU C Library,
Florian Weimer, Carlos O'Donell, Stepan Golosunov,
Andreas Schwab, Zack Weinberg
On 01/12/2020 09:17, Lukasz Majewski wrote:
> After gai_suspend and aio_suspend conversion to support 64 bit time and
> hence rewriting the code to use only absolute variants of futex wait
> functions (i.e. __futex_abstimed_wait64 and __futex_abstimed_wait_cancelable64)
> futex_reltimed_wait{_cancelable} are not needed anymore and can be removed.
>
> Build tests:
> ./src/scripts/build-many-glibcs.py glibcs
LGTM, thanks.
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
> ---
> sysdeps/nptl/futex-internal.h | 61 -----------------------------------
> 1 file changed, 61 deletions(-)
>
> diff --git a/sysdeps/nptl/futex-internal.h b/sysdeps/nptl/futex-internal.h
> index 1640da0ce8..31c5fad7d6 100644
> --- a/sysdeps/nptl/futex-internal.h
> +++ b/sysdeps/nptl/futex-internal.h
> @@ -177,67 +177,6 @@ futex_wait_simple (unsigned int *futex_word, unsigned int expected,
> ignore_value (futex_wait (futex_word, expected, private));
> }
>
> -/* Like futex_wait, but will eventually time out (i.e., stop being
> - blocked) after the duration of time provided (i.e., RELTIME) has
> - passed. The caller must provide a normalized RELTIME. RELTIME can also
> - equal NULL, in which case this function behaves equivalent to futex_wait.
> -
> - Returns the same values as futex_wait under those same conditions;
> - additionally, returns ETIMEDOUT if the timeout expired.
> - */
> -static __always_inline int
> -futex_reltimed_wait (unsigned int* futex_word, unsigned int expected,
> - const struct timespec* reltime, int private)
> -{
> - int err = lll_futex_timed_wait (futex_word, expected, reltime, private);
> - switch (err)
> - {
> - case 0:
> - case -EAGAIN:
> - case -EINTR:
> - case -ETIMEDOUT:
> - return -err;
> -
> - case -EFAULT: /* Must have been caused by a glibc or application bug. */
> - case -EINVAL: /* Either due to wrong alignment or due to the timeout not
> - being normalized. Must have been caused by a glibc or
> - application bug. */
> - case -ENOSYS: /* Must have been caused by a glibc bug. */
> - /* No other errors are documented at this time. */
> - default:
> - futex_fatal_error ();
> - }
> -}
> -
> -/* Like futex_reltimed_wait but is a POSIX cancellation point. */
> -static __always_inline int
> -futex_reltimed_wait_cancelable (unsigned int* futex_word,
> - unsigned int expected,
> - const struct timespec* reltime, int private)
> -{
> - int oldtype;
> - oldtype = LIBC_CANCEL_ASYNC ();
> - int err = lll_futex_timed_wait (futex_word, expected, reltime, private);
> - LIBC_CANCEL_RESET (oldtype);
> - switch (err)
> - {
> - case 0:
> - case -EAGAIN:
> - case -EINTR:
> - case -ETIMEDOUT:
> - return -err;
> -
> - case -EFAULT: /* Must have been caused by a glibc or application bug. */
> - case -EINVAL: /* Either due to wrong alignment or due to the timeout not
> - being normalized. Must have been caused by a glibc or
> - application bug. */
> - case -ENOSYS: /* Must have been caused by a glibc bug. */
> - /* No other errors are documented at this time. */
> - default:
> - futex_fatal_error ();
> - }
> -}
> -
> /* Check whether the specified clockid is supported by
> futex_abstimed_wait and futex_abstimed_wait_cancelable. */
> static __always_inline int
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] lowlevellock-futex: Remove not used macros
2020-12-01 12:17 ` [PATCH 2/2] lowlevellock-futex: Remove not used macros Lukasz Majewski
@ 2020-12-01 12:52 ` Adhemerval Zanella
2020-12-01 16:47 ` Alistair Francis
1 sibling, 0 replies; 6+ messages in thread
From: Adhemerval Zanella @ 2020-12-01 12:52 UTC (permalink / raw)
To: Lukasz Majewski, Joseph Myers, Paul Eggert
Cc: Alistair Francis, Arnd Bergmann, Alistair Francis, GNU C Library,
Florian Weimer, Carlos O'Donell, Stepan Golosunov,
Andreas Schwab, Zack Weinberg
On 01/12/2020 09:17, Lukasz Majewski wrote:
> Following macros: lll_futex_timed_lock_pi, lll_futex_clock_wait_bitset,
> lll_futex_wait_requeue_pi, lll_futex_timed_wait_requeue_pi are not
> used anymore so are eligible for removal.
>
> Build tests:
> ./src/scripts/build-many-glibcs.py glibcs
LGTM, thanks.
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
> ---
> sysdeps/nptl/lowlevellock-futex.h | 43 -------------------------------
> 1 file changed, 43 deletions(-)
>
> diff --git a/sysdeps/nptl/lowlevellock-futex.h b/sysdeps/nptl/lowlevellock-futex.h
> index 2209ca76a1..d09e9a8749 100644
> --- a/sysdeps/nptl/lowlevellock-futex.h
> +++ b/sysdeps/nptl/lowlevellock-futex.h
> @@ -94,28 +94,6 @@
> # define lll_futex_supported_clockid(clockid) \
> ((clockid) == CLOCK_REALTIME || (clockid) == CLOCK_MONOTONIC)
>
> -/* The kernel currently only supports CLOCK_MONOTONIC or
> - CLOCK_REALTIME timeouts for FUTEX_WAIT_BITSET. We could attempt to
> - convert others here but currently do not. */
> -# define lll_futex_clock_wait_bitset(futexp, val, clockid, timeout, private) \
> - ({ \
> - long int __ret; \
> - if (lll_futex_supported_clockid (clockid)) \
> - { \
> - const unsigned int clockbit = \
> - (clockid == CLOCK_REALTIME) ? FUTEX_CLOCK_REALTIME : 0; \
> - const int op = \
> - __lll_private_flag (FUTEX_WAIT_BITSET | clockbit, private); \
> - \
> - __ret = lll_futex_syscall (6, futexp, op, val, \
> - timeout, NULL /* Unused. */, \
> - FUTEX_BITSET_MATCH_ANY); \
> - } \
> - else \
> - __ret = -EINVAL; \
> - __ret; \
> - })
> -
> /* Wake up up to NR waiters on FUTEXP. */
> # define lll_futex_wake(futexp, nr, private) \
> lll_futex_syscall (4, futexp, \
> @@ -138,32 +116,11 @@
> FUTEX_OP_CLEAR_WAKE_IF_GT_ONE)
>
>
> -/* Priority Inheritance support. */
> -#define lll_futex_timed_lock_pi(futexp, abstime, private) \
> - lll_futex_syscall (4, futexp, \
> - __lll_private_flag (FUTEX_LOCK_PI, private), \
> - 0, abstime)
> -
> #define lll_futex_timed_unlock_pi(futexp, private) \
> lll_futex_syscall (4, futexp, \
> __lll_private_flag (FUTEX_UNLOCK_PI, private), \
> 0, 0)
>
> -/* Like lll_futex_wait (FUTEXP, VAL, PRIVATE) but with the expectation
> - that lll_futex_cmp_requeue_pi (FUTEXP, _, _, MUTEX, _, PRIVATE) will
> - be used to do the wakeup. Confers priority-inheritance behavior on
> - the waiter. */
> -# define lll_futex_wait_requeue_pi(futexp, val, mutex, private) \
> - lll_futex_timed_wait_requeue_pi (futexp, val, NULL, 0, mutex, private)
> -
> -/* Like lll_futex_wait_requeue_pi, but with a timeout. */
> -# define lll_futex_timed_wait_requeue_pi(futexp, val, timeout, clockbit, \
> - mutex, private) \
> - lll_futex_syscall (5, futexp, \
> - __lll_private_flag (FUTEX_WAIT_REQUEUE_PI \
> - | (clockbit), private), \
> - val, timeout, mutex)
> -
> /* Like lll_futex_requeue, but pairs with lll_futex_wait_requeue_pi
> and inherits priority from the waiter. */
> # define lll_futex_cmp_requeue_pi(futexp, nr_wake, nr_move, mutex, \
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable}
2020-12-01 12:17 [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable} Lukasz Majewski
2020-12-01 12:17 ` [PATCH 2/2] lowlevellock-futex: Remove not used macros Lukasz Majewski
2020-12-01 12:52 ` [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable} Adhemerval Zanella
@ 2020-12-01 16:39 ` Alistair Francis
2 siblings, 0 replies; 6+ messages in thread
From: Alistair Francis @ 2020-12-01 16:39 UTC (permalink / raw)
To: Lukasz Majewski
Cc: Joseph Myers, Paul Eggert, Adhemerval Zanella, Arnd Bergmann,
Alistair Francis, GNU C Library, Florian Weimer,
Carlos O'Donell, Stepan Golosunov, Andreas Schwab,
Zack Weinberg
On Tue, Dec 1, 2020 at 4:18 AM Lukasz Majewski <lukma@denx.de> wrote:
>
> After gai_suspend and aio_suspend conversion to support 64 bit time and
> hence rewriting the code to use only absolute variants of futex wait
> functions (i.e. __futex_abstimed_wait64 and __futex_abstimed_wait_cancelable64)
> futex_reltimed_wait{_cancelable} are not needed anymore and can be removed.
>
> Build tests:
> ./src/scripts/build-many-glibcs.py glibcs
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Alistair
> ---
> sysdeps/nptl/futex-internal.h | 61 -----------------------------------
> 1 file changed, 61 deletions(-)
>
> diff --git a/sysdeps/nptl/futex-internal.h b/sysdeps/nptl/futex-internal.h
> index 1640da0ce8..31c5fad7d6 100644
> --- a/sysdeps/nptl/futex-internal.h
> +++ b/sysdeps/nptl/futex-internal.h
> @@ -177,67 +177,6 @@ futex_wait_simple (unsigned int *futex_word, unsigned int expected,
> ignore_value (futex_wait (futex_word, expected, private));
> }
>
> -/* Like futex_wait, but will eventually time out (i.e., stop being
> - blocked) after the duration of time provided (i.e., RELTIME) has
> - passed. The caller must provide a normalized RELTIME. RELTIME can also
> - equal NULL, in which case this function behaves equivalent to futex_wait.
> -
> - Returns the same values as futex_wait under those same conditions;
> - additionally, returns ETIMEDOUT if the timeout expired.
> - */
> -static __always_inline int
> -futex_reltimed_wait (unsigned int* futex_word, unsigned int expected,
> - const struct timespec* reltime, int private)
> -{
> - int err = lll_futex_timed_wait (futex_word, expected, reltime, private);
> - switch (err)
> - {
> - case 0:
> - case -EAGAIN:
> - case -EINTR:
> - case -ETIMEDOUT:
> - return -err;
> -
> - case -EFAULT: /* Must have been caused by a glibc or application bug. */
> - case -EINVAL: /* Either due to wrong alignment or due to the timeout not
> - being normalized. Must have been caused by a glibc or
> - application bug. */
> - case -ENOSYS: /* Must have been caused by a glibc bug. */
> - /* No other errors are documented at this time. */
> - default:
> - futex_fatal_error ();
> - }
> -}
> -
> -/* Like futex_reltimed_wait but is a POSIX cancellation point. */
> -static __always_inline int
> -futex_reltimed_wait_cancelable (unsigned int* futex_word,
> - unsigned int expected,
> - const struct timespec* reltime, int private)
> -{
> - int oldtype;
> - oldtype = LIBC_CANCEL_ASYNC ();
> - int err = lll_futex_timed_wait (futex_word, expected, reltime, private);
> - LIBC_CANCEL_RESET (oldtype);
> - switch (err)
> - {
> - case 0:
> - case -EAGAIN:
> - case -EINTR:
> - case -ETIMEDOUT:
> - return -err;
> -
> - case -EFAULT: /* Must have been caused by a glibc or application bug. */
> - case -EINVAL: /* Either due to wrong alignment or due to the timeout not
> - being normalized. Must have been caused by a glibc or
> - application bug. */
> - case -ENOSYS: /* Must have been caused by a glibc bug. */
> - /* No other errors are documented at this time. */
> - default:
> - futex_fatal_error ();
> - }
> -}
> -
> /* Check whether the specified clockid is supported by
> futex_abstimed_wait and futex_abstimed_wait_cancelable. */
> static __always_inline int
> --
> 2.20.1
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] lowlevellock-futex: Remove not used macros
2020-12-01 12:17 ` [PATCH 2/2] lowlevellock-futex: Remove not used macros Lukasz Majewski
2020-12-01 12:52 ` Adhemerval Zanella
@ 2020-12-01 16:47 ` Alistair Francis
1 sibling, 0 replies; 6+ messages in thread
From: Alistair Francis @ 2020-12-01 16:47 UTC (permalink / raw)
To: Lukasz Majewski
Cc: Joseph Myers, Paul Eggert, Adhemerval Zanella, Arnd Bergmann,
Alistair Francis, GNU C Library, Florian Weimer,
Carlos O'Donell, Stepan Golosunov, Andreas Schwab,
Zack Weinberg
On Tue, Dec 1, 2020 at 4:18 AM Lukasz Majewski <lukma@denx.de> wrote:
>
> Following macros: lll_futex_timed_lock_pi, lll_futex_clock_wait_bitset,
> lll_futex_wait_requeue_pi, lll_futex_timed_wait_requeue_pi are not
> used anymore so are eligible for removal.
>
> Build tests:
> ./src/scripts/build-many-glibcs.py glibcs
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Alistair
> ---
> sysdeps/nptl/lowlevellock-futex.h | 43 -------------------------------
> 1 file changed, 43 deletions(-)
>
> diff --git a/sysdeps/nptl/lowlevellock-futex.h b/sysdeps/nptl/lowlevellock-futex.h
> index 2209ca76a1..d09e9a8749 100644
> --- a/sysdeps/nptl/lowlevellock-futex.h
> +++ b/sysdeps/nptl/lowlevellock-futex.h
> @@ -94,28 +94,6 @@
> # define lll_futex_supported_clockid(clockid) \
> ((clockid) == CLOCK_REALTIME || (clockid) == CLOCK_MONOTONIC)
>
> -/* The kernel currently only supports CLOCK_MONOTONIC or
> - CLOCK_REALTIME timeouts for FUTEX_WAIT_BITSET. We could attempt to
> - convert others here but currently do not. */
> -# define lll_futex_clock_wait_bitset(futexp, val, clockid, timeout, private) \
> - ({ \
> - long int __ret; \
> - if (lll_futex_supported_clockid (clockid)) \
> - { \
> - const unsigned int clockbit = \
> - (clockid == CLOCK_REALTIME) ? FUTEX_CLOCK_REALTIME : 0; \
> - const int op = \
> - __lll_private_flag (FUTEX_WAIT_BITSET | clockbit, private); \
> - \
> - __ret = lll_futex_syscall (6, futexp, op, val, \
> - timeout, NULL /* Unused. */, \
> - FUTEX_BITSET_MATCH_ANY); \
> - } \
> - else \
> - __ret = -EINVAL; \
> - __ret; \
> - })
> -
> /* Wake up up to NR waiters on FUTEXP. */
> # define lll_futex_wake(futexp, nr, private) \
> lll_futex_syscall (4, futexp, \
> @@ -138,32 +116,11 @@
> FUTEX_OP_CLEAR_WAKE_IF_GT_ONE)
>
>
> -/* Priority Inheritance support. */
> -#define lll_futex_timed_lock_pi(futexp, abstime, private) \
> - lll_futex_syscall (4, futexp, \
> - __lll_private_flag (FUTEX_LOCK_PI, private), \
> - 0, abstime)
> -
> #define lll_futex_timed_unlock_pi(futexp, private) \
> lll_futex_syscall (4, futexp, \
> __lll_private_flag (FUTEX_UNLOCK_PI, private), \
> 0, 0)
>
> -/* Like lll_futex_wait (FUTEXP, VAL, PRIVATE) but with the expectation
> - that lll_futex_cmp_requeue_pi (FUTEXP, _, _, MUTEX, _, PRIVATE) will
> - be used to do the wakeup. Confers priority-inheritance behavior on
> - the waiter. */
> -# define lll_futex_wait_requeue_pi(futexp, val, mutex, private) \
> - lll_futex_timed_wait_requeue_pi (futexp, val, NULL, 0, mutex, private)
> -
> -/* Like lll_futex_wait_requeue_pi, but with a timeout. */
> -# define lll_futex_timed_wait_requeue_pi(futexp, val, timeout, clockbit, \
> - mutex, private) \
> - lll_futex_syscall (5, futexp, \
> - __lll_private_flag (FUTEX_WAIT_REQUEUE_PI \
> - | (clockbit), private), \
> - val, timeout, mutex)
> -
> /* Like lll_futex_requeue, but pairs with lll_futex_wait_requeue_pi
> and inherits priority from the waiter. */
> # define lll_futex_cmp_requeue_pi(futexp, nr_wake, nr_move, mutex, \
> --
> 2.20.1
>
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2020-12-01 16:59 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-01 12:17 [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable} Lukasz Majewski
2020-12-01 12:17 ` [PATCH 2/2] lowlevellock-futex: Remove not used macros Lukasz Majewski
2020-12-01 12:52 ` Adhemerval Zanella
2020-12-01 16:47 ` Alistair Francis
2020-12-01 12:52 ` [PATCH 1/2] futex: Remove not used futex_reltimed_wait{_cancelable} Adhemerval Zanella
2020-12-01 16:39 ` Alistair Francis
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).