update for HEAD-2003091401
[reactos.git] / ntoskrnl / fs / filelock.c
index f41c6b1..7df7068 100644 (file)
@@ -6,6 +6,7 @@
 #include <ddk/ntddk.h>
 #include <internal/ifs.h>
 #include <ddk/ntifs.h>
+#include <ntos.h>
 
 #define NDEBUG
 #include <internal/debug.h>
@@ -185,6 +186,7 @@ FsRtlpCheckLockForReadOrWriteAccess(
  * NAME                                                        EXPORTED
  *     FsRtlCheckLockForReadAccess
  *
+ * @implemented
  */
 BOOLEAN
 STDCALL
@@ -216,6 +218,7 @@ FsRtlCheckLockForReadAccess (
  * NAME                                                        EXPORTED
  *     FsRtlCheckLockForWriteAccess
  *
+ * @implemented
  */
 BOOLEAN
 STDCALL
@@ -250,6 +253,7 @@ FsRtlCheckLockForWriteAccess (
  * NAME                                                        EXPORTED
  *     FsRtlFastCheckLockForRead
  *
+ * @implemented
  */
 BOOLEAN
 STDCALL
@@ -277,6 +281,7 @@ FsRtlFastCheckLockForRead (
  * NAME                                                        EXPORTED
  *     FsRtlFastCheckLockForWrite
  *
+ * @implemented
  */
 BOOLEAN
 STDCALL
@@ -400,6 +405,7 @@ FsRtlpFastUnlockAllByKey(
  * NAME                                                        EXPORTED
  *     FsRtlFastUnlockAll
  *
+ * @implemented
  */
 NTSTATUS
 STDCALL
@@ -423,6 +429,7 @@ FsRtlFastUnlockAll /*ByProcess*/ (
  * NAME                                                        EXPORTED
  *     FsRtlFastUnlockAllByKey
  *
+ * @implemented
  */
 NTSTATUS
 STDCALL
@@ -534,14 +541,14 @@ FsRtlpCompletePendingLocks(
    //walk pending list, FIFO order, try 2 complete locks
    PLIST_ENTRY                   EnumEntry;
    PIRP                          Irp;
-   PIO_STACK_LOCATION            Stack;
+   PEXTENDED_IO_STACK_LOCATION            Stack;
 
    EnumEntry = LockToc->PendingListHead.Blink;
    while (EnumEntry != &LockToc->PendingListHead) 
    {
       Irp = CONTAINING_RECORD(EnumEntry,IRP, Tail.Overlay.ListEntry);
 
-      Stack = IoGetCurrentIrpStackLocation(Irp);
+      Stack = (PEXTENDED_IO_STACK_LOCATION) IoGetCurrentIrpStackLocation(Irp);
       if (FsRtlpAddLock(LockToc,
                         Stack->FileObject,
                         &Stack->Parameters.LockControl.ByteOffset,
@@ -684,6 +691,7 @@ FsRtlpUnlockSingle(
  * NAME                                                        EXPORTED
  *     FsRtlFastUnlockSingle
  *
+ * @implemented
  */
 NTSTATUS
 STDCALL
@@ -727,7 +735,7 @@ FsRtlpDumpFileLocks(
    PFILE_LOCK_GRANTED   Granted;
    PIRP                 Irp;
    PLIST_ENTRY          EnumEntry;
-   PIO_STACK_LOCATION   Stack;
+   PEXTENDED_IO_STACK_LOCATION   Stack;
 
    assert(FileLock);
    LockToc = FileLock->LockInformation;
@@ -767,7 +775,7 @@ FsRtlpDumpFileLocks(
    {
       Irp = CONTAINING_RECORD(EnumEntry, IRP , Tail.Overlay.ListEntry );
 
-      Stack = IoGetCurrentIrpStackLocation(Irp);
+      Stack = (PEXTENDED_IO_STACK_LOCATION) IoGetCurrentIrpStackLocation(Irp);
 
       DPRINT1("%s, start: %i, len: %i, end: %i, key: %i, proc: 0x%X, fob: 0x%X\n",
          (Stack->Flags & SL_EXCLUSIVE_LOCK) ? "EXCL" : "SHRD",
@@ -794,6 +802,7 @@ FsRtlpDumpFileLocks(
  * RETURN VALUE
  *     NULL if no more locks.
  *
+ * @implemented
  */
 PFILE_LOCK_INFO
 STDCALL
@@ -895,6 +904,7 @@ restart:;
  * NOTE
  *  Called when creating/allocating/initializing FCB
  *
+ * @implemented
  */
 VOID
 STDCALL
@@ -917,6 +927,7 @@ FsRtlInitializeFileLock (
  * NAME                                                        EXPORTED
  *     FsRtlPrivateLock
  *
+ * @implemented
  */
 BOOLEAN
 STDCALL
@@ -1063,6 +1074,7 @@ FsRtlPrivateLock (
  * NAME                                                        EXPORTED
  *     FsRtlProcessFileLock
  *
+ * @implemented
  */
 NTSTATUS
 STDCALL
@@ -1072,12 +1084,12 @@ FsRtlProcessFileLock (
    IN PVOID        Context OPTIONAL
    )
 {
-   PIO_STACK_LOCATION   Stack;
+   PEXTENDED_IO_STACK_LOCATION   Stack;
    NTSTATUS             Status;
    IO_STATUS_BLOCK      LocalIoStatus;
 
    assert(FileLock);
-   Stack = IoGetCurrentIrpStackLocation(Irp);
+   Stack = (PEXTENDED_IO_STACK_LOCATION) IoGetCurrentIrpStackLocation(Irp);
    Irp->IoStatus.Information = 0;
 
    switch(Stack->MinorFunction)
@@ -1151,6 +1163,7 @@ FsRtlProcessFileLock (
  * NAME                                                        EXPORTED
  *     FsRtlUninitializeFileLock
  *
+ * @implemented
  */
 VOID
 STDCALL
@@ -1234,6 +1247,7 @@ FsRtlUninitializeFileLock (
  *     Only present in NT 5.0 or later.
  *     FCB FILE_LOCK struct should/is acording to DDK allocated from paged pool!
  *
+ * @implemented
  */
 PFILE_LOCK
 STDCALL
@@ -1262,6 +1276,7 @@ FsRtlAllocateFileLock(
  *     Only present in NT 5.0 or later.
  *     FCB FILE_LOCK struct should/is acording to DDK allocated from paged pool!
  *
+ * @implemented
  */
 VOID
 STDCALL