brintos

brintos / linux-shallow public Read only

0
0
Text · 654 B · 9d30552 Raw
23 lines · c
1/* SPDX-License-Identifier: GPL-2.0-or-later */2/*3 * Futex2 library addons for futex tests4 *5 * Copyright 2021 Collabora Ltd.6 */7#include <stdint.h>8 9#define u64_to_ptr(x) ((void *)(uintptr_t)(x))10 11/**12 * futex_waitv - Wait at multiple futexes, wake on any13 * @waiters:    Array of waiters14 * @nr_waiters: Length of waiters array15 * @flags: Operation flags16 * @timo:  Optional timeout for operation17 */18static inline int futex_waitv(volatile struct futex_waitv *waiters, unsigned long nr_waiters,19			      unsigned long flags, struct timespec *timo, clockid_t clockid)20{21	return syscall(__NR_futex_waitv, waiters, nr_waiters, flags, timo, clockid);22}23