[GIT pull] Preparatory patch for semaphore cleanup
From: Thomas Gleixner
Date: Wed Sep 08 2010 - 09:11:32 EST
Linus,
Please pull the semaphore-for-linus git tree from:
git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git semaphore-for-linus
This patch just provides the DEFINE_SEMAPHORE macro which is required
for the various subsystem cleanups I sent out, so we can finally get
rid of init_MUTEX[_LOCKED] in 2.6.37.
Thanks,
tglx
------------------>
Thomas Gleixner (1):
semaphore: Add DEFINE_SEMAPHORE
include/linux/semaphore.h | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/include/linux/semaphore.h b/include/linux/semaphore.h
index 7415839..5310d27 100644
--- a/include/linux/semaphore.h
+++ b/include/linux/semaphore.h
@@ -26,6 +26,9 @@ struct semaphore {
.wait_list = LIST_HEAD_INIT((name).wait_list), \
}
+#define DEFINE_SEMAPHORE(name) \
+ struct semaphore name = __SEMAPHORE_INITIALIZER(name, 1)
+
#define DECLARE_MUTEX(name) \
struct semaphore name = __SEMAPHORE_INITIALIZER(name, 1)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/