version 1.29.8.2, 2023/02/23 15:31:17
|
version 1.30.2.4, 2023/02/23 17:13:01
|
Line 389 schedEnd(sched_root_task_t ** __restrict root)
|
Line 389 schedEnd(sched_root_task_t ** __restrict root)
|
|
|
if ((*root)->root_sigthr) { |
if ((*root)->root_sigthr) { |
pthread_cancel((*root)->root_sigthr); |
pthread_cancel((*root)->root_sigthr); |
(*root)->root_sigthr ^= (*root)->root_sigthr; | #ifdef __linux__ |
| (*root)->root_sigthr = 0L; |
| #else |
| (*root)->root_sigthr = NULL; |
| #endif |
} |
} |
#endif |
#endif |
|
|
Line 1119 schedResumeby(sched_root_task_t * __restrict root, u_c
|
Line 1123 schedResumeby(sched_root_task_t * __restrict root, u_c
|
static void * |
static void * |
_sched_sigDisp(void *arg) |
_sched_sigDisp(void *arg) |
{ |
{ |
sched_root_task_t *sched = arg; | sched_root_task_t *root = arg; |
sigset_t ss; | sched_task_t *task, *tmp; |
int sig; | int sig, flg; |
|
|
sigfillset(&ss); | while (root->root_sigthr) { |
while (sched->root_sigthr) { | if (sigwait(&root->root_sigset, &sig)) |
sigwait(&ss, &sig); | continue; |
|
|
|
flg = 0; |
|
TAILQ_FOREACH_SAFE(task, &root->root_signal, task_node, tmp) { |
|
if (TASK_VAL(task) == (uintptr_t) sig) { |
|
if (!flg) { |
|
TASK_RET(task) = 0; |
|
TASK_FLAG(task) = 0; |
|
|
|
/* remove signal handle */ |
|
transit_task2ready(task, &root->root_signal); |
|
} |
|
flg++; |
|
} |
|
} |
|
if (flg < 2) |
|
sigdelset(&root->root_sigset, sig); |
} |
} |
|
|
return NULL; |
return NULL; |
Line 1152 schedSignalDispatch(sched_root_task_t * __restrict roo
|
Line 1171 schedSignalDispatch(sched_root_task_t * __restrict roo
|
|
|
if (!on) { |
if (!on) { |
pthread_cancel(root->root_sigthr); |
pthread_cancel(root->root_sigthr); |
root->root_sigthr ^= root->root_sigthr; | #ifdef __linux__ |
| root->root_sigthr = 0L; |
| #else |
| root->root_sigthr = NULL; |
| #endif |
return 0; |
return 0; |
} |
} |
|
|