Author: pschweitzer
Date: Sat Jul 5 08:40:17 2008
New Revision: 34305
URL:
http://svn.reactos.org/svn/reactos?rev=34305&view=rev
Log:
Finally reverted most of r34036: it only created problems...
Modified:
branches/pierre-fsd/drivers/filesystems/ntfs/fcb.c
branches/pierre-fsd/drivers/filesystems/ntfs/fsctl.c
branches/pierre-fsd/drivers/filesystems/ntfs/ntfs.h
Modified: branches/pierre-fsd/drivers/filesystems/ntfs/fcb.c
URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
==============================================================================
--- branches/pierre-fsd/drivers/filesystems/ntfs/fcb.c [iso-8859-1] (original)
+++ branches/pierre-fsd/drivers/filesystems/ntfs/fcb.c [iso-8859-1] Sat Jul 5 08:40:17
2008
@@ -68,20 +68,15 @@
PNTFS_FCB
-NtfsCreateFCB(PCWSTR FileName, PNTFS_VCB Vcb)
+NtfsCreateFCB(PCWSTR FileName)
{
PNTFS_FCB Fcb;
-
- ASSERT(Vcb);
- ASSERT(Vcb->Identifier.Type == NTFS_TYPE_VCB);
Fcb = ExAllocatePoolWithTag(NonPagedPool, sizeof(NTFS_FCB), TAG_FCB);
RtlZeroMemory(Fcb, sizeof(NTFS_FCB));
Fcb->Identifier.Type = NTFS_TYPE_FCB;
Fcb->Identifier.Size = sizeof(NTFS_TYPE_FCB);
-
- Fcb->Vcb = Vcb;
if (FileName)
{
@@ -99,10 +94,6 @@
ExInitializeResourceLite(&Fcb->MainResource);
Fcb->RFCB.Resource = &(Fcb->MainResource);
-#if 0
- ExInterlockedInsertTailList(&(Vcb->FcbListHead), &(Fcb->FcbListEntry),
&(Vcb->FcbListLock));
-#endif
-
return(Fcb);
}
@@ -110,20 +101,16 @@
VOID
NtfsDestroyFCB(PNTFS_FCB Fcb)
{
-#if 0
KIRQL oldIrql;
-#endif
ASSERT(Fcb);
ASSERT(Fcb->Identifier.Type == NTFS_TYPE_FCB);
ExDeleteResourceLite(&Fcb->MainResource);
-#if 0
KeAcquireSpinLock(&(Fcb->Vcb->FcbListLock), &oldIrql);
RemoveEntryList(&(Fcb->FcbListEntry));
KeReleaseSpinLock(&(Fcb->Vcb->FcbListLock), oldIrql);
-#endif
ExFreePool(Fcb);
}
@@ -189,12 +176,8 @@
NtfsAddFCBToTable(PNTFS_VCB Vcb,
PNTFS_FCB Fcb)
{
- KIRQL oldIrql;
-
- KeAcquireSpinLock(&Vcb->FcbListLock, &oldIrql);
Fcb->Vcb = Vcb;
- InsertTailList(&Vcb->FcbListHead, &Fcb->FcbListEntry);
- KeReleaseSpinLock(&Vcb->FcbListLock, oldIrql);
+ ExInterlockedInsertTailList(&(Vcb->FcbListHead), &(Fcb->FcbListEntry),
&(Vcb->FcbListLock));
}
@@ -286,7 +269,7 @@
{
PNTFS_FCB Fcb;
- Fcb = NtfsCreateFCB(L"\\", Vcb);
+ Fcb = NtfsCreateFCB(L"\\");
// memset(Fcb->entry.Filename, ' ', 11);
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 Jul 5 08:40:17
2008
@@ -381,8 +381,9 @@
Vcb->StorageDevice);
InitializeListHead(&Vcb->FcbListHead);
-
- Fcb = NtfsCreateFCB(NULL, Vcb);
+ KeInitializeSpinLock(&Vcb->FcbListLock);
+
+ Fcb = NtfsCreateFCB(NULL);
if (Fcb == NULL)
{
Status = STATUS_INSUFFICIENT_RESOURCES;
@@ -447,8 +448,6 @@
Vcb->MftBuffer = MftRecord;
ExInitializeResourceLite(&Vcb->DirResource);
-
- KeInitializeSpinLock(&Vcb->FcbListLock);
ExAcquireResourceExclusiveLite(&NtfsGlobalData->VolumeListLock, TRUE);
InsertHeadList(&NtfsGlobalData->VolumeListHead, &Vcb->VolumeListEntry);
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 Jul 5 08:40:17
2008
@@ -434,7 +434,7 @@
/* fcb.c */
PNTFS_FCB
-NtfsCreateFCB(PCWSTR FileName, PNTFS_VCB Vcb);
+NtfsCreateFCB(PCWSTR FileName);
VOID
NtfsDestroyFCB(PNTFS_FCB Fcb);