Get super basic ring3 task switching working

* It looks like UEFI enables SSE, so we need to tell clang -mno-sse for
  now to not use XMM* until we're ready to save them.
* SYSCALL is working from ring3 tasks, calling console printf!
This commit is contained in:
Justin C. Miller
2018-05-21 01:00:34 -07:00
parent e6f819ed90
commit 2597e2002b
4 changed files with 19 additions and 57 deletions

View File

@@ -113,7 +113,6 @@ print_stacktrace(int skip = 0)
addr_t
isr_handler(addr_t return_rsp, cpu_state regs)
{
log::debug(logs::task, "Starting RSP %016lx", return_rsp);
console *cons = console::get();
switch (static_cast<isr>(regs.interrupt & 0xff)) {
@@ -284,10 +283,8 @@ isr_handler(addr_t return_rsp, cpu_state regs)
print_stacktrace(2);
while(1) asm("hlt");
}
*reinterpret_cast<uint32_t *>(0xffffff80fee000b0) = 0;
log::debug(logs::task, "Returning RSP %016lx", return_rsp);
return return_rsp;
}