1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 04:57:44 +00:00

Kernel: Rename {ss,esp}_if_crossRing to userspace_{ss,esp}

These were always so awkwardly named.
This commit is contained in:
Andreas Kling 2020-01-09 18:02:01 +01:00
parent f007a63b10
commit 17ef5bc0ac
6 changed files with 15 additions and 15 deletions

View file

@ -135,8 +135,8 @@ static void dump(const RegisterDump& regs)
ss = regs.ss;
esp = regs.esp;
} else {
ss = regs.ss_if_crossRing;
esp = regs.esp_if_crossRing;
ss = regs.userspace_ss;
esp = regs.userspace_esp;
}
kprintf("exception code: %04x (isr: %04x)\n", regs.exception_code, regs.isr_number);
@ -247,8 +247,8 @@ void page_fault_handler(RegisterDump regs)
#endif
bool faulted_in_userspace = (regs.cs & 3) == 3;
if (faulted_in_userspace && !MM.validate_user_stack(current->process(), VirtualAddress(regs.esp_if_crossRing))) {
dbgprintf("Invalid stack pointer: %p\n", regs.esp_if_crossRing);
if (faulted_in_userspace && !MM.validate_user_stack(current->process(), VirtualAddress(regs.userspace_esp))) {
dbgprintf("Invalid stack pointer: %p\n", regs.userspace_esp);
handle_crash(regs, "Bad stack on page fault", SIGSTKFLT);
ASSERT_NOT_REACHED();
}