[PATCH] wait.h cleanup

From: Matti Annala (gval@mbnet.fi)
Date: Sat Nov 16 2002 - 04:22:26 EST


The patch below slightly cleans up the waitqueue initialization macros and
removes a useless comment from the header (the macro names are clear enough).

Comments?

--------------------------------------------------------------------------------

diff -ur linux-2.5.47/include/linux/wait.h difflinux/include/linux/wait.h
--- linux-2.5.47/include/linux/wait.h 2002-11-05 00:30:31.000000000 +0200
+++ difflinux/include/linux/wait.h 2002-11-14 09:40:37.000000000 +0200
@@ -37,21 +37,16 @@
 };
 typedef struct __wait_queue_head wait_queue_head_t;
 
-
-/*
- * Macros for declaration and initialisaton of the datatypes
- */
-
-#define __WAITQUEUE_INITIALIZER(name, tsk) { \
+#define __WAITQUEUE_INITIALIZER(tsk) { \
  .task = tsk, \
- .func = default_wake_function, \
+ .func = default_wake_function, \
  .task_list = { NULL, NULL } }
 
-#define DECLARE_WAITQUEUE(name, tsk) \
- wait_queue_t name = __WAITQUEUE_INITIALIZER(name, tsk)
+#define DECLARE_WAITQUEUE(name, tsk) \
+ wait_queue_t name = __WAITQUEUE_INITIALIZER(tsk)
 
-#define __WAIT_QUEUE_HEAD_INITIALIZER(name) { \
- .lock = SPIN_LOCK_UNLOCKED, \
+#define __WAIT_QUEUE_HEAD_INITIALIZER(name) { \
+ .lock = SPIN_LOCK_UNLOCKED, \
  .task_list = { &(name).task_list, &(name).task_list } }
 
 #define DECLARE_WAIT_QUEUE_HEAD(name) \

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Nov 23 2002 - 22:00:17 EST