summaryrefslogtreecommitdiffstats
path: root/sys/dev
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/hwpmc/hwpmc_mod.c9
-rw-r--r--sys/dev/random/randomdev_soft.c6
2 files changed, 3 insertions, 12 deletions
diff --git a/sys/dev/hwpmc/hwpmc_mod.c b/sys/dev/hwpmc/hwpmc_mod.c
index 1ea0e68..579b6fd 100644
--- a/sys/dev/hwpmc/hwpmc_mod.c
+++ b/sys/dev/hwpmc/hwpmc_mod.c
@@ -646,15 +646,8 @@ pmc_select_cpu(int cpu)
static void
pmc_force_context_switch(void)
{
- u_char curpri;
-
- mtx_lock_spin(&sched_lock);
- curpri = curthread->td_priority;
- mtx_unlock_spin(&sched_lock);
-
- (void) tsleep((void *) pmc_force_context_switch, curpri,
- "pmcctx", 1);
+ (void) tsleep((void *) pmc_force_context_switch, 0, "pmcctx", 1);
}
/*
diff --git a/sys/dev/random/randomdev_soft.c b/sys/dev/random/randomdev_soft.c
index cd5e2d9..159d6ce 100644
--- a/sys/dev/random/randomdev_soft.c
+++ b/sys/dev/random/randomdev_soft.c
@@ -211,8 +211,7 @@ random_yarrow_deinit(void)
* Command the hash/reseed thread to end and wait for it to finish
*/
random_kthread_control = -1;
- tsleep((void *)&random_kthread_control, curthread->td_priority, "term",
- 0);
+ tsleep((void *)&random_kthread_control, 0, "term", 0);
/* Destroy the harvest fifos */
while (!STAILQ_EMPTY(&emptyfifo.head)) {
@@ -285,8 +284,7 @@ random_kthread(void *arg __unused)
/* Found nothing, so don't belabour the issue */
if (!active)
- tsleep(&harvestfifo, curthread->td_priority, "-",
- hz / 10);
+ tsleep(&harvestfifo, 0, "-", hz / 10);
}
OpenPOWER on IntegriCloud