x86/bits32/
mod.rs

1//! Data structures and functions used by 32-bit mode.
2
3pub mod eflags;
4pub mod paging;
5pub mod segmentation;
6pub mod task;
7
8#[cfg(target_arch = "x86")]
9use core::arch::asm;
10
11#[cfg(target_arch = "x86")]
12#[inline(always)]
13pub unsafe fn stack_jmp(stack: *mut (), ip: *const ()) -> ! {
14    asm!("movl {0}, %esp; jmp {1}", in(reg) stack, in(reg) ip, options(att_syntax));
15    loop {}
16}