__wake_up_sync(9)

__wake_up_sync9

Wake up threads blocked on a waitqueue.

Usage

void __wake_up_sync(wait_queue_head_t * q, unsigned int mode, int nr_exclusive);

Arguments

q

the waitqueue

mode

which threads

nr_exclusive

how many wake-one or wake-many threads to wake up

Overview

The sync wakeup differs that the waker knows that it will schedule away soon, so while the target thread will be woken up, it will not be migrated to another CPU - ie. the two threads are ´synchronized´ with each other. This can prevent needless bouncing between CPUs.

On UP it can prevent extra preemption.

Releases

2 releases since Debian 4.0 (Etch); the text changed 1 time.

  1. 4.0
  2. 5.0

From linux-manual-2.6.26 2.6.26-29 in Debian 5.0 (Lenny). Parsed by carta from the page's man source.