RTS_SYS_LOCK and do_runctl()

- No need for RTS_SYS_LOCK as there are no tasks anymore.
This commit is contained in:
Tomas Hruby 2010-04-06 11:18:04 +00:00
parent cdd6743e88
commit b0d37b81c4
2 changed files with 4 additions and 9 deletions

View File

@ -128,7 +128,6 @@ struct proc {
#define RTS_PAGEFAULT 0x400 /* process has unhandled pagefault */
#define RTS_VMREQUEST 0x800 /* originator of vm memory request */
#define RTS_VMREQTARGET 0x1000 /* target of vm memory request */
#define RTS_SYS_LOCK 0x2000 /* temporary process lock flag for systask */
#define RTS_PREEMPTED 0x4000 /* this process was preempted by a higher
priority process and we should pick a new one
to run. Processes with this flag should be

View File

@ -22,7 +22,7 @@ PUBLIC int do_runctl(struct proc * caller, message * m_ptr)
* of RTS_PROC_STOP, and send a SIGSNDELAY signal later when the process is done
* sending (ending the delay). Used by PM for safe signal delivery.
*/
int proc_nr, action, flags, delayed;
int proc_nr, action, flags;
register struct proc *rp;
/* Extract the message parameters and do sanity checking. */
@ -39,17 +39,13 @@ PUBLIC int do_runctl(struct proc * caller, message * m_ptr)
* Note that asynchronous messages are not covered: a process using SENDA
* should not also install signal handlers *and* expect POSIX compliance.
*/
if (action == RC_STOP && (flags & RC_DELAY)) {
RTS_SET(rp, RTS_SYS_LOCK);
if (action == RC_STOP && (flags & RC_DELAY)) {
if (RTS_ISSET(rp, RTS_SENDING) || (rp->p_misc_flags & MF_SC_DEFER))
rp->p_misc_flags |= MF_SIG_DELAY;
delayed = (rp->p_misc_flags & MF_SIG_DELAY);
RTS_UNSET(rp, RTS_SYS_LOCK);
if (delayed) return(EBUSY);
if (rp->p_misc_flags & MF_SIG_DELAY)
return (EBUSY);
}
/* Either set or clear the stop flag. */