Commit 329f43c9 by malcolm

Bit of cleanup, messages. Kernel stack still not properly formed.

parent 7de0adfc
Showing with 5 additions and 5 deletions
......@@ -55,6 +55,7 @@ int yield()
procs[curproc]->state = RUNNABLE;
serial_writestring("about to schedule\n");
schedule();
serial_writestring("echeduled\n");
//unlock mutex
return 1;
}
......
......@@ -2,7 +2,10 @@ global context_switch
context_switch:
mov eax, [esp+4]
mov edx, [esp+8]
; set return of new context to current context's
; address, so that we return to the proper location
; in kernel memory
mov ecx, [esp]
mov [edx+20], ecx
......@@ -13,10 +16,6 @@ context_switch:
mov ecx, cr3
push ecx
; CR3 PROBLEM - STACK CHANGES, CANT ACCESS NEW MEM?
; WHY IS PROCS[CURPROC]->CTXT IN PROCESS MEM, NOT
; IN KERNEL MEM? INTERROGATE FREMMA
mov [eax], esp
mov esp, edx
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment