|
@@ -440,13 +440,15 @@ void abort_exclusive_wait(wait_queue_head_t *q, wait_queue_t *wait,
|
|
|
int autoremove_wake_function(wait_queue_t *wait, unsigned mode, int sync, void *key);
|
|
|
int wake_bit_function(wait_queue_t *wait, unsigned mode, int sync, void *key);
|
|
|
|
|
|
-#define DEFINE_WAIT(name) \
|
|
|
+#define DEFINE_WAIT_FUNC(name, function) \
|
|
|
wait_queue_t name = { \
|
|
|
.private = current, \
|
|
|
- .func = autoremove_wake_function, \
|
|
|
+ .func = function, \
|
|
|
.task_list = LIST_HEAD_INIT((name).task_list), \
|
|
|
}
|
|
|
|
|
|
+#define DEFINE_WAIT(name) DEFINE_WAIT_FUNC(name, autoremove_wake_function)
|
|
|
+
|
|
|
#define DEFINE_WAIT_BIT(name, word, bit) \
|
|
|
struct wait_bit_queue name = { \
|
|
|
.key = __WAIT_BIT_KEY_INITIALIZER(word, bit), \
|