Author: fireball
Date: Sat Jan 12 18:20:22 2008
New Revision: 31736
URL:
http://svn.reactos.org/svn/reactos?rev=31736&view=rev
Log:
- Add missing critical region acquiring to the VfatShutdown routine.
- Remove that irql <= PASSIVE_LEVEL check, always entering the critical region. And for
vfat calls with an unusual high irql leave a DPRINT.
Modified:
trunk/reactos/drivers/filesystems/vfat/misc.c
trunk/reactos/drivers/filesystems/vfat/shutdown.c
Modified: trunk/reactos/drivers/filesystems/vfat/misc.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/vfat/m…
==============================================================================
--- trunk/reactos/drivers/filesystems/vfat/misc.c (original)
+++ trunk/reactos/drivers/filesystems/vfat/misc.c Sat Jan 12 18:20:22 2008
@@ -142,7 +142,6 @@
{
NTSTATUS Status;
PVFAT_IRP_CONTEXT IrpContext;
- KIRQL Irql;
DPRINT ("VfatBuildRequest (DeviceObject %p, Irp %p)\n", DeviceObject, Irp);
@@ -157,22 +156,14 @@
}
else
{
- Irql = KeGetCurrentIrql();
- if (Irql <= PASSIVE_LEVEL)
- {
- FsRtlEnterFileSystem();
- }
- else
+ if (KeGetCurrentIrql() > PASSIVE_LEVEL)
{
DPRINT1("Vfat is entered at irql = %d\n", Irql);
}
+
+ FsRtlEnterFileSystem();
Status = VfatDispatchRequest (IrpContext);
-
- if (Irql <= PASSIVE_LEVEL)
- {
- FsRtlExitFileSystem();
- }
-
+ FsRtlExitFileSystem();
}
return Status;
}
Modified: trunk/reactos/drivers/filesystems/vfat/shutdown.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/vfat/s…
==============================================================================
--- trunk/reactos/drivers/filesystems/vfat/shutdown.c (original)
+++ trunk/reactos/drivers/filesystems/vfat/shutdown.c Sat Jan 12 18:20:22 2008
@@ -50,6 +50,8 @@
ULONG eocMark;
DPRINT("VfatShutdown(DeviceObject %p, Irp %p)\n",DeviceObject, Irp);
+
+ FsRtlEnterFileSystem();
/* FIXME: block new mount requests */
@@ -108,6 +110,8 @@
Irp->IoStatus.Information = 0;
IoCompleteRequest(Irp, IO_NO_INCREMENT);
+ FsRtlExitFileSystem();
+
return(Status);
}