aboutsummaryrefslogtreecommitdiff
path: root/src/task.rs
blob: a7637f22142c6b2d0f8b4f841589dda3e2a0c08d (plain) (blame)
1
2
3
4
5
6
7
8
9
//! Helpers to program the task state segment.
//! See Intel 3a, Chapter 7

pub use crate::segmentation;

/// Load the task state register.
pub unsafe fn load_tr(sel: segmentation::SegmentSelector) {
    asm!("ltr $0" :: "r" (sel.bits()));
}