aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/wait.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/wait.h')
-rw-r--r--include/linux/wait.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/include/linux/wait.h b/include/linux/wait.h
index 158715445ffb..55a611486bac 100644
--- a/include/linux/wait.h
+++ b/include/linux/wait.h
@@ -206,14 +206,16 @@ void __wake_up_sync(struct wait_queue_head *wq_head, unsigned int mode, int nr);
206/* 206/*
207 * Wakeup macros to be used to report events to the targets. 207 * Wakeup macros to be used to report events to the targets.
208 */ 208 */
209#define poll_to_key(m) ((void *)(__force uintptr_t)(__poll_t)(m))
210#define key_to_poll(m) ((__force __poll_t)(uintptr_t)(void *)(m))
209#define wake_up_poll(x, m) \ 211#define wake_up_poll(x, m) \
210 __wake_up(x, TASK_NORMAL, 1, (void *) (m)) 212 __wake_up(x, TASK_NORMAL, 1, poll_to_key(m))
211#define wake_up_locked_poll(x, m) \ 213#define wake_up_locked_poll(x, m) \
212 __wake_up_locked_key((x), TASK_NORMAL, (void *) (m)) 214 __wake_up_locked_key((x), TASK_NORMAL, poll_to_key(m))
213#define wake_up_interruptible_poll(x, m) \ 215#define wake_up_interruptible_poll(x, m) \
214 __wake_up(x, TASK_INTERRUPTIBLE, 1, (void *) (m)) 216 __wake_up(x, TASK_INTERRUPTIBLE, 1, poll_to_key(m))
215#define wake_up_interruptible_sync_poll(x, m) \ 217#define wake_up_interruptible_sync_poll(x, m) \
216 __wake_up_sync_key((x), TASK_INTERRUPTIBLE, 1, (void *) (m)) 218 __wake_up_sync_key((x), TASK_INTERRUPTIBLE, 1, poll_to_key(m))
217 219
218#define ___wait_cond_timeout(condition) \ 220#define ___wait_cond_timeout(condition) \
219({ \ 221({ \