From 252524e5cf22644bfef7715916ea8091b2018dea Mon Sep 17 00:00:00 2001 From: =?utf8?q?Fran=C3=A7ois=20Tigeot?= Date: Sat, 16 Mar 2019 08:19:00 +0100 Subject: [PATCH] drm/linux: Improve linux/wait.h --- sys/dev/drm/include/linux/wait.h | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/sys/dev/drm/include/linux/wait.h b/sys/dev/drm/include/linux/wait.h index f2d3a82007..5df3aabc69 100644 --- a/sys/dev/drm/include/linux/wait.h +++ b/sys/dev/drm/include/linux/wait.h @@ -33,8 +33,15 @@ #include #include -typedef struct { -} wait_queue_t; +typedef struct __wait_queue wait_queue_t; + +typedef int (*wait_queue_func_t)(wait_queue_t *wait, unsigned mode, int flags, void *key); + +struct __wait_queue { + unsigned int flags; + void *private; + wait_queue_func_t func; +}; typedef struct { struct lock lock; @@ -48,6 +55,7 @@ init_waitqueue_head(wait_queue_head_t *eq) #define wake_up(eq) wakeup_one(eq) #define wake_up_all(eq) wakeup(eq) +#define wake_up_all_locked(eq) wakeup(eq) #define wake_up_interruptible(eq) wakeup_one(eq) #define wake_up_interruptible_all(eq) wakeup(eq) @@ -152,9 +160,19 @@ add_wait_queue(wait_queue_head_t *q, wait_queue_t *wait) { } +static inline void +__add_wait_queue(wait_queue_head_t *head, wait_queue_t *new) +{ +} + #define DECLARE_WAIT_QUEUE_HEAD(name) \ wait_queue_head_t name = { \ .lock = LOCK_INITIALIZER("name", 0, LK_CANRECURSE) \ } +static inline void +__remove_wait_queue(wait_queue_head_t *head, wait_queue_t *old) +{ +} + #endif /* _LINUX_WAIT_H_ */ -- 2.41.0