Changes in kernel/generic/src/proc/thread.c [26aafe8:7e7b791] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/proc/thread.c
r26aafe8 r7e7b791 68 68 #include <errno.h> 69 69 70 71 #ifndef LOADED_PROG_STACK_PAGES_NO 72 #define LOADED_PROG_STACK_PAGES_NO 1 73 #endif 74 75 70 76 /** Thread states */ 71 77 const char *thread_states[] = { … … 294 300 295 301 /* Not needed, but good for debugging */ 296 memsetb(thread->kstack, STACK_SIZE, 0);302 memsetb(thread->kstack, THREAD_STACK_SIZE * 1 << STACK_FRAMES, 0); 297 303 298 304 irq_spinlock_lock(&tidlock, true); … … 302 308 context_save(&thread->saved_context); 303 309 context_set(&thread->saved_context, FADDR(cushion), 304 (uintptr_t) thread->kstack, STACK_SIZE);310 (uintptr_t) thread->kstack, THREAD_STACK_SIZE); 305 311 306 312 the_initialize((the_t *) thread->kstack); … … 599 605 printf("%-8" PRIu64 " %-14s %10p %-8s %10p %-5" PRIu32 "\n", 600 606 thread->tid, name, thread, thread_states[thread->state], 601 thread->task, thread->task->cont ainer);607 thread->task, thread->task->context); 602 608 #endif 603 609 … … 611 617 printf("%-8" PRIu64 " %-14s %18p %-8s %18p %-5" PRIu32 "\n", 612 618 thread->tid, name, thread, thread_states[thread->state], 613 thread->task, thread->task->cont ainer);619 thread->task, thread->task->context); 614 620 #endif 615 621 … … 652 658 else 653 659 printf("[id ] [name ] [address ] [state ] [task ]" 654 " [ct n]\n");660 " [ctx]\n"); 655 661 #endif 656 662 … … 661 667 } else 662 668 printf("[id ] [name ] [address ] [state ]" 663 " [task ] [ct n]\n");669 " [task ] [ctx]\n"); 664 670 #endif 665 671 … … 912 918 } 913 919 920 sysarg_t sys_thread_udelay(uint32_t usec) 921 { 922 asm_delay_loop(usec * CPU->delay_loop_const); 923 return 0; 924 } 925 914 926 /** @} 915 927 */
Note:
See TracChangeset
for help on using the changeset viewer.