bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 3/7] init: Mark auth, proc and fs servers as essential


From: Justus Winter
Subject: [PATCH 3/7] init: Mark auth, proc and fs servers as essential
Date: Wed, 24 Jul 2013 08:30:55 +0200

This is a fragment of Guillem Jovers patch presented here:

http://lists.gnu.org/archive/html/bug-hurd/2006-02/msg00081.html

It has been refreshed and the copyright year is adjusted.

* init/init.c (launch_core_servers): Mark auth, proc and fs servers as
essential.
---
 init/init.c |   11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/init/init.c b/init/init.c
index 930408e..e8c2220 100644
--- a/init/init.c
+++ b/init/init.c
@@ -1,7 +1,7 @@
 /* Start and maintain hurd core servers and system run state
 
    Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-     2005, 2008 Free Software Foundation, Inc.
+     2005, 2008, 2013 Free Software Foundation, Inc.
    This file is part of the GNU Hurd.
 
    The GNU Hurd is free software; you can redistribute it and/or modify
@@ -649,6 +649,7 @@ launch_core_servers (void)
   proc_child (procserver, authtask);
 
   proc_task2proc (procserver, authtask, &authproc);
+  proc_mark_essential (authproc);
   proc_mark_exec (authproc);
   startup_authinit_reply (authreply, authreplytype, 0, authproc,
                          MACH_MSG_TYPE_COPY_SEND);
@@ -671,6 +672,7 @@ launch_core_servers (void)
   err = proc_task2proc (procserver, proctask, &procproc);
   if (!err)
     {
+      proc_mark_essential (procproc);
       proc_mark_exec (procproc);
       mach_port_deallocate (mach_task_self (), procproc);
     }
@@ -680,6 +682,7 @@ launch_core_servers (void)
   /* Get the bootstrap filesystem's proc server port.
      We must do this before calling proc_setmsgport below.  */
   proc_task2proc (procserver, fstask, &fsproc);
+  proc_mark_essential (fsproc);
   proc_mark_exec (fsproc);
 
 #if 0
@@ -784,8 +787,10 @@ frob_kernel_process (void)
       return;
     }
 
-  /* Mark the kernel task as an essential task so that we never
-     want to task_terminate it.  */
+  /* Mark the kernel task as an essential task so that we or the proc server
+     never want to task_terminate it.  */
+  proc_mark_essential (proc);
+
   err = record_essential_task ("kernel", task);
   assert_perror (err);
 
-- 
1.7.10.4




reply via email to

[Prev in Thread] Current Thread [Next in Thread]