mirror of
https://github.com/RGBCube/serenity
synced 2025-05-15 10:14:58 +00:00
Kernel: Factor our PreviousMode into RegisterState::previous_mode
Various places in the kernel were manually checking the cs register for x86_64, however to share this with aarch64 a function in RegisterState is added, and the call-sites are updated. While we're here the PreviousMode enum is renamed to ExecutionMode.
This commit is contained in:
parent
247109cee6
commit
fb10774862
11 changed files with 53 additions and 29 deletions
|
@ -631,7 +631,7 @@ void Thread::update_time_scheduled(u64 current_scheduler_time, bool is_kernel, b
|
|||
|
||||
bool Thread::tick()
|
||||
{
|
||||
if (previous_mode() == PreviousMode::KernelMode) {
|
||||
if (previous_mode() == ExecutionMode::Kernel) {
|
||||
++m_process->m_ticks_in_kernel;
|
||||
++m_ticks_in_kernel;
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue