File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed
kos/src/kernel/core/arch/i386/misc Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change 2828#ifdef __x86_64__
2929
3030#include <kernel/panic.h>
31+ #include <kernel/printk.h>
3132#include <kernel/types.h>
3233#include <kernel/x86/cpuid.h>
3334#include <kernel/x86/fsgsbase.h> /* x86_fsgsbase_patch() */
@@ -190,11 +191,13 @@ NOTHROW(KCALL x86_initialize_fsgsbase)(void) {
190191 /* Check if our CPU supports fsgsbase. If it does, the we don't have
191192 * to do anything, and we can NOP out calls to `x86_fsgsbase_patch()' */
192193 if (X86_HAVE_FSGSBASE ) {
194+ printk (FREESTR (KERN_INFO "[fsgsbase] Supported by CPU\n" ));
193195 * ((byte_t * )& x86_fsgsbase_patch + 0 ) = 0xc3 ; /* ret */
194196 return ;
195197 }
196198
197199 /* Patch all fsgsbase instructions within the kernel core. */
200+ printk (FREESTR (KERN_INFO "[fsgsbase] Not supported by CPU (patching kernel for MSR usage...)\n" ));
198201 for (iter = __x86_fixup_fsgsbase_start ;
199202 iter < __x86_fixup_fsgsbase_end ; ++ iter ) {
200203 void * pc = (byte_t * )KERNEL_CORE_BASE + * iter ;
You can’t perform that action at this time.
0 commit comments