Subversion Repositories HelenOS

Compare Revisions

Ignore whitespace Rev 2314 → Rev 2315

/branches/rcu/kernel/generic/include/synch/waitq.h
40,18 → 40,11
#include <synch/synch.h>
#include <adt/list.h>
 
 
/** Specifies behavior of the waitq_wakeup */
typedef enum {
WAKEUP_FIRST = 0, /**< Wakes up only the first sleeping thread, if there
aren't any sleeping threads increments missed wakeups */
WAKEUP_ALL = 1, /**< Wakes up all sleeping threads AND zeroes out
missed_wakeups */
WAKEUP_ALL_INC_MISSED, /**< Wakes up all sleeping threads OR increments
missed_wakeups if there aren't any */
} wakeup_all_flag_t;
WAKEUP_FIRST = 0,
WAKEUP_ALL
} wakeup_mode_t;
 
 
/** Wait queue structure. */
typedef struct {
 
79,8 → 72,8
extern ipl_t waitq_sleep_prepare(waitq_t *wq);
extern int waitq_sleep_timeout_unsafe(waitq_t *wq, uint32_t usec, int flags);
extern void waitq_sleep_finish(waitq_t *wq, int rc, ipl_t ipl);
extern void waitq_wakeup(waitq_t *wq, int all);
extern void _waitq_wakeup_unsafe(waitq_t *wq, int all);
extern void waitq_wakeup(waitq_t *wq, wakeup_mode_t mode);
extern void _waitq_wakeup_unsafe(waitq_t *wq, wakeup_mode_t mode);
extern void waitq_interrupt_sleep(struct thread *t);
 
#endif