From 7b611b0cb22347b6dcb39cb97b7826908f188d10 Mon Sep 17 00:00:00 2001 From: jhb Date: Thu, 30 Dec 2004 20:29:58 +0000 Subject: Stop explicitly touching td_base_pri outside of the scheduler and simply set a thread's priority via sched_prio() when that is the desired action. The schedulers will start managing td_base_pri internally shortly. --- sys/dev/md/md.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'sys/dev') diff --git a/sys/dev/md/md.c b/sys/dev/md/md.c index 8c35d85..550fd5f 100644 --- a/sys/dev/md/md.c +++ b/sys/dev/md/md.c @@ -71,6 +71,7 @@ #include #include #include +#include #include #include #include @@ -618,7 +619,9 @@ md_kthread(void *arg) int error, hasgiant; sc = arg; - curthread->td_base_pri = PRIBIO; + mtx_lock_spin(&sched_lock); + sched_prio(curthread, PRIBIO); + mtx_unlock_spin(&sched_lock); switch (sc->type) { case MD_VNODE: -- cgit v1.1