From 77583447a9e7fa38ca9ded43c5e1a8e8583bf05f Mon Sep 17 00:00:00 2001 From: jhb Date: Wed, 24 Jan 2001 10:23:54 +0000 Subject: - Proc locking. - P_OWEUPC -> PS_OWEUPC. --- sys/alpha/include/cpu.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'sys/alpha/include') diff --git a/sys/alpha/include/cpu.h b/sys/alpha/include/cpu.h index 0edb2fc..cd49802 100644 --- a/sys/alpha/include/cpu.h +++ b/sys/alpha/include/cpu.h @@ -80,8 +80,12 @@ struct clockframe { * buffer pages are invalid. On the hp300, request an ast to send us * through trap, marking the proc as needing a profiling tick. */ -#define need_proftick(p) \ - do { (p)->p_flag |= P_OWEUPC; aston(); } while (0) +#define need_proftick(p) do { \ + mtx_enter(&sched_lock, MTX_SPIN); \ + (p)->p_sflag |= PS_OWEUPC; \ + mtx_exit(&sched_lock, MTX_SPIN); \ + aston(); \ +} while (0) /* * Notify the current process (p) that it has a signal pending, -- cgit v1.1