- Proc locking around the vinumdaemon dinking with its flags.

- P_INMEM -> PS_INMEM.
This commit is contained in:
John Baldwin 2001-01-24 10:28:19 +00:00
parent 2ae8bab0b6
commit e7d904a13a
1 changed files with 6 additions and 1 deletions

View File

@ -69,7 +69,12 @@ vinum_daemon(void)
int s;
struct daemonq *request;
curproc->p_flag |= P_INMEM | P_SYSTEM; /* we're a system process */
PROC_LOCK(curproc);
curproc->p_flag |= P_SYSTEM; /* we're a system process */
PROC_UNLOCK(curproc);
mtx_enter(&sched_lock, MTX_SPIN);
curproc->p_sflag |= PS_INMEM;
mtx_exit(&sched_lock, MTX_SPIN);
daemon_save_config(); /* start by saving the configuration */
daemonpid = curproc->p_pid; /* mark our territory */
while (1) {