1 use crate::arch::x86_64::asm::current::current_pcb;
2 
3 /// @brief 增加进程的锁持有计数
4 #[inline]
preempt_disable()5 pub fn preempt_disable() {
6     current_pcb().preempt_count += 1;
7 }
8 
9 /// @brief 减少进程的锁持有计数
10 #[inline]
preempt_enable()11 pub fn preempt_enable() {
12     current_pcb().preempt_count -= 1;
13 }
14