linux-busy-cache-partition-while-afs-running-and-dont-allow-afsd-shutdown-while-afs...
[openafs.git] / src / afs / LINUX / osi_vfsops.c
index 255f9bc..b9880cb 100644 (file)
@@ -31,6 +31,7 @@ RCSID("$Header$");
 
 struct vcache *afs_globalVp = 0;
 struct vfs *afs_globalVFS = 0;
+struct nameidata afs_cacheNd;
 int afs_was_mounted = 0; /* Used to force reload if mount/unmount/mount */
 
 extern struct super_operations afs_sops;
@@ -273,6 +274,7 @@ void afs_put_super(struct super_block *sbp)
     afs_globalVFS = 0;
     afs_globalVp = 0;
     afs_shutdown();
+    path_release(&afs_cacheNd);
 
     osi_linux_verify_alloced_memory();
  done:
@@ -340,9 +342,7 @@ int afs_statfs(struct super_block *sbp, struct statfs *statp, int size)
 void 
 afs_umount_begin(struct super_block *sbp)
 {
-    afs_put_super(sbp);      
     afs_shuttingdown=1;
-    afs_was_mounted=0;
 }
 
 #if defined(AFS_LINUX24_ENV)
@@ -352,7 +352,7 @@ struct super_operations afs_sops = {
     delete_inode:      afs_delete_inode,
     put_super:         afs_put_super,
     statfs:            afs_statfs,
-    umount_begin:      NULL /* afs_umount_begin */
+    umount_begin:      afs_umount_begin
 };
 #else
 struct super_operations afs_sops = {
@@ -366,7 +366,7 @@ struct super_operations afs_sops = {
     afs_statfs,
     NULL,              /* afs_remount_fs - see doc above */
     NULL,              /* afs_clear_inode */
-    NULL                /* afs_umount_begin */
+    afs_umount_begin
 };
 #endif