patch-2.4.26 linux-2.4.26/fs/xfs/xfs_fsops.c
Next file: linux-2.4.26/fs/xfs/xfs_fsops.h
Previous file: linux-2.4.26/fs/xfs/xfs_fs.h
Back to the patch index
Back to the overall index
- Lines: 29
- Date:
2004-04-14 06:05:40.000000000 -0700
- Orig file:
linux-2.4.25/fs/xfs/xfs_fsops.c
- Orig date:
2004-02-18 05:36:32.000000000 -0800
diff -urN linux-2.4.25/fs/xfs/xfs_fsops.c linux-2.4.26/fs/xfs/xfs_fsops.c
@@ -626,3 +626,28 @@
xfs_finish_freeze(mp);
return 0;
}
+
+int
+xfs_fs_goingdown(
+ xfs_mount_t *mp,
+ __uint32_t inflags)
+{
+ switch (inflags)
+ {
+ case XFS_FSOP_GOING_FLAGS_DEFAULT:
+ xfs_fs_freeze(mp);
+ xfs_force_shutdown(mp, XFS_FORCE_UMOUNT);
+ xfs_fs_thaw(mp);
+ break;
+ case XFS_FSOP_GOING_FLAGS_LOGFLUSH:
+ xfs_force_shutdown(mp, XFS_FORCE_UMOUNT);
+ break;
+ case XFS_FSOP_GOING_FLAGS_NOLOGFLUSH:
+ xfs_force_shutdown(mp, XFS_FORCE_UMOUNT|XFS_LOG_IO_ERROR);
+ break;
+ default:
+ return XFS_ERROR(EINVAL);
+ }
+
+ return 0;
+}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)