From: Jorrit Herder Date: Fri, 24 Jun 2005 16:19:41 +0000 (+0000) Subject: Removed sys_exit() kernel call. X-Git-Tag: v3.1.0~708 X-Git-Url: http://zhaoyanbai.com/repos/dnssec-verify.html?a=commitdiff_plain;h=e3bb0e40eeb56af7e332ed4e32a2c8a7575162ca;p=minix.git Removed sys_exit() kernel call. --- diff --git a/lib/syslib/Makefile b/lib/syslib/Makefile index 4fb9a3753..754cef428 100755 --- a/lib/syslib/Makefile +++ b/lib/syslib/Makefile @@ -27,7 +27,6 @@ OBJECTS = \ $(LIBSYS)(sys_eniop.o) \ $(LIBSYS)(sys_segctl.o) \ $(LIBSYS)(sys_umap.o) \ - $(LIBSYS)(sys_exit.o) \ $(LIBSYS)(sys_physcp.o) \ $(LIBSYS)(sys_vircp.o) \ $(LIBSYS)(sys_in.o) \ @@ -95,9 +94,6 @@ $(LIBSYS)(sys_segctl.o): sys_segctl.c $(LIBSYS)(sys_umap.o): sys_umap.c $(CC1) sys_umap.c -$(LIBSYS)(sys_exit.o): sys_exit.c - $(CC1) sys_exit.c - $(LIBSYS)(sys_getsig.o): sys_getsig.c $(CC1) sys_getsig.c diff --git a/lib/syslib/sys_exit.c b/lib/syslib/sys_exit.c deleted file mode 100644 index 770366c88..000000000 --- a/lib/syslib/sys_exit.c +++ /dev/null @@ -1,15 +0,0 @@ -#include "syslib.h" - -/*===========================================================================* - * sys_exit * - *===========================================================================*/ -PUBLIC int sys_exit(int status) -{ -/* A server wants to exit. The exit status is passed on, possibly a panic. - */ - message m; - m.EXIT_STATUS = status; - return(_taskcall(SYSTASK, SYS_EXIT, &m)); - /* NOT REACHED */ -} - diff --git a/lib/syslib/sys_xit.c b/lib/syslib/sys_xit.c index 0702686af..78c15ebd0 100755 --- a/lib/syslib/sys_xit.c +++ b/lib/syslib/sys_xit.c @@ -3,15 +3,15 @@ /*===========================================================================* * sys_xit * *===========================================================================*/ -PUBLIC int sys_xit(parent, proc) -int parent; /* parent of exiting process */ +PUBLIC int sys_xit(proc) int proc; /* which process has exited */ { -/* A process has exited. Tell the kernel. */ - +/* A process has exited. PM tells the kernel. In addition this call can be + * used by system processes to directly exit without passing through the + * PM. This should be used with care to prevent inconsistent PM tables. + */ message m; - m.PR_PPROC_NR = parent; m.PR_PROC_NR = proc; return(_taskcall(SYSTASK, SYS_XIT, &m)); } diff --git a/lib/utils/panic.c b/lib/utils/panic.c index e3fd88e39..bf5e13853 100644 --- a/lib/utils/panic.c +++ b/lib/utils/panic.c @@ -22,9 +22,9 @@ int num; /* number to go with format string */ } } - m.m_type = SYS_EXIT; - m.EXIT_STATUS = 1; - _taskcall(SYSTASK, SYS_EXIT, &m); + m.m_type = SYS_XIT; + m.PR_PROC_NR = SELF; + _taskcall(SYSTASK, SYS_XIT, &m); /* never reached */ }