From f59a0547109ab2e1afd1572b118065e778379fcd Mon Sep 17 00:00:00 2001 From: Stefano Ceccherini Date: Tue, 8 Jun 2004 14:26:22 +0000 Subject: [PATCH] Should always count to 10 before committing. Another comment git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7856 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kernel/core/thread.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/kernel/core/thread.c b/src/kernel/core/thread.c index 611c68b15f..3742c3462c 100644 --- a/src/kernel/core/thread.c +++ b/src/kernel/core/thread.c @@ -658,6 +658,7 @@ thread_exit2(void *_args) // ToDo: was: // restore_interrupts(args.int_state); // we probably don't want to let the interrupts disabled at this point?? + // Actually, args.int_state will always be 0, unless we fix thread_exit() TRACE(("thread_exit2, running on death stack 0x%lx\n", args.t->kernel_stack_base)); @@ -789,7 +790,7 @@ thread_exit(void) } // TODO: get_death_stack() disables interrupts - // and leave them disabled, so I wonder if it's good to disable + // and leaves them disabled, so I wonder if it's good to disable // them again a bunch of lines after this death_stack = get_death_stack(); { @@ -801,6 +802,7 @@ thread_exit(void) args.death_sem = cached_death_sem; // disable the interrupts. Must remain disabled until the kernel stack pointer can be officially switched + // TODO: interrupts are already disabled at this point args.int_state = disable_interrupts(); // set the new kernel stack officially to the death stack, wont be really switched until