diff options
| author | John Baldwin <jhb@FreeBSD.org> | 2008-07-28 20:39:21 +0000 |
|---|---|---|
| committer | John Baldwin <jhb@FreeBSD.org> | 2008-07-28 20:39:21 +0000 |
| commit | c3ea3378012c3b18d0e4172751bad9149ce6b43b (patch) | |
| tree | d585c314fd166b901b98941569f69b36db06290a | |
| parent | 6c5bbf5ce1d6814f1281c4687957549b713c6f43 (diff) | |
Notes
| -rw-r--r-- | sys/kern/sched_4bsd.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/kern/sched_4bsd.c b/sys/kern/sched_4bsd.c index 333db66fd479..88a54943f280 100644 --- a/sys/kern/sched_4bsd.c +++ b/sys/kern/sched_4bsd.c @@ -1167,7 +1167,10 @@ sched_pickcpu(struct thread *td) mtx_assert(&sched_lock, MA_OWNED); - best = NOCPU; + if (THREAD_CAN_SCHED(td, td->td_lastcpu)) + best = td->td_lastcpu; + else + best = NOCPU; for (cpu = 0; cpu <= mp_maxid; cpu++) { if (CPU_ABSENT(cpu)) continue; |
