Print this page
8956 Implement KPTI
Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>
Reviewed by: Robert Mustacchi <rm@joyent.com>

*** 22,31 **** --- 22,33 ---- * Copyright (c) 1992, 2010, Oracle and/or its affiliates. All rights reserved. */ /* * Copyright (c) 2010, Intel Corporation. * All rights reserved. + * + * Copyright 2018 Joyent, Inc. */ #include <sys/asm_linkage.h> #include <sys/asm_misc.h> #include <sys/regset.h>
*** 324,334 **** /* * Complete the rest of the setup and call mp_startup(). */ movq %gs:CPU_THREAD, %rax /* get thread ptr */ ! call *T_PC(%rax) /* call mp_startup */ /* not reached */ int $20 /* whoops, returned somehow! */ SET_SIZE(real_mode_start_cpu) --- 326,336 ---- /* * Complete the rest of the setup and call mp_startup(). */ movq %gs:CPU_THREAD, %rax /* get thread ptr */ ! call *T_PC(%rax) /* call mp_startup_boot */ /* not reached */ int $20 /* whoops, returned somehow! */ SET_SIZE(real_mode_start_cpu)
*** 500,510 **** or $(CR0_MP|CR0_NE), %edx mov %edx, %cr0 /* set machine status word */ /* * Before going any farther, enable usage of page table NX bit if ! * that's how our page tables are set up. */ bt $X86FSET_NX, x86_featureset jnc 1f movl %cr4, %ecx andl $CR4_PAE, %ecx --- 502,512 ---- or $(CR0_MP|CR0_NE), %edx mov %edx, %cr0 /* set machine status word */ /* * Before going any farther, enable usage of page table NX bit if ! * that's how our page tables are set up. (PCIDE is enabled later on). */ bt $X86FSET_NX, x86_featureset jnc 1f movl %cr4, %ecx andl $CR4_PAE, %ecx