diff options
Diffstat (limited to 'kernel/drivers/cpu.c')
-rw-r--r-- | kernel/drivers/cpu.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/kernel/drivers/cpu.c b/kernel/drivers/cpu.c index f751d33..5d53bef 100644 --- a/kernel/drivers/cpu.c +++ b/kernel/drivers/cpu.c @@ -168,6 +168,13 @@ CLEAR void cpu_enable_features(void) } else { print("No SMAP support :(\n"); } + + // Enable UMIP // TODO: QEMU support?! + if (cpu_extended_features.ecx & CPUID_EXT_FEAT_ECX_UMIP) { + cr4_set(cr4_get() | 0x800); + } else { + print("No UMIP support :(\n"); + } } void clac(void) |