* [PATCH] xtensa: struct semaphore.sleepers initialization
@ 2005-10-29 3:29 Arthur Othieno
0 siblings, 0 replies; only message in thread
From: Arthur Othieno @ 2005-10-29 3:29 UTC (permalink / raw)
To: akpm; +Cc: chris, linux-kernel
No one may sleep on us until we've been down()'d. So on allocation,
initialize `sleepers' to 0, just like everyone else does.
Signed-off-by: Arthur Othieno <a.othieno@bluewin.ch>
---
include/asm-xtensa/semaphore.h | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
30304537ba5143b13071e4d62ecbd1edcf526f41
diff --git a/include/asm-xtensa/semaphore.h b/include/asm-xtensa/semaphore.h
--- a/include/asm-xtensa/semaphore.h
+++ b/include/asm-xtensa/semaphore.h
@@ -38,6 +38,7 @@ struct semaphore {
static inline void sema_init (struct semaphore *sem, int val)
{
atomic_set(&sem->count, val);
+ sem->sleepers = 0;
init_waitqueue_head(&sem->wait);
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-10-29 3:29 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-10-29 3:29 [PATCH] xtensa: struct semaphore.sleepers initialization Arthur Othieno
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.