#define wait_event_interruptible(wq, condition)

#define wait_event_timeout(wq, condition, timeout) { ... }

#define wait_event_interruptible_timeout(wq, condition, timeout)

□ wait_event_interruptible uses the TASK_INTERRUPTIBLE task state. The sleeping process can therefore be woken up by receiving a signal.

□ wait_event_timeout waits for the specified condition to be fulfilled, but stops waiting after a time-out specified in jiffies. This prevents a process from sleeping for ever.

□ wait_event_interruptible_timeout puts the process to sleep so that it can be woken up by receiving a signal. It also registers a time-out. Kernel nomenclature is usually not a place for surprises!

Additionally the kernel defines a number of deprecated functions (sleep_on, sleep_on_timeout, interruptible_sleep_on, and interruptible_sleep_on_timeout) that are deprecated and not supposed to be used in new code anymore. They still sit around for compatibility purposes.

Continue reading here: Info

Was this article helpful?

0 0