mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 12:28:12 +00:00
Kernel: Hide the implementation detail that MSRs use two registers
When retrieving and setting x86 MSRs two registers are required. The existing setter and getter for the MSR class made this implementation detail visible to the caller. This changes the setter and getter to use u64 instead.
This commit is contained in:
parent
a09e6171a6
commit
04a912f68f
3 changed files with 10 additions and 9 deletions
|
@ -1128,7 +1128,7 @@ UNMAP_AFTER_INIT void Processor::gdt_init()
|
|||
|
||||
#if ARCH(X86_64)
|
||||
MSR gs_base(MSR_GS_BASE);
|
||||
gs_base.set((size_t)this & 0xffffffff, (size_t)this >> 32);
|
||||
gs_base.set((u64)this);
|
||||
#else
|
||||
asm volatile(
|
||||
"mov %%ax, %%ds\n"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue