Author: pschweitzer
Date: Sat Jun 28 12:48:32 2008
New Revision: 34164
URL:
http://svn.reactos.org/svn/reactos?rev=34164&view=rev
Log:
- Added support of PSEH
- Linked Volume together using linked list
- Removed useless and unclear stuff
Modified:
branches/pierre-fsd/drivers/filesystems/ntfs/fsctl.c
branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.c
branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.h
branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.rbuild
Modified: branches/pierre-fsd/drivers/filesystems/ntfs/fsctl.c
URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
==============================================================================
--- branches/pierre-fsd/drivers/filesystems/ntfs/fsctl.c [iso-8859-1] (original)
+++ branches/pierre-fsd/drivers/filesystems/ntfs/fsctl.c [iso-8859-1] Sat Jun 28 12:48:32
2008
@@ -392,7 +392,7 @@
TAG_CCB);
if (Ccb == NULL)
{
- Status = STATUS_INSUFFICIENT_RESOURCES;
+ Status = STATUS_INSUFFICIENT_RESOURCES;
goto ByeBye;
}
RtlZeroMemory(Ccb, sizeof(NTFS_CCB));
@@ -427,6 +427,10 @@
ExInitializeResourceLite(&Vcb->DirResource);
KeInitializeSpinLock(&Vcb->FcbListLock);
+
+ ExAcquireResourceExclusiveLite(&NtfsGlobalData->VolumeListLock, TRUE);
+ InsertHeadList(&NtfsGlobalData->VolumeListHead, &Vcb->VolumeListEntry);
+ ExReleaseResourceLite(&NtfsGlobalData->VolumeListLock);
/* Get serial number */
NewDeviceObject->Vpb->SerialNumber = Vcb->NtfsInfo.SerialNumber;
Modified: branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.c
URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
==============================================================================
--- branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.c [iso-8859-1] (original)
+++ branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.c [iso-8859-1] Sat Jun 28 12:48:32
2008
@@ -64,8 +64,6 @@
RtlZeroMemory(NtfsGlobalData, sizeof(NTFS_GLOBAL_DATA));
NtfsGlobalData->Identifier.Type = NTFS_TYPE_GLOBAL_DATA;
NtfsGlobalData->Identifier.Size = sizeof(NTFS_GLOBAL_DATA);
-
- ExInitializeResourceLite(&NtfsGlobalData->Resource);
/* Keep trace of Driver Object */
NtfsGlobalData->DriverObject = DriverObject;
@@ -97,6 +95,9 @@
NtfsGlobalData->DeviceObject->Flags |= DO_DIRECT_IO;
+ ExInitializeResourceLite(&NtfsGlobalData->VolumeListLock);
+ InitializeListHead(&NtfsGlobalData->VolumeListHead);
+
/* Register file system */
IoRegisterFileSystem(NtfsGlobalData->DeviceObject);
ObReferenceObject(NtfsGlobalData->DeviceObject);
@@ -106,7 +107,6 @@
{
if (NtfsGlobalData)
{
- ExDeleteResourceLite(&NtfsGlobalData->Resource);
ExFreePoolWithTag(NtfsGlobalData, TAG('N', 'D', 'R',
'G'));
}
}
Modified: branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.h
URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
==============================================================================
--- branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.h [iso-8859-1] (original)
+++ branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.h [iso-8859-1] Sat Jun 28 12:48:32
2008
@@ -5,6 +5,7 @@
#include <ntddk.h>
#include <ntdddisk.h>
#include <ccros.h>
+#include <pseh/pseh.h>
#define CACHEPAGESIZE(pDeviceExt) \
((pDeviceExt)->NtfsInfo.UCHARsPerCluster > PAGE_SIZE ? \
@@ -115,7 +116,9 @@
NTFS_INFO NtfsInfo;
-
+ PNTFS_BCB MftBuffer;
+
+ LIST_ENTRY VolumeListEntry;
} DEVICE_EXTENSION, *PDEVICE_EXTENSION, NTFS_VCB, *PNTFS_VCB;
@@ -173,7 +176,8 @@
typedef struct
{
NTFSIDENTIFIER Identifier;
- ERESOURCE Resource;
+ ERESOURCE VolumeListLock;
+ LIST_ENTRY VolumeListHead;
PDRIVER_OBJECT DriverObject;
PDEVICE_OBJECT DeviceObject;
CACHE_MANAGER_CALLBACKS CacheMgrCallbacks;
Modified: branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.rbuild
URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
==============================================================================
--- branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.rbuild [iso-8859-1] (original)
+++ branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.rbuild [iso-8859-1] Sat Jun 28
12:48:32 2008
@@ -5,6 +5,7 @@
<include base="ntfs">.</include>
<library>ntoskrnl</library>
<library>hal</library>
+ <library>pseh</library>
<file>attrib.c</file>
<file>blockdev.c</file>
<file>close.c</file>