Remove KernelThreadExt

This commit is contained in:
Ruihan Li
2024-11-10 16:48:35 +08:00
committed by Tate, Hongliang Tian
parent 7850f7e60a
commit a4a8807a20
11 changed files with 111 additions and 138 deletions

View File

@ -9,10 +9,7 @@ use ostd::timer::Jiffies;
use super::{ext::IfaceEx, Iface, IFACES};
use crate::{
sched::priority::{Priority, PriorityRange},
thread::{
kernel_thread::{KernelThreadExt, ThreadOptions},
Thread,
},
thread::kernel_thread::ThreadOptions,
WaitTimeout,
};
@ -70,6 +67,7 @@ fn spawn_background_poll_thread(iface: Arc<Iface>) {
};
// FIXME: remove the use of real-time priority.
let options = ThreadOptions::new(task_fn).priority(Priority::new(PriorityRange::new(0)));
Thread::spawn_kernel_thread(options);
ThreadOptions::new(task_fn)
.priority(Priority::new(PriorityRange::new(0)))
.spawn();
}