pub fn init_syscall()Expand description
Initialize SYSCALL/SYSRET support.
Configures the following MSRs:
- EFER: Enable SYSCALL/SYSRET extensions
- LSTAR: Set syscall entry point to
syscall_entry - STAR: Set segment selectors for SYSCALL (kernel) and SYSRET (user)
- SFMASK: Mask IF flag so syscall entry runs with interrupts disabled
- KernelGsBase: Point to
PerCpuDatafor swapgs in syscall_entry
Must be called after gdt::init() and before any user-mode transitions.