Rev 1115 | Rev 1158 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1115 | Rev 1138 | ||
---|---|---|---|
Line 264... | Line 264... | ||
264 | t = (thread_t *) slab_alloc(thread_slab, 0); |
264 | t = (thread_t *) slab_alloc(thread_slab, 0); |
265 | if (!t) |
265 | if (!t) |
266 | return NULL; |
266 | return NULL; |
267 | 267 | ||
268 | /* Not needed, but good for debugging */ |
268 | /* Not needed, but good for debugging */ |
269 | memsetb((__address)t->kstack, THREAD_STACK_SIZE, 0); |
269 | memsetb((__address)t->kstack, THREAD_STACK_SIZE * 1<<STACK_FRAMES, 0); |
270 | 270 | ||
271 | ipl = interrupts_disable(); |
271 | ipl = interrupts_disable(); |
272 | spinlock_lock(&tidlock); |
272 | spinlock_lock(&tidlock); |
273 | t->tid = ++last_tid; |
273 | t->tid = ++last_tid; |
274 | spinlock_unlock(&tidlock); |
274 | spinlock_unlock(&tidlock); |