]> Zhao Yanbai Git Server - minix.git/commitdiff
avfs: fix for root file system not being unmounted
authorDavid van Moolenbroek <david@minix3.org>
Wed, 4 Jan 2012 13:10:10 +0000 (14:10 +0100)
committerDavid van Moolenbroek <david@minix3.org>
Wed, 4 Jan 2012 13:10:10 +0000 (14:10 +0100)
Also no longer have avfs crash whenever a file system server crashes.

servers/avfs/misc.c
servers/avfs/proto.h
servers/avfs/vmnt.c

index 08a1afa48f7c578f2ab980b963dc4503108bfd81..31a8af2b8493307a8a912fec2996ea2e472a1a20 100644 (file)
@@ -350,9 +350,6 @@ PUBLIC void pm_reboot()
        rfp = &fproc[i];
        if (rfp->fp_endpoint == NONE) continue;
 
-       /* Let FSes exit themselves */
-       if (find_vmnt(rfp->fp_endpoint) != NULL) continue;
-
        /* Don't just free the proc right away, but let it finish what it was
         * doing first */
        lock_proc(rfp, 0);
@@ -460,7 +457,6 @@ PRIVATE void free_proc(struct fproc *exiter, int flags)
    */
   unsuspend_by_endpt(exiter->fp_endpoint);
   dmap_unmap_by_endpt(exiter->fp_endpoint);
-  vmnt_unmap_by_endpt(exiter->fp_endpoint);
   worker_stop_by_endpt(exiter->fp_endpoint);
 
   /* Release root and working directories. */
index 327935bd85823b0143550985a678fb2c6cc05ac2..54d4a9d0c8ec4681daae0760b6d96fcb5d65db73 100644 (file)
@@ -334,7 +334,6 @@ _PROTOTYPE( struct vmnt *get_locked_vmnt, (struct fproc *rfp)               );
 _PROTOTYPE( void init_vmnts, (void)                                    );
 _PROTOTYPE( int lock_vmnt, (struct vmnt *vp, tll_access_t locktype)    );
 _PROTOTYPE( void unlock_vmnt, (struct vmnt *vp)                                );
-_PROTOTYPE( void vmnt_unmap_by_endpt, (endpoint_t proc_e)              );
 
 /* vnode.c */
 _PROTOTYPE( void check_vnode_locks, (void)                             );
index 3202473f30a319d2873049613356ca3d6788f94a..66c40567831699f489778644fb1885fc4429c86b 100644 (file)
@@ -180,15 +180,3 @@ PUBLIC void unlock_vmnt(struct vmnt *vmp)
 #endif
 
 }
-
-/*===========================================================================*
- *                             vmnt_unmap_by_endpoint                       *
- *===========================================================================*/
-PUBLIC void vmnt_unmap_by_endpt(endpoint_t proc_e)
-{
-  struct vmnt *vmp;
-
-  if ((vmp = find_vmnt(proc_e)) != NULL)
-       clear_vmnt(vmp);
-
-}