Changeset ff14c520 in mainline for generic/src/proc/thread.c
- Timestamp:
- 2006-03-16T22:31:39Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 93165be
- Parents:
- 37c57f2
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
generic/src/proc/thread.c
r37c57f2 rff14c520 249 249 * @param task Task to which the thread belongs. 250 250 * @param flags Thread flags. 251 * @param name Symbolic name. 251 252 * 252 253 * @return New thread's structure on success, NULL on failure. 253 254 * 254 255 */ 255 thread_t *thread_create(void (* func)(void *), void *arg, task_t *task, int flags )256 thread_t *thread_create(void (* func)(void *), void *arg, task_t *task, int flags, char *name) 256 257 { 257 258 thread_t *t; … … 280 281 interrupts_restore(ipl); 281 282 283 t->name = name; 282 284 t->thread_code = func; 283 285 t->thread_arg = arg; … … 410 412 for (cur=threads_head.next; cur!=&threads_head; cur=cur->next) { 411 413 t = list_get_instance(cur, thread_t, threads_link); 412 printf("Thr: %d(%s) ", t->tid, thread_states[t->state]); 414 printf("%s: address=%P, tid=%d, state=%s, task=%P, code=%P, stack=%P, cpu=", 415 t->name, t, t->tid, thread_states[t->state], t->task, t->thread_code, t->kstack); 413 416 if (t->cpu) 414 417 printf("cpu%d ", t->cpu->id); 418 else 419 printf("none"); 415 420 printf("\n"); 416 421 }
Note:
See TracChangeset
for help on using the changeset viewer.