1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-18 10:35:55 +00:00

Protect p_flag with the proc lock. The sched_lock is not needed to turn

off P_STOPPED_SIG in p_flag.
This commit is contained in:
John Baldwin 2003-04-17 22:14:30 +00:00
parent c2247848dc
commit ab0eee5563
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=113619

View File

@ -263,8 +263,8 @@ procfs_control(struct thread *td, struct proc *p, int op)
* or some other trap.
*/
case PROCFS_CTL_RUN:
PROC_UNLOCK(p);
p->p_flag &= ~P_STOPPED_SIG; /* this uses SIGSTOP */
PROC_UNLOCK(p);
break;
/*
@ -349,9 +349,9 @@ procfs_doprocctl(PFS_FILL_ARGS)
/* XXXKSE: */
FIX_SSTEP(FIRST_THREAD_IN_PROC(p));
#endif
mtx_lock_spin(&sched_lock);
/* XXXKSE: */
p->p_flag &= ~P_STOPPED_SIG;
mtx_lock_spin(&sched_lock);
thread_unsuspend(p);
mtx_unlock_spin(&sched_lock);
} else