t 40 include/arm/stdarg.h #define va_arg(a, t) (0) t 40 include/ppc/stdarg.h #define va_arg(a, t) (0) t 257 include/sys/elf.h #define ELF32_ST_INFO(b,t) (((b) << 4) + ((t) & 0xf)) t 295 include/sys/elf.h #define ELF32_R_INFO(s,t) (((s) << 8) + (unsigned char)(t)) t 62 include/sys/ioctl.h #define _IOR(g,n,t) _IOC(IOC_OUT, (g), (n), sizeof(t)) t 63 include/sys/ioctl.h #define _IOW(g,n,t) _IOC(IOC_IN, (g), (n), sizeof(t)) t 65 include/sys/ioctl.h #define _IOWR(g,n,t) _IOC(IOC_INOUT, (g), (n), sizeof(t)) t 67 include/sys/ioctl.h #define _IORN(g,n,t) _IOC((IOC_OVAL|IOC_OUT), (g), (n), sizeof(t)) t 68 include/sys/ioctl.h #define _IOWN(g,n,t) _IOC((IOC_IVAL|IOC_IN), (g), (n), sizeof(t)) t 97 include/sys/prex.h int thread_terminate(thread_t t); t 98 include/sys/prex.h int thread_load(thread_t t, void (*entry)(void), void *stack); t 101 include/sys/prex.h int thread_suspend(thread_t t); t 102 include/sys/prex.h int thread_resume(thread_t t); t 103 include/sys/prex.h int thread_getpri(thread_t t, int *pri); t 104 include/sys/prex.h int thread_setpri(thread_t t, int pri); t 105 include/sys/prex.h int thread_getpolicy(thread_t t, int *policy); t 106 include/sys/prex.h int thread_setpolicy(thread_t t, int policy); t 123 include/sys/prex.h int timer_periodic(thread_t t, u_long start, u_long period); t 129 include/sys/types.h #define FD_COPY(f, t) bcopy(f, t, sizeof(*(f))) t 40 include/x86/stdarg.h #define va_arg(a, t) (0) t 84 sys/ipc/msg.c thread_t t; t 134 sys/ipc/msg.c t = msg_dequeue(&obj->recvq); t 135 sys/ipc/msg.c sched_unsleep(t, 0); t 190 sys/ipc/msg.c thread_t t; t 257 sys/ipc/msg.c t = msg_dequeue(&obj->sendq); t 262 sys/ipc/msg.c len = MIN(size, t->msgsize); t 264 sys/ipc/msg.c if (copyout(t->msgaddr, msg, len)) { t 265 sys/ipc/msg.c msg_enqueue(&obj->sendq, t); t 274 sys/ipc/msg.c curthread->sender = t; t 275 sys/ipc/msg.c t->receiver = curthread; t 290 sys/ipc/msg.c thread_t t; t 314 sys/ipc/msg.c t = curthread->sender; t 315 sys/ipc/msg.c len = MIN(size, t->msgsize); t 317 sys/ipc/msg.c if (copyin(msg, t->msgaddr, len)) { t 325 sys/ipc/msg.c sched_unsleep(t, 0); t 326 sys/ipc/msg.c t->receiver = NULL; t 357 sys/ipc/msg.c msg_cancel(thread_t t) t 362 sys/ipc/msg.c if (t->sendobj != NULL) { t 363 sys/ipc/msg.c if (t->receiver != NULL) t 364 sys/ipc/msg.c t->receiver->sender = NULL; t 366 sys/ipc/msg.c queue_remove(&t->ipc_link); t 368 sys/ipc/msg.c if (t->recvobj != NULL) { t 369 sys/ipc/msg.c if (t->sender != NULL) { t 370 sys/ipc/msg.c sched_unsleep(t->sender, SLP_BREAK); t 371 sys/ipc/msg.c t->sender->receiver = NULL; t 373 sys/ipc/msg.c queue_remove(&t->ipc_link); t 386 sys/ipc/msg.c thread_t t; t 395 sys/ipc/msg.c t = queue_entry(q, struct thread, ipc_link); t 396 sys/ipc/msg.c sched_unsleep(t, SLP_INVAL); t 403 sys/ipc/msg.c t = queue_entry(q, struct thread, ipc_link); t 404 sys/ipc/msg.c sched_unsleep(t, SLP_INVAL); t 417 sys/ipc/msg.c thread_t t, top; t 423 sys/ipc/msg.c t = queue_entry(q, struct thread, ipc_link); t 424 sys/ipc/msg.c if (t->priority < top->priority) t 425 sys/ipc/msg.c top = t; t 433 sys/ipc/msg.c msg_enqueue(queue_t head, thread_t t) t 436 sys/ipc/msg.c enqueue(head, &t->ipc_link); t 101 sys/kern/exception.c thread_t t; t 122 sys/kern/exception.c t = list_entry(n, struct thread, task_link); t 123 sys/kern/exception.c t->excbits = 0; t 130 sys/kern/exception.c if (t->slpevt == &exception_event) { t 133 sys/kern/exception.c sched_unsleep(t, SLP_BREAK); t 176 sys/kern/exception.c thread_t t = NULL; t 199 sys/kern/exception.c t = list_entry(n, struct thread, task_link); t 200 sys/kern/exception.c if (t->slpevt == &exception_event) { t 213 sys/kern/exception.c t = list_entry(n, struct thread, task_link); t 221 sys/kern/exception.c t->excbits |= (1 << excno); t 228 sys/kern/exception.c sched_unsleep(t, SLP_INTR); t 118 sys/kern/sched.c runq_enqueue(thread_t t) t 121 sys/kern/sched.c enqueue(&runq[t->priority], &t->sched_link); t 122 sys/kern/sched.c if (t->priority < maxpri) { t 123 sys/kern/sched.c maxpri = t->priority; t 133 sys/kern/sched.c runq_insert(thread_t t) t 136 sys/kern/sched.c queue_insert(&runq[t->priority], &t->sched_link); t 137 sys/kern/sched.c if (t->priority < maxpri) t 138 sys/kern/sched.c maxpri = t->priority; t 149 sys/kern/sched.c thread_t t; t 152 sys/kern/sched.c t = queue_entry(q, struct thread, sched_link); t 156 sys/kern/sched.c return t; t 163 sys/kern/sched.c runq_remove(thread_t t) t 166 sys/kern/sched.c queue_remove(&t->sched_link); t 177 sys/kern/sched.c thread_t t; t 184 sys/kern/sched.c t = queue_entry(q, struct thread, sched_link); t 185 sys/kern/sched.c t->slpevt = NULL; t 186 sys/kern/sched.c t->state &= ~TS_SLEEP; t 187 sys/kern/sched.c if (t != curthread && t->state == TS_RUN) t 188 sys/kern/sched.c runq_enqueue(t); t 198 sys/kern/sched.c sched_setrun(thread_t t) t 201 sys/kern/sched.c enqueue(&wakeq, &t->sched_link); t 202 sys/kern/sched.c timer_stop(&t->timeout); t 257 sys/kern/sched.c thread_t t = (thread_t)arg; t 259 sys/kern/sched.c sched_unsleep(t, SLP_TIMEOUT); t 310 sys/kern/sched.c thread_t t; t 319 sys/kern/sched.c t = queue_entry(q, struct thread, sched_link); t 320 sys/kern/sched.c t->slpret = 0; t 321 sys/kern/sched.c sched_setrun(t); t 338 sys/kern/sched.c thread_t top, t = NULL; t 352 sys/kern/sched.c t = queue_entry(q, struct thread, sched_link); t 353 sys/kern/sched.c if (t->priority < top->priority) t 354 sys/kern/sched.c top = t; t 363 sys/kern/sched.c return t; t 374 sys/kern/sched.c sched_unsleep(thread_t t, int result) t 379 sys/kern/sched.c if (t->state & TS_SLEEP) { t 381 sys/kern/sched.c queue_remove(&t->sched_link); t 382 sys/kern/sched.c t->slpret = result; t 383 sys/kern/sched.c sched_setrun(t); t 412 sys/kern/sched.c sched_suspend(thread_t t) t 415 sys/kern/sched.c if (t->state == TS_RUN) { t 416 sys/kern/sched.c if (t == curthread) t 419 sys/kern/sched.c runq_remove(t); t 421 sys/kern/sched.c t->state |= TS_SUSP; t 429 sys/kern/sched.c sched_resume(thread_t t) t 432 sys/kern/sched.c if (t->state & TS_SUSP) { t 433 sys/kern/sched.c t->state &= ~TS_SUSP; t 434 sys/kern/sched.c if (t->state == TS_RUN) t 435 sys/kern/sched.c runq_enqueue(t); t 471 sys/kern/sched.c sched_start(thread_t t, int pri, int policy) t 474 sys/kern/sched.c t->state = TS_RUN | TS_SUSP; t 475 sys/kern/sched.c t->policy = policy; t 476 sys/kern/sched.c t->priority = pri; t 477 sys/kern/sched.c t->basepri = pri; t 478 sys/kern/sched.c if (t->policy == SCHED_RR) t 479 sys/kern/sched.c t->timeleft = QUANTUM; t 486 sys/kern/sched.c sched_stop(thread_t t) t 489 sys/kern/sched.c if (t == curthread) { t 499 sys/kern/sched.c if (t->state == TS_RUN) t 500 sys/kern/sched.c runq_remove(t); t 501 sys/kern/sched.c else if (t->state & TS_SLEEP) t 502 sys/kern/sched.c queue_remove(&t->sched_link); t 504 sys/kern/sched.c timer_stop(&t->timeout); t 505 sys/kern/sched.c t->state = TS_EXIT; t 567 sys/kern/sched.c sched_getpri(thread_t t) t 570 sys/kern/sched.c return t->priority; t 581 sys/kern/sched.c sched_setpri(thread_t t, int basepri, int pri) t 584 sys/kern/sched.c t->basepri = basepri; t 586 sys/kern/sched.c if (t == curthread) { t 591 sys/kern/sched.c t->priority = pri; t 596 sys/kern/sched.c if (t->state == TS_RUN) { t 602 sys/kern/sched.c runq_remove(t); t 603 sys/kern/sched.c t->priority = pri; t 604 sys/kern/sched.c runq_enqueue(t); t 606 sys/kern/sched.c t->priority = pri; t 614 sys/kern/sched.c sched_getpolicy(thread_t t) t 617 sys/kern/sched.c return t->policy; t 624 sys/kern/sched.c sched_setpolicy(thread_t t, int policy) t 631 sys/kern/sched.c t->timeleft = QUANTUM; t 632 sys/kern/sched.c t->policy = policy; t 716 sys/kern/sched.c thread_t t; t 728 sys/kern/sched.c t = kthread_create(dpc_thread, NULL, PRI_DPC); t 729 sys/kern/sched.c if (t == NULL) t 232 sys/kern/system.c u_long t; t 234 sys/kern/system.c t = timer_ticks(); t 235 sys/kern/system.c return copyout(&t, ticks, sizeof(t)); t 169 sys/kern/task.c thread_t t; t 198 sys/kern/task.c t = list_entry(n, struct thread, task_link); t 199 sys/kern/task.c if (t != curthread) t 200 sys/kern/task.c thread_destroy(t); t 230 sys/kern/task.c thread_t t; t 248 sys/kern/task.c t = list_entry(n, struct thread, task_link); t 249 sys/kern/task.c thread_suspend(t); t 266 sys/kern/task.c thread_t t; t 290 sys/kern/task.c t = list_entry(n, struct thread, task_link); t 291 sys/kern/task.c thread_resume(t); t 478 sys/kern/task.c thread_t t; t 506 sys/kern/task.c if ((error = thread_create(task, &t)) != 0) t 509 sys/kern/task.c error = thread_load(t, (void (*)(void))mod->entry, sp); t 512 sys/kern/task.c t->priority = PRI_REALTIME; t 513 sys/kern/task.c t->basepri = PRI_REALTIME; t 514 sys/kern/task.c thread_resume(t); t 67 sys/kern/thread.c thread_t t; t 90 sys/kern/thread.c t = NULL; t 91 sys/kern/thread.c if (copyout(&t, tp, sizeof(t))) { t 99 sys/kern/thread.c if ((t = thread_allocate(task)) == NULL) { t 104 sys/kern/thread.c memcpy(t->kstack, curthread->kstack, KSTACKSZ); t 105 sys/kern/thread.c sp = (vaddr_t)t->kstack + KSTACKSZ; t 106 sys/kern/thread.c context_set(&t->ctx, CTX_KSTACK, (register_t)sp); t 107 sys/kern/thread.c context_set(&t->ctx, CTX_KENTRY, (register_t)&syscall_ret); t 108 sys/kern/thread.c sched_start(t, curthread->basepri, SCHED_RR); t 109 sys/kern/thread.c t->suscnt = task->suscnt + 1; t 115 sys/kern/thread.c *tp = t; t 117 sys/kern/thread.c copyout(&t, tp, sizeof(t)); t 129 sys/kern/thread.c thread_terminate(thread_t t) t 133 sys/kern/thread.c if (!thread_valid(t)) { t 137 sys/kern/thread.c if (!task_access(t->task)) { t 141 sys/kern/thread.c thread_destroy(t); t 167 sys/kern/thread.c thread_load(thread_t t, void (*entry)(void), void *stack) t 178 sys/kern/thread.c if (!thread_valid(t)) { t 182 sys/kern/thread.c if (!task_access(t->task)) { t 188 sys/kern/thread.c context_set(&t->ctx, CTX_UENTRY, (register_t)entry); t 190 sys/kern/thread.c context_set(&t->ctx, CTX_USTACK, (register_t)stack); t 211 sys/kern/thread.c thread_valid(thread_t t) t 219 sys/kern/thread.c if (tmp == t) t 243 sys/kern/thread.c thread_suspend(thread_t t) t 247 sys/kern/thread.c if (!thread_valid(t)) { t 251 sys/kern/thread.c if (!task_access(t->task)) { t 255 sys/kern/thread.c if (++t->suscnt == 1) t 256 sys/kern/thread.c sched_suspend(t); t 269 sys/kern/thread.c thread_resume(thread_t t) t 272 sys/kern/thread.c ASSERT(t != curthread); t 275 sys/kern/thread.c if (!thread_valid(t)) { t 279 sys/kern/thread.c if (!task_access(t->task)) { t 283 sys/kern/thread.c if (t->suscnt == 0) { t 287 sys/kern/thread.c t->suscnt--; t 288 sys/kern/thread.c if (t->suscnt == 0 && t->task->suscnt == 0) t 289 sys/kern/thread.c sched_resume(t); t 299 sys/kern/thread.c thread_schedparam(thread_t t, int op, int *param) t 305 sys/kern/thread.c if (!thread_valid(t)) { t 309 sys/kern/thread.c if (t->task->flags & TF_SYSTEM) { t 317 sys/kern/thread.c if (!(t->task == curtask || t->task->parent == curtask) && t 325 sys/kern/thread.c pri = sched_getpri(t); t 360 sys/kern/thread.c if (t->priority != t->basepri && pri > t->priority) t 361 sys/kern/thread.c pri = t->priority; t 363 sys/kern/thread.c mutex_setpri(t, pri); t 364 sys/kern/thread.c sched_setpri(t, pri, pri); t 368 sys/kern/thread.c policy = sched_getpolicy(t); t 378 sys/kern/thread.c error = sched_setpolicy(t, policy); t 413 sys/kern/thread.c struct thread *t; t 416 sys/kern/thread.c if ((t = kmem_alloc(sizeof(*t))) == NULL) t 420 sys/kern/thread.c kmem_free(t); t 423 sys/kern/thread.c memset(t, 0, sizeof(*t)); t 425 sys/kern/thread.c t->kstack = stack; t 426 sys/kern/thread.c t->task = task; t 427 sys/kern/thread.c list_init(&t->mutexes); t 428 sys/kern/thread.c list_insert(&thread_list, &t->link); t 429 sys/kern/thread.c list_insert(&task->threads, &t->task_link); t 432 sys/kern/thread.c return t; t 444 sys/kern/thread.c thread_deallocate(thread_t t) t 447 sys/kern/thread.c list_remove(&t->task_link); t 448 sys/kern/thread.c list_remove(&t->link); t 449 sys/kern/thread.c t->excbits = 0; t 450 sys/kern/thread.c t->task->nthreads--; t 463 sys/kern/thread.c if (t == curthread) { t 468 sys/kern/thread.c zombie = t; t 472 sys/kern/thread.c kmem_free(t->kstack); t 473 sys/kern/thread.c t->kstack = NULL; t 474 sys/kern/thread.c kmem_free(t); t 485 sys/kern/thread.c thread_t t; t 492 sys/kern/thread.c t = list_entry(n, struct thread, link); t 494 sys/kern/thread.c info->id = t; t 495 sys/kern/thread.c info->state = t->state; t 496 sys/kern/thread.c info->policy = t->policy; t 497 sys/kern/thread.c info->priority = t->priority; t 498 sys/kern/thread.c info->basepri = t->basepri; t 499 sys/kern/thread.c info->time = t->time; t 500 sys/kern/thread.c info->suscnt = t->suscnt; t 501 sys/kern/thread.c info->task = t->task; t 502 sys/kern/thread.c info->active = (t == curthread) ? 1 : 0; t 503 sys/kern/thread.c strlcpy(info->taskname, t->task->name, MAXTASKNAME); t 504 sys/kern/thread.c strlcpy(info->slpevt, t->slpevt ? t 505 sys/kern/thread.c t->slpevt->name : "-", MAXEVTNAME); t 527 sys/kern/thread.c thread_t t; t 536 sys/kern/thread.c if ((t = thread_allocate(&kernel_task)) == NULL) t 539 sys/kern/thread.c memset(t->kstack, 0, KSTACKSZ); t 540 sys/kern/thread.c sp = (vaddr_t)t->kstack + KSTACKSZ; t 541 sys/kern/thread.c context_set(&t->ctx, CTX_KSTACK, (register_t)sp); t 542 sys/kern/thread.c context_set(&t->ctx, CTX_KENTRY, (register_t)entry); t 543 sys/kern/thread.c context_set(&t->ctx, CTX_KARG, (register_t)arg); t 544 sys/kern/thread.c sched_start(t, pri, SCHED_FIFO); t 545 sys/kern/thread.c t->suscnt = 1; t 546 sys/kern/thread.c sched_resume(t); t 548 sys/kern/thread.c return t; t 555 sys/kern/thread.c kthread_terminate(thread_t t) t 557 sys/kern/thread.c ASSERT(t != NULL); t 558 sys/kern/thread.c ASSERT(t->task->flags & TF_SYSTEM); t 562 sys/kern/thread.c mutex_cancel(t); t 563 sys/kern/thread.c timer_cancel(t); t 564 sys/kern/thread.c sched_stop(t); t 565 sys/kern/thread.c thread_deallocate(t); t 72 sys/kern/timer.c struct timer *t; t 86 sys/kern/timer.c t = list_entry(n, struct timer, link); t 87 sys/kern/timer.c if (time_before(tmr->expire, t->expire)) t 240 sys/kern/timer.c timer_periodic(thread_t t, u_long start, u_long period) t 249 sys/kern/timer.c if (!thread_valid(t)) { t 253 sys/kern/timer.c if (t->task != curtask) { t 258 sys/kern/timer.c tmr = t->periodic; t 281 sys/kern/timer.c t->periodic = tmr; t 330 sys/kern/timer.c timer_cancel(thread_t t) t 333 sys/kern/timer.c if (t->periodic != NULL) { t 334 sys/kern/timer.c timer_stop(t->periodic); t 335 sys/kern/timer.c kmem_free(t->periodic); t 336 sys/kern/timer.c t->periodic = NULL; t 316 sys/sync/mutex.c mutex_cancel(thread_t t) t 325 sys/sync/mutex.c head = &t->mutexes; t 353 sys/sync/mutex.c mutex_setpri(thread_t t, int pri) t 356 sys/sync/mutex.c if (t->mutex_waiting && pri < t->priority) t 357 sys/sync/mutex.c prio_inherit(t); t 469 sys/sync/mutex.c prio_uninherit(thread_t t) t 476 sys/sync/mutex.c if (t->priority == t->basepri) t 479 sys/sync/mutex.c maxpri = t->basepri; t 486 sys/sync/mutex.c head = &t->mutexes; t 493 sys/sync/mutex.c sched_setpri(t, t->basepri, maxpri); t 402 usr/bin/test/test.c char *s, *t; t 407 usr/bin/test/test.c if ((t = *(t_wp+2)) == 0) t 412 usr/bin/test/test.c (t[0] != ')' || t[1] != '\0'); t 255 usr/lib/libc/gen/fts.c char *t; t 384 usr/lib/libc/gen/fts.c name: t = sp->fts_path + NAPPEND(p->fts_parent); t 385 usr/lib/libc/gen/fts.c *t++ = '/'; t 386 usr/lib/libc/gen/fts.c memmove(t, p->fts_name, p->fts_namelen + 1); t 768 usr/lib/libc/gen/fts.c FTSENT *t; t 830 usr/lib/libc/gen/fts.c for (t = p->fts_parent; t 831 usr/lib/libc/gen/fts.c t->fts_level >= FTS_ROOTLEVEL; t = t->fts_parent) t 832 usr/lib/libc/gen/fts.c if (ino == t->fts_ino && dev == t->fts_dev) { t 833 usr/lib/libc/gen/fts.c p->fts_cycle = t; t 38 usr/lib/libc/gen/time.c time(t) t 39 usr/lib/libc/gen/time.c time_t *t; t 45 usr/lib/libc/gen/time.c if (t != NULL) t 46 usr/lib/libc/gen/time.c *t = tt.tv_sec; t 57 usr/lib/libc/stdio/fflush.c int n, t; t 59 usr/lib/libc/stdio/fflush.c t = fp->_flags; t 60 usr/lib/libc/stdio/fflush.c if ((t & __SWR) == 0) t 73 usr/lib/libc/stdio/fflush.c fp->_w = t & (__SLBF|__SNBF) ? 0 : fp->_bf._size; t 75 usr/lib/libc/stdio/fflush.c for (; n > 0; n -= t, p += t) { t 76 usr/lib/libc/stdio/fflush.c t = __swrite(fp, (char *)p, n); t 77 usr/lib/libc/stdio/fflush.c if (t <= 0) { t 51 usr/lib/libc/stdlib/qsort.c TYPE t = *pi; \ t 53 usr/lib/libc/stdlib/qsort.c *pj++ = t; \ t 74 usr/lib/libc/stdlib/qsort.c long t = *(long *)(void *)(a); \ t 76 usr/lib/libc/stdlib/qsort.c *(long *)(void *)(b) = t; \ t 59 usr/lib/libc/stdlib/random.c long x, hi, lo, t; t 72 usr/lib/libc/stdlib/random.c t = 16807 * lo - 2836 * hi; t 73 usr/lib/libc/stdlib/random.c if (t < 0) t 74 usr/lib/libc/stdlib/random.c t += 0x7fffffff; t 75 usr/lib/libc/stdlib/random.c randseed = t; t 76 usr/lib/libc/stdlib/random.c return (t); t 34 usr/lib/libc/string/memccpy.c memccpy(t, f, c, n) t 35 usr/lib/libc/string/memccpy.c void *t; t 42 usr/lib/libc/string/memccpy.c unsigned char *tp = t; t 46 usr/lib/libc/string/memccpy.c return (t); t 38 usr/lib/libc/termios/cfgetispeed.c cfgetispeed(t) t 39 usr/lib/libc/termios/cfgetispeed.c const struct termios *t; t 42 usr/lib/libc/termios/cfgetispeed.c return (t->c_ispeed); t 38 usr/lib/libc/termios/cfgetospeed.c cfgetospeed(t) t 39 usr/lib/libc/termios/cfgetospeed.c const struct termios *t; t 42 usr/lib/libc/termios/cfgetospeed.c return (t->c_ospeed); t 40 usr/lib/libc/termios/cfmakeraw.c cfmakeraw(t) t 41 usr/lib/libc/termios/cfmakeraw.c struct termios *t; t 44 usr/lib/libc/termios/cfmakeraw.c t->c_iflag &= ~(IGNBRK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON); t 45 usr/lib/libc/termios/cfmakeraw.c t->c_oflag &= ~OPOST; t 46 usr/lib/libc/termios/cfmakeraw.c t->c_lflag &= ~(ECHO|ECHONL|ICANON|ISIG|IEXTEN); t 47 usr/lib/libc/termios/cfmakeraw.c t->c_cflag &= ~(CSIZE|PARENB); t 48 usr/lib/libc/termios/cfmakeraw.c t->c_cflag |= CS8; t 38 usr/lib/libc/termios/cfsetispeed.c cfsetispeed(t, speed) t 39 usr/lib/libc/termios/cfsetispeed.c struct termios *t; t 43 usr/lib/libc/termios/cfsetispeed.c t->c_ispeed = speed; t 38 usr/lib/libc/termios/cfsetospeed.c cfsetospeed(t, speed) t 39 usr/lib/libc/termios/cfsetospeed.c struct termios *t; t 43 usr/lib/libc/termios/cfsetospeed.c t->c_ospeed = speed; t 38 usr/lib/libc/termios/cfsetspeed.c cfsetspeed(t, speed) t 39 usr/lib/libc/termios/cfsetspeed.c struct termios *t; t 43 usr/lib/libc/termios/cfsetspeed.c t->c_ispeed = t->c_ospeed = speed; t 36 usr/lib/libc/termios/tcgetattr.c tcgetattr(fd, t) t 38 usr/lib/libc/termios/tcgetattr.c struct termios *t; t 41 usr/lib/libc/termios/tcgetattr.c return (ioctl(fd, TIOCGETA, t)); t 39 usr/lib/libc/termios/tcsetattr.c tcsetattr(fd, opt, t) t 41 usr/lib/libc/termios/tcsetattr.c const struct termios *t; t 46 usr/lib/libc/termios/tcsetattr.c localterm = *t; t 48 usr/lib/libc/termios/tcsetattr.c t = &localterm; t 52 usr/lib/libc/termios/tcsetattr.c return (ioctl(fd, TIOCSETA, t)); t 54 usr/lib/libc/termios/tcsetattr.c return (ioctl(fd, TIOCSETAW, t)); t 56 usr/lib/libc/termios/tcsetattr.c return (ioctl(fd, TIOCSETAF, t)); t 45 usr/lib/libc/time/gmtime_r.c time_t t; t 49 usr/lib/libc/time/gmtime_r.c t = *timep; t 50 usr/lib/libc/time/gmtime_r.c days = t / 60 / 60 / 24; t 72 usr/lib/libc/time/gmtime_r.c tmp->tm_sec = t % 60; t 73 usr/lib/libc/time/gmtime_r.c tmp->tm_min = (t / 60) % 60; t 74 usr/lib/libc/time/gmtime_r.c tmp->tm_hour = (t / 60 / 60) % 24; t 59 usr/lib/libc/time/strftime.c strftime(s, maxsize, format, t) t 63 usr/lib/libc/time/strftime.c const struct tm *t; t 69 usr/lib/libc/time/strftime.c if (_fmt(format, t)) { t 77 usr/lib/libc/time/strftime.c _fmt(format, t) t 79 usr/lib/libc/time/strftime.c const struct tm *t; t 88 usr/lib/libc/time/strftime.c if (t->tm_wday < 0 || t->tm_wday > 6) t 90 usr/lib/libc/time/strftime.c if (!_add(Afmt[t->tm_wday])) t 94 usr/lib/libc/time/strftime.c if (t->tm_wday < 0 || t->tm_wday > 6) t 96 usr/lib/libc/time/strftime.c if (!_add(afmt[t->tm_wday])) t 100 usr/lib/libc/time/strftime.c if (t->tm_mon < 0 || t->tm_mon > 11) t 102 usr/lib/libc/time/strftime.c if (!_add(Bfmt[t->tm_mon])) t 107 usr/lib/libc/time/strftime.c if (t->tm_mon < 0 || t->tm_mon > 11) t 109 usr/lib/libc/time/strftime.c if (!_add(bfmt[t->tm_mon])) t 113 usr/lib/libc/time/strftime.c if (!_fmt("%a %b %e %H:%M:%S %Y", t)) t 117 usr/lib/libc/time/strftime.c if (!_fmt("%m/%d/%y %H:%M:%S", t)) t 121 usr/lib/libc/time/strftime.c if (!_fmt("%m/%d/%y", t)) t 125 usr/lib/libc/time/strftime.c if (!_conv(t->tm_mday, 2, '0')) t 129 usr/lib/libc/time/strftime.c if (!_conv(t->tm_mday, 2, ' ')) t 133 usr/lib/libc/time/strftime.c if (!_conv(t->tm_hour, 2, '0')) t 137 usr/lib/libc/time/strftime.c if (!_conv(t->tm_hour % 12 ? t 138 usr/lib/libc/time/strftime.c t->tm_hour % 12 : 12, 2, '0')) t 142 usr/lib/libc/time/strftime.c if (!_conv(t->tm_yday + 1, 3, '0')) t 146 usr/lib/libc/time/strftime.c if (!_conv(t->tm_hour, 2, ' ')) t 150 usr/lib/libc/time/strftime.c if (!_conv(t->tm_hour % 12 ? t 151 usr/lib/libc/time/strftime.c t->tm_hour % 12 : 12, 2, ' ')) t 155 usr/lib/libc/time/strftime.c if (!_conv(t->tm_min, 2, '0')) t 159 usr/lib/libc/time/strftime.c if (!_conv(t->tm_mon + 1, 2, '0')) t 167 usr/lib/libc/time/strftime.c if (!_add(t->tm_hour >= 12 ? "PM" : "AM")) t 171 usr/lib/libc/time/strftime.c if (!_fmt("%H:%M", t)) t 175 usr/lib/libc/time/strftime.c if (!_fmt("%I:%M:%S %p", t)) t 179 usr/lib/libc/time/strftime.c if (!_conv(t->tm_sec, 2, '0')) t 183 usr/lib/libc/time/strftime.c if (!_secs(t)) t 188 usr/lib/libc/time/strftime.c if (!_fmt("%H:%M:%S", t)) t 196 usr/lib/libc/time/strftime.c if (!_conv((t->tm_yday + 7 - t->tm_wday) / 7, t 201 usr/lib/libc/time/strftime.c if (!_conv((t->tm_yday + 7 - t 202 usr/lib/libc/time/strftime.c (t->tm_wday ? (t->tm_wday - 1) : 6)) t 207 usr/lib/libc/time/strftime.c if (!_conv(t->tm_wday, 1, '0')) t 211 usr/lib/libc/time/strftime.c if (!_fmt("%m/%d/%y", t)) t 215 usr/lib/libc/time/strftime.c if (!_conv((t->tm_year + TM_YEAR_BASE) t 220 usr/lib/libc/time/strftime.c if (!_conv(t->tm_year + TM_YEAR_BASE, 4, '0')) t 246 usr/lib/libc/time/strftime.c _secs(t) t 247 usr/lib/libc/time/strftime.c const struct tm *t; t 255 usr/lib/libc/time/strftime.c tmp = *t; t 87 usr/lib/posix/process/fork.c thread_t t; t 101 usr/lib/posix/process/fork.c if ((error = thread_create(tsk, &t)) != 0) { t 127 usr/lib/posix/process/fork.c thread_load(t, __child_entry, NULL); t 128 usr/lib/posix/process/fork.c thread_resume(t); t 89 usr/lib/posix/process/fork_nommu.c thread_t t; t 102 usr/lib/posix/process/fork_nommu.c if ((error = thread_create(tsk, &t)) != 0) { t 133 usr/lib/posix/process/fork_nommu.c thread_load(t, __child_entry, NULL); t 134 usr/lib/posix/process/fork_nommu.c thread_getpri(t, &pri); t 135 usr/lib/posix/process/fork_nommu.c thread_setpri(t, pri + 1); t 136 usr/lib/posix/process/fork_nommu.c thread_resume(t); t 149 usr/lib/posix/process/fork_nommu.c t = thread_self(); t 150 usr/lib/posix/process/fork_nommu.c thread_getpri(t, &pri); t 151 usr/lib/posix/process/fork_nommu.c thread_setpri(t, pri - 1); t 32 usr/lib/prex/syscalls/thread_getpolicy.c extern int thread_schedparam(thread_t t, int op, int *param); t 35 usr/lib/prex/syscalls/thread_getpolicy.c thread_getpolicy(thread_t t, int *policy) t 38 usr/lib/prex/syscalls/thread_getpolicy.c return thread_schedparam(t, 2, policy); t 32 usr/lib/prex/syscalls/thread_getpri.c extern int thread_schedparam(thread_t t, int op, int *param); t 35 usr/lib/prex/syscalls/thread_getpri.c thread_getpri(thread_t t, int *pri) t 38 usr/lib/prex/syscalls/thread_getpri.c return thread_schedparam(t, 0, pri); t 32 usr/lib/prex/syscalls/thread_setpolicy.c extern int thread_schedparam(thread_t t, int op, int *param); t 35 usr/lib/prex/syscalls/thread_setpolicy.c thread_setpolicy(thread_t t, int policy) t 38 usr/lib/prex/syscalls/thread_setpolicy.c return thread_schedparam(t, 3, &policy); t 32 usr/lib/prex/syscalls/thread_setpri.c extern int thread_schedparam(thread_t t, int op, int *param); t 35 usr/lib/prex/syscalls/thread_setpri.c thread_setpri(thread_t t, int pri) t 38 usr/lib/prex/syscalls/thread_setpri.c return thread_schedparam(t, 1, &pri); t 52 usr/sample/balls/balls.c thread_t t; t 54 usr/sample/balls/balls.c if (thread_create(task_self(), &t) != 0) t 56 usr/sample/balls/balls.c if (thread_load(t, start, stack) != 0) t 58 usr/sample/balls/balls.c if (thread_resume(t) != 0) t 60 usr/sample/balls/balls.c return t; t 57 usr/sample/ipc/ipc.c thread_t t; t 65 usr/sample/ipc/ipc.c if (thread_create(task, &t) != 0) t 68 usr/sample/ipc/ipc.c if (thread_load(t, func, stack) != 0) t 71 usr/sample/ipc/ipc.c if (thread_resume(t) != 0) t 84 usr/sample/mutex/mutex.c thread_t t; t 86 usr/sample/mutex/mutex.c if (thread_create(task_self(), &t) != 0) t 89 usr/sample/mutex/mutex.c if (thread_load(t, start, stack) != 0) t 92 usr/sample/mutex/mutex.c return t; t 42 usr/sample/sem/sem.c thread_t t; t 44 usr/sample/sem/sem.c if (thread_create(task_self(), &t) != 0) t 47 usr/sample/sem/sem.c if (thread_load(t, start, stack) != 0) t 50 usr/sample/sem/sem.c if (thread_resume(t) != 0) t 63 usr/sample/sem/sem.c thread_t t; t 65 usr/sample/sem/sem.c t = thread_self(); t 66 usr/sample/sem/sem.c printf("Start thread=%x\n", (u_int)t); t 77 usr/sample/sem/sem.c printf("Running thread=%x\n", (u_int)t); t 85 usr/sample/sem/sem.c printf("End thread=%x\n", (u_int)t); t 86 usr/sample/sem/sem.c thread_terminate(t); t 48 usr/sample/task/task.c thread_t t; t 54 usr/sample/task/task.c if (thread_create(task, &t) != 0) t 57 usr/sample/task/task.c if (thread_load(t, func, stack + 1024) != 0) t 60 usr/sample/task/task.c if (thread_resume(t) != 0) t 54 usr/sample/thread/thread.c thread_t t; t 56 usr/sample/thread/thread.c if (thread_create(task_self(), &t) != 0) t 59 usr/sample/thread/thread.c if (thread_load(t, start, stack) != 0) t 62 usr/sample/thread/thread.c if (thread_setpri(t, 128) != 0) t 65 usr/sample/thread/thread.c if (thread_resume(t) != 0) t 125 usr/sbin/lock/lock.c char *p, *t; t 134 usr/sbin/lock/lock.c for (t = p; *t && isdigit(*t); ++t); t 135 usr/sbin/lock/lock.c if (strlen(p) != 4 || *t) { t 77 usr/server/exec/exec_execve.c thread_t t; t 172 usr/server/exec/exec_execve.c if ((error = thread_create(new_task, &t)) != 0) t 194 usr/server/exec/exec_execve.c if ((error = thread_load(t, (void (*)(void))exec.entry, sp)) != 0) t 210 usr/server/exec/exec_execve.c thread_setpri(t, PRI_DEFAULT); t 211 usr/server/exec/exec_execve.c thread_resume(t); t 218 usr/server/exec/exec_execve.c thread_terminate(t); t 89 usr/server/fs/vfs/main.c fs_mount(struct task *t, struct mount_msg *msg) t 94 usr/server/fs/vfs/main.c if (task_chkcap(t->t_taskid, CAP_DISKADMIN) != 0) t 109 usr/server/fs/vfs/main.c fs_umount(struct task *t, struct path_msg *msg) t 113 usr/server/fs/vfs/main.c if (task_chkcap(t->t_taskid, CAP_DISKADMIN) != 0) t 120 usr/server/fs/vfs/main.c fs_sync(struct task *t, struct msg *msg) t 127 usr/server/fs/vfs/main.c fs_open(struct task *t, struct open_msg *msg) t 135 usr/server/fs/vfs/main.c if ((fd = task_newfd(t)) == -1) t 150 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, acc, path)) != 0) t 156 usr/server/fs/vfs/main.c t->t_ofile[fd] = fp; t 157 usr/server/fs/vfs/main.c t->t_nopens++; t 163 usr/server/fs/vfs/main.c fs_close(struct task *t, struct msg *msg) t 172 usr/server/fs/vfs/main.c fp = t->t_ofile[fd]; t 179 usr/server/fs/vfs/main.c t->t_ofile[fd] = NULL; t 180 usr/server/fs/vfs/main.c t->t_nopens--; t 185 usr/server/fs/vfs/main.c fs_mknod(struct task *t, struct open_msg *msg) t 190 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, VWRITE, path)) != 0) t 197 usr/server/fs/vfs/main.c fs_lseek(struct task *t, struct msg *msg) t 203 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->data[0])) == NULL) t 214 usr/server/fs/vfs/main.c fs_read(struct task *t, struct io_msg *msg) t 221 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->fd)) == NULL) t 234 usr/server/fs/vfs/main.c fs_write(struct task *t, struct io_msg *msg) t 241 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->fd)) == NULL) t 254 usr/server/fs/vfs/main.c fs_ioctl(struct task *t, struct ioctl_msg *msg) t 258 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->fd)) == NULL) t 265 usr/server/fs/vfs/main.c fs_fsync(struct task *t, struct msg *msg) t 269 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->data[0])) == NULL) t 276 usr/server/fs/vfs/main.c fs_fstat(struct task *t, struct stat_msg *msg) t 282 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->fd)) == NULL) t 291 usr/server/fs/vfs/main.c fs_opendir(struct task *t, struct open_msg *msg) t 298 usr/server/fs/vfs/main.c if ((fd = task_newfd(t)) == -1) t 302 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, VREAD, path)) != 0) t 307 usr/server/fs/vfs/main.c t->t_ofile[fd] = fp; t 313 usr/server/fs/vfs/main.c fs_closedir(struct task *t, struct msg *msg) t 321 usr/server/fs/vfs/main.c fp = t->t_ofile[fd]; t 327 usr/server/fs/vfs/main.c t->t_ofile[fd] = NULL; t 332 usr/server/fs/vfs/main.c fs_readdir(struct task *t, struct dir_msg *msg) t 336 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->fd)) == NULL) t 343 usr/server/fs/vfs/main.c fs_rewinddir(struct task *t, struct msg *msg) t 347 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->data[0])) == NULL) t 354 usr/server/fs/vfs/main.c fs_seekdir(struct task *t, struct msg *msg) t 359 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->data[0])) == NULL) t 367 usr/server/fs/vfs/main.c fs_telldir(struct task *t, struct msg *msg) t 373 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->data[0])) == NULL) t 384 usr/server/fs/vfs/main.c fs_mkdir(struct task *t, struct open_msg *msg) t 389 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, VWRITE, path)) != 0) t 396 usr/server/fs/vfs/main.c fs_rmdir(struct task *t, struct path_msg *msg) t 403 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, VWRITE, path)) != 0) t 410 usr/server/fs/vfs/main.c fs_rename(struct task *t, struct path_msg *msg) t 419 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, VREAD, src)) != 0) t 422 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path2, VWRITE, dest)) != 0) t 429 usr/server/fs/vfs/main.c fs_chdir(struct task *t, struct path_msg *msg) t 437 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, VREAD, path)) != 0) t 443 usr/server/fs/vfs/main.c if (t->t_cwdfp) t 444 usr/server/fs/vfs/main.c sys_closedir(t->t_cwdfp); t 445 usr/server/fs/vfs/main.c t->t_cwdfp = fp; t 446 usr/server/fs/vfs/main.c strlcpy(t->t_cwd, path, sizeof(t->t_cwd)); t 451 usr/server/fs/vfs/main.c fs_fchdir(struct task *t, struct msg *msg) t 457 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, fd)) == NULL) t 460 usr/server/fs/vfs/main.c if (t->t_cwdfp) t 461 usr/server/fs/vfs/main.c sys_closedir(t->t_cwdfp); t 462 usr/server/fs/vfs/main.c t->t_cwdfp = fp; t 463 usr/server/fs/vfs/main.c return sys_fchdir(fp, t->t_cwd); t 467 usr/server/fs/vfs/main.c fs_link(struct task *t, struct msg *msg) t 474 usr/server/fs/vfs/main.c fs_unlink(struct task *t, struct path_msg *msg) t 481 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, VWRITE, path)) != 0) t 488 usr/server/fs/vfs/main.c fs_stat(struct task *t, struct stat_msg *msg) t 494 usr/server/fs/vfs/main.c error = task_conv(t, msg->path, 0, path); t 503 usr/server/fs/vfs/main.c fs_getcwd(struct task *t, struct path_msg *msg) t 506 usr/server/fs/vfs/main.c strlcpy(msg->path, t->t_cwd, sizeof(msg->path)); t 514 usr/server/fs/vfs/main.c fs_dup(struct task *t, struct msg *msg) t 520 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, old_fd)) == NULL) t 524 usr/server/fs/vfs/main.c if ((new_fd = task_newfd(t)) == -1) t 527 usr/server/fs/vfs/main.c t->t_ofile[new_fd] = fp; t 541 usr/server/fs/vfs/main.c fs_dup2(struct task *t, struct msg *msg) t 551 usr/server/fs/vfs/main.c fp = t->t_ofile[old_fd]; t 554 usr/server/fs/vfs/main.c org = t->t_ofile[new_fd]; t 559 usr/server/fs/vfs/main.c t->t_ofile[new_fd] = fp; t 573 usr/server/fs/vfs/main.c fs_fcntl(struct task *t, struct fcntl_msg *msg) t 578 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->fd)) == NULL) t 587 usr/server/fs/vfs/main.c if ((new_fd = task_newfd(t)) == -1) t 589 usr/server/fs/vfs/main.c t->t_ofile[new_fd] = fp; t 619 usr/server/fs/vfs/main.c fs_access(struct task *t, struct path_msg *msg) t 631 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, acc, path)) != 0) t 641 usr/server/fs/vfs/main.c fs_fork(struct task *t, struct msg *msg) t 655 usr/server/fs/vfs/main.c newtask->t_cwdfp = t->t_cwdfp; t 656 usr/server/fs/vfs/main.c strlcpy(newtask->t_cwd, t->t_cwd, sizeof(newtask->t_cwd)); t 658 usr/server/fs/vfs/main.c fp = t->t_ofile[i]; t 685 usr/server/fs/vfs/main.c fs_exec(struct task *t, struct msg *msg) t 721 usr/server/fs/vfs/main.c fs_exit(struct task *t, struct msg *msg) t 732 usr/server/fs/vfs/main.c fp = t->t_ofile[fd]; t 736 usr/server/fs/vfs/main.c if (t->t_cwdfp) t 737 usr/server/fs/vfs/main.c sys_close(t->t_cwdfp); t 738 usr/server/fs/vfs/main.c task_free(t); t 747 usr/server/fs/vfs/main.c fs_register(struct task *t, struct msg *msg) t 759 usr/server/fs/vfs/main.c fs_pipe(struct task *t, struct msg *msg) t 768 usr/server/fs/vfs/main.c if ((rfd = task_newfd(t)) == -1) t 770 usr/server/fs/vfs/main.c t->t_ofile[rfd] = (file_t)1; /* temp */ t 772 usr/server/fs/vfs/main.c if ((wfd = task_newfd(t)) == -1) { t 773 usr/server/fs/vfs/main.c t->t_ofile[rfd] = NULL; t 776 usr/server/fs/vfs/main.c sprintf(path, "/mnt/fifo/pipe-%x-%d", (u_int)t->t_taskid, rfd); t 786 usr/server/fs/vfs/main.c t->t_ofile[rfd] = rfp; t 787 usr/server/fs/vfs/main.c t->t_ofile[wfd] = wfp; t 788 usr/server/fs/vfs/main.c t->t_nopens += 2; t 793 usr/server/fs/vfs/main.c t->t_ofile[rfd] = NULL; t 794 usr/server/fs/vfs/main.c t->t_ofile[wfd] = NULL; t 805 usr/server/fs/vfs/main.c fs_isatty(struct task *t, struct msg *msg) t 810 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->data[0])) == NULL) t 820 usr/server/fs/vfs/main.c fs_truncate(struct task *t, struct path_msg *msg) t 827 usr/server/fs/vfs/main.c if ((error = task_conv(t, msg->path, VWRITE, path)) != 0) t 834 usr/server/fs/vfs/main.c fs_ftruncate(struct task *t, struct msg *msg) t 838 usr/server/fs/vfs/main.c if ((fp = task_getfp(t, msg->data[0])) == NULL) t 848 usr/server/fs/vfs/main.c fs_boot(struct task *t, struct msg *msg) t 883 usr/server/fs/vfs/main.c fs_shutdown(struct task *t, struct msg *msg) t 901 usr/server/fs/vfs/main.c fs_debug(struct task *t, struct msg *msg) t 948 usr/server/fs/vfs/main.c thread_t t; t 953 usr/server/fs/vfs/main.c if ((error = thread_create(self, &t)) != 0) t 959 usr/server/fs/vfs/main.c if ((error = thread_load(t, entry, sp)) != 0) t 962 usr/server/fs/vfs/main.c return thread_resume(t); t 1031 usr/server/fs/vfs/main.c struct task *t; t 1063 usr/server/fs/vfs/main.c t = task_lookup(msg->hdr.task); t 1064 usr/server/fs/vfs/main.c if (t == NULL) t 1068 usr/server/fs/vfs/main.c error = (*map->func)(t, msg); t 1070 usr/server/fs/vfs/main.c task_unlock(t); t 128 usr/server/fs/vfs/vfs.h void task_free(struct task *t); t 129 usr/server/fs/vfs/vfs.h void task_setid(struct task *t, task_t task); t 130 usr/server/fs/vfs/vfs.h void task_unlock(struct task *t); t 132 usr/server/fs/vfs/vfs.h file_t task_getfp(struct task *t, int fd); t 133 usr/server/fs/vfs/vfs.h void task_setfp(struct task *t, int fd, file_t fp); t 134 usr/server/fs/vfs/vfs.h int task_newfd(struct task *t); t 135 usr/server/fs/vfs/vfs.h void task_delfd(struct task *t, int fd); t 137 usr/server/fs/vfs/vfs.h int task_conv(struct task *t, char *path, int mode, char *full); t 55 usr/server/fs/vfs/vfs_bio.c #define SET(t, f) (t) |= (f) t 56 usr/server/fs/vfs/vfs_bio.c #define CLR(t, f) (t) &= ~(f) t 57 usr/server/fs/vfs/vfs_bio.c #define ISSET(t, f) ((t) & (f)) t 73 usr/server/fs/vfs/vfs_task.c struct task *t; t 81 usr/server/fs/vfs/vfs_task.c t = list_entry(n, struct task, t_link); t 82 usr/server/fs/vfs/vfs_task.c ASSERT(t->t_taskid); t 83 usr/server/fs/vfs/vfs_task.c if (t->t_taskid == task) { t 85 usr/server/fs/vfs/vfs_task.c mutex_lock(&t->t_lock); t 86 usr/server/fs/vfs/vfs_task.c return t; t 101 usr/server/fs/vfs/vfs_task.c struct task *t; t 107 usr/server/fs/vfs/vfs_task.c if (!(t = malloc(sizeof(struct task)))) t 109 usr/server/fs/vfs/vfs_task.c memset(t, 0, sizeof(struct task)); t 110 usr/server/fs/vfs/vfs_task.c t->t_taskid = task; t 111 usr/server/fs/vfs/vfs_task.c strlcpy(t->t_cwd, "/", sizeof(t->t_cwd)); t 112 usr/server/fs/vfs/vfs_task.c mutex_init(&t->t_lock); t 115 usr/server/fs/vfs/vfs_task.c list_insert(&task_table[TASKHASH(task)], &t->t_link); t 117 usr/server/fs/vfs/vfs_task.c *pt = t; t 125 usr/server/fs/vfs/vfs_task.c task_free(struct task *t) t 129 usr/server/fs/vfs/vfs_task.c list_remove(&t->t_link); t 130 usr/server/fs/vfs/vfs_task.c mutex_unlock(&t->t_lock); t 131 usr/server/fs/vfs/vfs_task.c mutex_destroy(&t->t_lock); t 132 usr/server/fs/vfs/vfs_task.c free(t); t 140 usr/server/fs/vfs/vfs_task.c task_setid(struct task *t, task_t task) t 144 usr/server/fs/vfs/vfs_task.c list_remove(&t->t_link); t 145 usr/server/fs/vfs/vfs_task.c t->t_taskid = task; t 146 usr/server/fs/vfs/vfs_task.c list_insert(&task_table[TASKHASH(task)], &t->t_link); t 154 usr/server/fs/vfs/vfs_task.c task_unlock(struct task *t) t 157 usr/server/fs/vfs/vfs_task.c mutex_unlock(&t->t_lock); t 165 usr/server/fs/vfs/vfs_task.c task_getfp(struct task *t, int fd) t 171 usr/server/fs/vfs/vfs_task.c return t->t_ofile[fd]; t 178 usr/server/fs/vfs/vfs_task.c task_setfp(struct task *t, int fd, file_t fp) t 181 usr/server/fs/vfs/vfs_task.c t->t_ofile[fd] = fp; t 189 usr/server/fs/vfs/vfs_task.c task_newfd(struct task *t) t 197 usr/server/fs/vfs/vfs_task.c if (t->t_ofile[fd] == NULL) t 210 usr/server/fs/vfs/vfs_task.c task_delfd(struct task *t, int fd) t 213 usr/server/fs/vfs/vfs_task.c t->t_ofile[fd] = NULL; t 224 usr/server/fs/vfs/vfs_task.c task_conv(struct task *t, char *path, int acc, char *full) t 229 usr/server/fs/vfs/vfs_task.c cwd = t->t_cwd; t 289 usr/server/fs/vfs/vfs_task.c return sec_file_permission(t->t_taskid, full, acc); t 297 usr/server/fs/vfs/vfs_task.c struct task *t; t 307 usr/server/fs/vfs/vfs_task.c t = list_entry(n, struct task, t_link); t 308 usr/server/fs/vfs/vfs_task.c dprintf(" %08x %7x %s\n", (int)t->t_taskid, t->t_nopens, t 309 usr/server/fs/vfs/vfs_task.c t->t_cwd); t 269 usr/server/pow/pow.c thread_t t; t 274 usr/server/pow/pow.c if ((error = thread_create(self, &t)) != 0) t 280 usr/server/pow/pow.c if ((error = thread_load(t, entry, sp)) != 0) t 283 usr/server/pow/pow.c return thread_resume(t); t 52 usr/test/attack/attack.c thread_t t = (thread_t)random(); t 96 usr/test/attack/attack.c thread_suspend(t); t 97 usr/test/attack/attack.c thread_terminate(t); t 60 usr/test/deadlock/deadlock.c thread_t t; t 63 usr/test/deadlock/deadlock.c error = thread_create(task_self(), &t); t 67 usr/test/deadlock/deadlock.c error = thread_load(t, start, stack); t 71 usr/test/deadlock/deadlock.c return t; t 46 usr/test/ipc/ipc.c thread_t t; t 49 usr/test/ipc/ipc.c error = thread_create(task_self(), &t); t 53 usr/test/ipc/ipc.c error = thread_load(t, start, stack); t 57 usr/test/ipc/ipc.c error = thread_resume(t); t 48 usr/test/ipc_mt/ipc_mt.c thread_t t; t 51 usr/test/ipc_mt/ipc_mt.c error = thread_create(task_self(), &t); t 55 usr/test/ipc_mt/ipc_mt.c error = thread_load(t, start, stack); t 59 usr/test/ipc_mt/ipc_mt.c error = thread_resume(t); t 117 usr/test/kmon/cmd.c thread_t t; t 124 usr/test/kmon/cmd.c t = (thread_t)strtoul(argv[1], &ep, 16); t 125 usr/test/kmon/cmd.c printf("Kill thread id:%x\n", (u_int)t); t 127 usr/test/kmon/cmd.c if (thread_terminate(t)) t 128 usr/test/kmon/cmd.c printf("Thread %x does not exist\n", (u_int)t); t 57 usr/test/task/task.c thread_t t; t 85 usr/test/task/task.c error = thread_create(task, &t); t 87 usr/test/task/task.c error = thread_load(t, test_thread, stack[i]+1024); t 89 usr/test/task/task.c thread_resume(t); t 42 usr/test/thread/thread.c thread_t t; t 45 usr/test/thread/thread.c if ((error = thread_create(task_self(), &t)) != 0) t 48 usr/test/thread/thread.c if ((error = thread_load(t, start, stack)) != 0) t 51 usr/test/thread/thread.c if ((error = thread_resume(t)) != 0) t 54 usr/test/thread/thread.c return t; t 69 usr/test/thread/thread.c thread_t self, t; t 79 usr/test/thread/thread.c t = thread_run(test_thread, stack+1024); t 90 usr/test/thread/thread.c error = thread_suspend(t); t 101 usr/test/thread/thread.c error = thread_resume(t); t 111 usr/test/thread/thread.c thread_suspend(t); t 121 usr/test/thread/thread.c thread_resume(t);