+/*
+ * TraceFS reported only IRP_MJ_FLUSH_BUFFERS
+ * and IRP_MJ_SHUTDOWN.
+ * Apparently it is not enough, FSCTL_DISMOUNT_VOLUME is needed,
+ * otherwise NT-5.1 autochkdsks the disk and W2000 may give BSOD during boot.
+ */
+enum step {
+ /* First item value assumed to be 0. */
+ STEP_IRP_MJ_FLUSH_BUFFERS_PRE,
+#if 0
+ /* DISABLED: STATUS_ACCESS_DENIED; FIXME: Why?
+ * The official way of device modification is: LOCK,DISMOUNT
+ * but LOCK fails for Captive if any file was written (and closed).
+ */
+ STEP_FSCTL_LOCK_VOLUME,
+#endif
+ STEP_FSCTL_DISMOUNT_VOLUME,
+ STEP_IRP_MJ_FLUSH_BUFFERS_POST,
+ STEP_MAX=3,
+ } stepi;