Changeset View
Changeset View
Standalone View
Standalone View
sys/sys/sleepqueue.h
Show First 20 Lines • Show All 79 Lines • ▼ Show 20 Lines | |||||
#define SLEEPQ_TYPE 0x0ff /* Mask of sleep queue types. */ | #define SLEEPQ_TYPE 0x0ff /* Mask of sleep queue types. */ | ||||
#define SLEEPQ_SLEEP 0x00 /* Used by sleep/wakeup. */ | #define SLEEPQ_SLEEP 0x00 /* Used by sleep/wakeup. */ | ||||
#define SLEEPQ_CONDVAR 0x01 /* Used for a cv. */ | #define SLEEPQ_CONDVAR 0x01 /* Used for a cv. */ | ||||
#define SLEEPQ_PAUSE 0x02 /* Used by pause. */ | #define SLEEPQ_PAUSE 0x02 /* Used by pause. */ | ||||
#define SLEEPQ_SX 0x03 /* Used by an sx lock. */ | #define SLEEPQ_SX 0x03 /* Used by an sx lock. */ | ||||
#define SLEEPQ_LK 0x04 /* Used by a lockmgr. */ | #define SLEEPQ_LK 0x04 /* Used by a lockmgr. */ | ||||
#define SLEEPQ_INTERRUPTIBLE 0x100 /* Sleep is interruptible. */ | #define SLEEPQ_INTERRUPTIBLE 0x100 /* Sleep is interruptible. */ | ||||
#define SLEEPQ_UNFAIR 0x200 /* Unfair wakeup order. */ | #define SLEEPQ_UNFAIR 0x200 /* Unfair wakeup order. */ | ||||
#define SLEEPQ_USERWAIT 0x400 /* Waiting on the user. */ | |||||
void init_sleepqueues(void); | void init_sleepqueues(void); | ||||
int sleepq_abort(struct thread *td, int intrval); | int sleepq_abort(struct thread *td, int intrval); | ||||
void sleepq_add(const void *wchan, struct lock_object *lock, | void sleepq_add(const void *wchan, struct lock_object *lock, | ||||
const char *wmesg, int flags, int queue); | const char *wmesg, int flags, int queue); | ||||
struct sleepqueue *sleepq_alloc(void); | struct sleepqueue *sleepq_alloc(void); | ||||
int sleepq_broadcast(const void *wchan, int flags, int pri, int queue); | int sleepq_broadcast(const void *wchan, int flags, int pri, int queue); | ||||
void sleepq_chains_remove_matching(bool (*matches)(struct thread *)); | void sleepq_chains_remove_matching(bool (*matches)(struct thread *)); | ||||
Show All 27 Lines |