write kernel sp to tss in dispatcher
This commit is contained in:
@@ -41,10 +41,11 @@ Thread::Thread (bool kernel, void * start): queue_link(nullptr), isKernel(kerne
|
||||
prepareContext(StackPointer.isr, context, kickoff, reinterpret_cast<uintptr_t>(this), 0, 0);
|
||||
}
|
||||
|
||||
Thread::Thread() : queue_link(nullptr), id(idCounter++), kill_flag(false) {
|
||||
void *tos = reinterpret_cast<void *>(reserved_stack_space_isr + STACK_SIZE);
|
||||
prepareContext(tos, context, kickoff, reinterpret_cast<uintptr_t>(this), 0, 0);
|
||||
}
|
||||
Thread::Thread() : Thread(false, 0) {}
|
||||
//Thread::Thread() : queue_link(nullptr), id(idCounter++), kill_flag(false) {
|
||||
// void *tos = reinterpret_cast<void *>(reserved_stack_space_isr + STACK_SIZE);
|
||||
// prepareContext(tos, context, kickoff, reinterpret_cast<uintptr_t>(this), 0, 0);
|
||||
//}
|
||||
|
||||
void Thread::resume(Thread *next) {
|
||||
assert(next != nullptr && "Pointer to next Thread must not be nullptr!");
|
||||
|
||||
Reference in New Issue
Block a user