Home
last modified time | relevance | path

Searched refs:wait (Results 1 – 9 of 9) sorted by relevance

/DragonOS-0.1.8/kernel/src/libs/
Dwait_queue_head.c22 void wait_queue_sleep_with_node(wait_queue_head_t *q, wait_queue_node_t *wait) in wait_queue_sleep_with_node() argument
24 BUG_ON(wait->pcb == NULL); in wait_queue_sleep_with_node()
26 wait->pcb->state = PROC_UNINTERRUPTIBLE; in wait_queue_sleep_with_node()
27 list_append(&q->wait_list, &wait->wait_list); in wait_queue_sleep_with_node()
37 void wait_queue_sleep_with_node_unlock(wait_queue_head_t *q, wait_queue_node_t *wait, void *lock) in wait_queue_sleep_with_node_unlock() argument
39 BUG_ON(wait->pcb == NULL); in wait_queue_sleep_with_node_unlock()
41 wait->pcb->state = PROC_UNINTERRUPTIBLE; in wait_queue_sleep_with_node_unlock()
42 list_append(&q->wait_list, &wait->wait_list); in wait_queue_sleep_with_node_unlock()
53 void wait_queue_sleep_with_node_interriptible(wait_queue_head_t *q, wait_queue_node_t *wait) in wait_queue_sleep_with_node_interriptible() argument
55 BUG_ON(wait->pcb == NULL); in wait_queue_sleep_with_node_interriptible()
[all …]
Dwait_queue.c26 wait_queue_node_t *wait = (wait_queue_node_t *)kzalloc(sizeof(wait_queue_node_t), 0); in wait_queue_sleep_on() local
27 wait_queue_init(wait, current_pcb); in wait_queue_sleep_on()
29 list_append(&wait_queue_head->wait_list, &wait->wait_list); in wait_queue_sleep_on()
42 wait_queue_node_t *wait = (wait_queue_node_t *)kzalloc(sizeof(wait_queue_node_t), 0); in wait_queue_sleep_on_unlock() local
43 wait_queue_init(wait, current_pcb); in wait_queue_sleep_on_unlock()
45 list_append(&wait_queue_head->wait_list, &wait->wait_list); in wait_queue_sleep_on_unlock()
57 wait_queue_node_t *wait = (wait_queue_node_t *)kzalloc(sizeof(wait_queue_node_t), 0); in wait_queue_sleep_on_interriptible() local
58 wait_queue_init(wait, current_pcb); in wait_queue_sleep_on_interriptible()
60 list_append(&wait_queue_head->wait_list, &wait->wait_list); in wait_queue_sleep_on_interriptible()
75 …wait_queue_node_t *wait = container_of(list_next(&wait_queue_head->wait_list), wait_queue_node_t, … in wait_queue_wakeup() local
[all …]
Dsemaphore.c13 wait_queue_node_t wait; in semaphore_down() local
14 wait_queue_init(&wait, current_pcb); in semaphore_down()
18 list_append(&sema->wait_queue.wait_list, &wait.wait_list); in semaphore_down()
/DragonOS-0.1.8/kernel/src/common/
Dwait_queue.h69 wait_queue_node_t *wait = (wait_queue_node_t *)kzalloc(sizeof(wait_queue_node_t), 0); \
73 wait_queue_node_t *wait = (wait_queue_node_t *)kzalloc(sizeof(wait_queue_node_t), 0); \
93 void wait_queue_sleep_with_node(wait_queue_head_t *q, wait_queue_node_t *wait);
102 void wait_queue_sleep_with_node_unlock(wait_queue_head_t *q, wait_queue_node_t *wait, void *lock);
110 void wait_queue_sleep_with_node_interriptible(wait_queue_head_t *q, wait_queue_node_t *wait);
/DragonOS-0.1.8/kernel/src/sched/
Dcompletion.c61 DECLARE_WAIT_ON_STACK_SELF(wait); in __wait_for_common()
66 if (list_empty(&wait.wait_list)) in __wait_for_common()
67 list_append(&x->wait_queue.wait_list, &wait.wait_list); in __wait_for_common()
68 wait.pcb->state = state; // 清除运行位, 并设置为interuptible/uninteruptible in __wait_for_common()
78 wait.pcb->state = PROC_RUNNING; // 设置为运行, 并清空state, 所以使用等号赋值 in __wait_for_common()
79 if (!list_empty(&wait.wait_list)) in __wait_for_common()
80 list_del_init(&wait.wait_list); // 必须使用del_init in __wait_for_common()
/DragonOS-0.1.8/user/libs/libc/src/include/export/sys/
Dwait.h11 pid_t wait(int *stat_loc);
/DragonOS-0.1.8/user/libs/libc/src/sys/
Dwait.c10 pid_t wait(int *stat_loc) in wait() function
/DragonOS-0.1.8/docs/kernel/sched/
Dc_waiting.md121 | wait_queue_sleep_with_node_unlock(wait_queue_head_t *q, wait_queue_node_t *wait, void *lock) …
122 | wait_queue_sleep_with_node_interriptible(wait_queue_head_t *q, wait_queue_node_t *wait) | 传入一个等待队…
176 ### 关于完成量的wait系列函数
/DragonOS-0.1.8/user/apps/shell/
Dcmd_test.c80 wait(NULL); // 等待子进程结束 in shell_pipe_test()