mirror of
https://github.com/reactos/reactos.git
synced 2025-07-29 07:41:48 +00:00
[NTOSKRNL]
Fix a number of warnings from VS /analyze svn path=/trunk/; revision=58319
This commit is contained in:
parent
a087bbe982
commit
987bf80da1
11 changed files with 115 additions and 125 deletions
74
reactos/ntoskrnl/cache/section/data.c
vendored
74
reactos/ntoskrnl/cache/section/data.c
vendored
|
@ -131,9 +131,9 @@ MiZeroFillSection(PVOID Address, PLARGE_INTEGER FileOffsetPtr, ULONG Length)
|
|||
LARGE_INTEGER FileOffset = *FileOffsetPtr, End, FirstMapped;
|
||||
KIRQL OldIrql;
|
||||
|
||||
DPRINT("MiZeroFillSection(Address %x,Offset %x,Length %x)\n",
|
||||
DPRINT("MiZeroFillSection(Address %p, Offset 0x%I64x,Length 0x%lx)\n",
|
||||
Address,
|
||||
FileOffset.LowPart,
|
||||
FileOffset.QuadPart,
|
||||
Length);
|
||||
|
||||
AddressSpace = MmGetKernelAddressSpace();
|
||||
|
@ -224,10 +224,10 @@ _MiFlushMappedSection(PVOID BaseAddress,
|
|||
PPFN_NUMBER Pages;
|
||||
KIRQL OldIrql;
|
||||
|
||||
DPRINT("MiFlushMappedSection(%x,%08x,%x,%d,%s:%d)\n",
|
||||
DPRINT("MiFlushMappedSection(%p,%I64x,%I64x,%u,%s:%d)\n",
|
||||
BaseAddress,
|
||||
BaseOffset->LowPart,
|
||||
FileSize,
|
||||
BaseOffset->QuadPart,
|
||||
FileSize ? FileSize->QuadPart : 0,
|
||||
WriteData,
|
||||
File,
|
||||
Line);
|
||||
|
@ -508,7 +508,7 @@ MmCreateCacheSection(PROS_SECTION_OBJECT *SectionObject,
|
|||
return STATUS_NO_MEMORY;
|
||||
}
|
||||
|
||||
DPRINT("Zeroing %x\n", Segment);
|
||||
DPRINT("Zeroing %p\n", Segment);
|
||||
RtlZeroMemory(Segment, sizeof(MM_SECTION_SEGMENT));
|
||||
ExInitializeFastMutex(&Segment->Lock);
|
||||
|
||||
|
@ -555,7 +555,7 @@ MmCreateCacheSection(PROS_SECTION_OBJECT *SectionObject,
|
|||
else
|
||||
{
|
||||
KeReleaseSpinLock(&FileObject->IrpListLock, OldIrql);
|
||||
DPRINTC("Free Segment %x\n", Segment);
|
||||
DPRINTC("Free Segment %p\n", Segment);
|
||||
ExFreePoolWithTag(Segment, TAG_MM_SECTION_SEGMENT);
|
||||
|
||||
DPRINT("Filling out Segment info (previous data section)\n");
|
||||
|
@ -583,16 +583,13 @@ MmCreateCacheSection(PROS_SECTION_OBJECT *SectionObject,
|
|||
Section->MaximumSize.QuadPart = MaximumSize.QuadPart;
|
||||
|
||||
/* Extend file if section is longer */
|
||||
DPRINT("MaximumSize %08x%08x ValidDataLength %08x%08x\n",
|
||||
MaximumSize.u.HighPart,
|
||||
MaximumSize.u.LowPart,
|
||||
FileSizes.ValidDataLength.u.HighPart,
|
||||
FileSizes.ValidDataLength.u.LowPart);
|
||||
DPRINT("MaximumSize %I64x ValidDataLength %I64x\n",
|
||||
MaximumSize.QuadPart,
|
||||
FileSizes.ValidDataLength.QuadPart);
|
||||
if (MaximumSize.QuadPart > FileSizes.ValidDataLength.QuadPart)
|
||||
{
|
||||
DPRINT("Changing file size to %08x%08x, segment %x\n",
|
||||
MaximumSize.u.HighPart,
|
||||
MaximumSize.u.LowPart,
|
||||
DPRINT("Changing file size to %I64x, segment %p\n",
|
||||
MaximumSize.QuadPart,
|
||||
Segment);
|
||||
|
||||
Status = IoSetInformation(FileObject,
|
||||
|
@ -609,7 +606,7 @@ MmCreateCacheSection(PROS_SECTION_OBJECT *SectionObject,
|
|||
}
|
||||
}
|
||||
|
||||
DPRINTC("Segment %x created (%x)\n", Segment, Segment->Flags);
|
||||
DPRINTC("Segment %p created (%x)\n", Segment, Segment->Flags);
|
||||
|
||||
*SectionObject = Section;
|
||||
return STATUS_SUCCESS;
|
||||
|
@ -645,7 +642,7 @@ _MiMapViewOfSegment(PMMSUPPORT AddressSpace,
|
|||
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT("Mapping between 0x%.8X and 0x%.8X failed (%X).\n",
|
||||
DPRINT("Mapping between 0x%p and 0x%p failed (%X).\n",
|
||||
(*BaseAddress),
|
||||
(char*)(*BaseAddress) + ViewSize,
|
||||
Status);
|
||||
|
@ -653,11 +650,11 @@ _MiMapViewOfSegment(PMMSUPPORT AddressSpace,
|
|||
return Status;
|
||||
}
|
||||
|
||||
DPRINTC("MiMapViewOfSegment %x %x %x %x %x %wZ %s:%d\n",
|
||||
DPRINTC("MiMapViewOfSegment %p %p %p %I64x %Ix %wZ %s:%d\n",
|
||||
MmGetAddressSpaceOwner(AddressSpace),
|
||||
*BaseAddress,
|
||||
Segment,
|
||||
ViewOffset ? ViewOffset->LowPart : 0,
|
||||
ViewOffset ? ViewOffset->QuadPart : 0,
|
||||
ViewSize,
|
||||
Segment->FileObject ? &Segment->FileObject->FileName : NULL,
|
||||
file,
|
||||
|
@ -680,7 +677,7 @@ _MiMapViewOfSegment(PMMSUPPORT AddressSpace,
|
|||
0,
|
||||
Protect);
|
||||
|
||||
DPRINTC("MiMapViewOfSegment(P %x, A %x, T %x)\n",
|
||||
DPRINTC("MiMapViewOfSegment(P %p, A %p, T %x)\n",
|
||||
MmGetAddressSpaceOwner(AddressSpace),
|
||||
*BaseAddress,
|
||||
MArea->Type);
|
||||
|
@ -704,10 +701,9 @@ MiFreeSegmentPage(PMM_SECTION_SEGMENT Segment,
|
|||
PFILE_OBJECT FileObject = Segment->FileObject;
|
||||
|
||||
Entry = MmGetPageEntrySectionSegment(Segment, FileOffset);
|
||||
DPRINTC("MiFreeSegmentPage(%x:%08x%08x -> Entry %x\n",
|
||||
DPRINTC("MiFreeSegmentPage(%p:%I64x -> Entry %Ix\n",
|
||||
Segment,
|
||||
FileOffset->HighPart,
|
||||
FileOffset->LowPart,
|
||||
FileOffset->QuadPart,
|
||||
Entry);
|
||||
|
||||
if (Entry && !IS_SWAP_FROM_SSE(Entry))
|
||||
|
@ -716,17 +712,16 @@ MiFreeSegmentPage(PMM_SECTION_SEGMENT Segment,
|
|||
PFN_NUMBER OldPage = PFN_FROM_SSE(Entry);
|
||||
if (IS_DIRTY_SSE(Entry) && FileObject)
|
||||
{
|
||||
DPRINT("MiWriteBackPage(%x,%wZ,%08x%08x)\n",
|
||||
DPRINT("MiWriteBackPage(%p,%wZ,%I64x)\n",
|
||||
Segment,
|
||||
&FileObject->FileName,
|
||||
FileOffset->u.HighPart,
|
||||
FileOffset->u.LowPart);
|
||||
FileOffset->QuadPart);
|
||||
|
||||
MiWriteBackPage(FileObject, FileOffset, PAGE_SIZE, OldPage);
|
||||
}
|
||||
DPRINTC("Free page %x (off %x from %x) (ref ct %d, ent %x, dirty? %s)\n",
|
||||
DPRINTC("Free page %Ix (off %I64x from %p) (ref ct %lu, ent %Ix, dirty? %s)\n",
|
||||
OldPage,
|
||||
FileOffset->LowPart,
|
||||
FileOffset->QuadPart,
|
||||
Segment,
|
||||
MmGetReferenceCountPage(OldPage),
|
||||
Entry,
|
||||
|
@ -759,7 +754,7 @@ MmFreeCacheSectionPage(PVOID Context,
|
|||
PMM_SECTION_SEGMENT Segment;
|
||||
LARGE_INTEGER Offset;
|
||||
|
||||
DPRINT("MmFreeSectionPage(%x,%x,%x,%x,%d)\n",
|
||||
DPRINT("MmFreeSectionPage(%p,%p,%Ix,%Ix,%u)\n",
|
||||
MmGetAddressSpaceOwner(ContextData[0]),
|
||||
Address,
|
||||
Page,
|
||||
|
@ -777,12 +772,12 @@ MmFreeCacheSectionPage(PVOID Context,
|
|||
|
||||
if (Page != 0 && PFN_FROM_SSE(Entry) == Page && Dirty)
|
||||
{
|
||||
DPRINT("Freeing section page %x:%x -> %x\n", Segment, Offset.LowPart, Entry);
|
||||
DPRINT("Freeing section page %p:%I64x -> %Ix\n", Segment, Offset.QuadPart, Entry);
|
||||
MmSetPageEntrySectionSegment(Segment, &Offset, DIRTY_SSE(Entry));
|
||||
}
|
||||
if (Page)
|
||||
{
|
||||
DPRINT("Removing page %x:%x -> %x\n", Segment, Offset.LowPart, Entry);
|
||||
DPRINT("Removing page %p:%I64x -> %x\n", Segment, Offset.QuadPart, Entry);
|
||||
MmSetSavedSwapEntryPage(Page, 0);
|
||||
MmDeleteRmap(Page, Process, Address);
|
||||
MmDeleteVirtualMapping(Process, Address, FALSE, NULL, NULL);
|
||||
|
@ -819,7 +814,7 @@ MmUnmapViewOfCacheSegment(PMMSUPPORT AddressSpace,
|
|||
Context[0] = AddressSpace;
|
||||
Context[1] = Segment;
|
||||
|
||||
DPRINT("MmFreeMemoryArea(%x,%x)\n",
|
||||
DPRINT("MmFreeMemoryArea(%p,%p)\n",
|
||||
MmGetAddressSpaceOwner(AddressSpace),
|
||||
MemoryArea->StartingAddress);
|
||||
|
||||
|
@ -827,7 +822,7 @@ MmUnmapViewOfCacheSegment(PMMSUPPORT AddressSpace,
|
|||
|
||||
MmUnlockSectionSegment(Segment);
|
||||
|
||||
DPRINTC("MiUnmapViewOfSegment %x %x %x\n",
|
||||
DPRINTC("MiUnmapViewOfSegment %p %p %p\n",
|
||||
MmGetAddressSpaceOwner(AddressSpace),
|
||||
BaseAddress,
|
||||
Segment);
|
||||
|
@ -843,15 +838,15 @@ MmExtendCacheSection(PROS_SECTION_OBJECT Section,
|
|||
{
|
||||
LARGE_INTEGER OldSize;
|
||||
PMM_SECTION_SEGMENT Segment = Section->Segment;
|
||||
DPRINT("Extend Segment %x\n", Segment);
|
||||
DPRINT("Extend Segment %p\n", Segment);
|
||||
|
||||
MmLockSectionSegment(Segment);
|
||||
OldSize.QuadPart = Segment->RawLength.QuadPart;
|
||||
MmUnlockSectionSegment(Segment);
|
||||
|
||||
DPRINT("OldSize %08x%08x NewSize %08x%08x\n",
|
||||
OldSize.u.HighPart, OldSize.u.LowPart,
|
||||
NewSize->u.HighPart, NewSize->u.LowPart);
|
||||
DPRINT("OldSize 0x%I64x NewSize 0x%I64x\n",
|
||||
OldSize.QuadPart,
|
||||
NewSize->QuadPart);
|
||||
|
||||
if (ExtendFile && OldSize.QuadPart < NewSize->QuadPart)
|
||||
{
|
||||
|
@ -883,9 +878,8 @@ MmMapCacheViewInSystemSpaceAtOffset(IN PMM_SECTION_SEGMENT Segment,
|
|||
PMMSUPPORT AddressSpace;
|
||||
NTSTATUS Status;
|
||||
|
||||
DPRINT("MmMapViewInSystemSpaceAtOffset() called offset %08x%08x\n",
|
||||
FileOffset->HighPart,
|
||||
FileOffset->LowPart);
|
||||
DPRINT("MmMapViewInSystemSpaceAtOffset() called offset 0x%I64x\n",
|
||||
FileOffset->QuadPart);
|
||||
|
||||
AddressSpace = MmGetKernelAddressSpace();
|
||||
|
||||
|
|
58
reactos/ntoskrnl/cache/section/fault.c
vendored
58
reactos/ntoskrnl/cache/section/fault.c
vendored
|
@ -189,7 +189,7 @@ MmNotPresentFaultCachePage (
|
|||
}
|
||||
else
|
||||
{
|
||||
DPRINT("Set %x in address space @ %x\n", Required->Page[0], Address);
|
||||
DPRINT("Set %x in address space @ %p\n", Required->Page[0], Address);
|
||||
Status = MmCreateVirtualMapping(Process,
|
||||
Address,
|
||||
Attributes,
|
||||
|
@ -332,7 +332,7 @@ MiCowCacheSectionPage (
|
|||
LARGE_INTEGER Offset;
|
||||
PEPROCESS Process = MmGetAddressSpaceOwner(AddressSpace);
|
||||
|
||||
DPRINT("MmAccessFaultSectionView(%x, %x, %x, %x)\n",
|
||||
DPRINT("MmAccessFaultSectionView(%p, %p, %p, %u)\n",
|
||||
AddressSpace,
|
||||
MemoryArea,
|
||||
Address,
|
||||
|
@ -358,11 +358,11 @@ MiCowCacheSectionPage (
|
|||
#endif
|
||||
{
|
||||
ULONG_PTR Entry;
|
||||
DPRINTC("setting non-cow page %x %x:%x offset %x (%x) to writable\n",
|
||||
DPRINTC("setting non-cow page %p %p:%p offset %I64x (%Ix) to writable\n",
|
||||
Segment,
|
||||
Process,
|
||||
PAddress,
|
||||
Offset.u.LowPart,
|
||||
Offset.QuadPart,
|
||||
MmGetPfnForProcess(Process, Address));
|
||||
if (Segment->FileObject)
|
||||
{
|
||||
|
@ -450,7 +450,7 @@ MiCowCacheSectionPage (
|
|||
MmReleasePageMemoryConsumer(MC_CACHE, OldPage);
|
||||
MmUnlockSectionSegment(Segment);
|
||||
|
||||
DPRINT("Address 0x%.8X\n", Address);
|
||||
DPRINT("Address 0x%p\n", Address);
|
||||
return STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
|
@ -539,11 +539,11 @@ MmpSectionAccessFaultInner(KPROCESSOR_MODE Mode,
|
|||
|
||||
RtlZeroMemory(&Context, sizeof(WORK_QUEUE_WITH_CONTEXT));
|
||||
|
||||
DPRINT("MmAccessFault(Mode %d, Address %x)\n", Mode, Address);
|
||||
DPRINT("MmAccessFault(Mode %d, Address %Ix)\n", Mode, Address);
|
||||
|
||||
if (KeGetCurrentIrql() >= DISPATCH_LEVEL)
|
||||
{
|
||||
DPRINT1("Page fault at high IRQL was %d\n", KeGetCurrentIrql());
|
||||
DPRINT1("Page fault at high IRQL was %u\n", KeGetCurrentIrql());
|
||||
return STATUS_UNSUCCESSFUL;
|
||||
}
|
||||
|
||||
|
@ -553,7 +553,7 @@ MmpSectionAccessFaultInner(KPROCESSOR_MODE Mode,
|
|||
/* Check permissions */
|
||||
if (Mode != KernelMode)
|
||||
{
|
||||
DPRINT("MmAccessFault(Mode %d, Address %x)\n", Mode, Address);
|
||||
DPRINT("MmAccessFault(Mode %d, Address %Ix)\n", Mode, Address);
|
||||
return STATUS_ACCESS_VIOLATION;
|
||||
}
|
||||
AddressSpace = MmGetKernelAddressSpace();
|
||||
|
@ -578,11 +578,11 @@ MmpSectionAccessFaultInner(KPROCESSOR_MODE Mode,
|
|||
{
|
||||
MmUnlockAddressSpace(AddressSpace);
|
||||
}
|
||||
DPRINT("Address: %x\n", Address);
|
||||
DPRINT("Address: %Ix\n", Address);
|
||||
return STATUS_ACCESS_VIOLATION;
|
||||
}
|
||||
|
||||
DPRINT("Type %x (%x -> %x)\n",
|
||||
DPRINT("Type %x (%p -> %p)\n",
|
||||
MemoryArea->Type,
|
||||
MemoryArea->StartingAddress,
|
||||
MemoryArea->EndingAddress);
|
||||
|
@ -605,9 +605,9 @@ MmpSectionAccessFaultInner(KPROCESSOR_MODE Mode,
|
|||
if (Status == STATUS_SUCCESS + 1)
|
||||
{
|
||||
/* Wait page ... */
|
||||
DPRINT("Waiting for %x\n", Address);
|
||||
DPRINT("Waiting for %Ix\n", Address);
|
||||
MiWaitForPageEvent(MmGetAddressSpaceOwner(AddressSpace), Address);
|
||||
DPRINT("Restarting fault %x\n", Address);
|
||||
DPRINT("Restarting fault %Ix\n", Address);
|
||||
Status = STATUS_MM_RESTART_OPERATION;
|
||||
}
|
||||
else if (Status == STATUS_MM_RESTART_OPERATION)
|
||||
|
@ -619,7 +619,7 @@ MmpSectionAccessFaultInner(KPROCESSOR_MODE Mode,
|
|||
{
|
||||
if (Thread->ActiveFaultCount > 0)
|
||||
{
|
||||
DPRINT("Already fault handling ... going to work item (%x)\n",
|
||||
DPRINT("Already fault handling ... going to work item (%Ix)\n",
|
||||
Address);
|
||||
Context.AddressSpace = AddressSpace;
|
||||
Context.MemoryArea = MemoryArea;
|
||||
|
@ -657,8 +657,8 @@ MmpSectionAccessFaultInner(KPROCESSOR_MODE Mode,
|
|||
|
||||
if (!NT_SUCCESS(Status) && MemoryArea->Type == 1)
|
||||
{
|
||||
DPRINT1("Completed page fault handling %x %x\n", Address, Status);
|
||||
DPRINT1("Type %x (%x -> %x)\n",
|
||||
DPRINT1("Completed page fault handling %Ix %x\n", Address, Status);
|
||||
DPRINT1("Type %x (%p -> %p)\n",
|
||||
MemoryArea->Type,
|
||||
MemoryArea->StartingAddress,
|
||||
MemoryArea->EndingAddress);
|
||||
|
@ -693,13 +693,13 @@ MmAccessFaultCacheSection(KPROCESSOR_MODE Mode,
|
|||
PMMSUPPORT AddressSpace;
|
||||
NTSTATUS Status;
|
||||
|
||||
DPRINT("MmpAccessFault(Mode %d, Address %x)\n", Mode, Address);
|
||||
DPRINT("MmpAccessFault(Mode %d, Address %Ix)\n", Mode, Address);
|
||||
|
||||
Thread = PsGetCurrentThread();
|
||||
|
||||
if (KeGetCurrentIrql() >= DISPATCH_LEVEL)
|
||||
{
|
||||
DPRINT1("Page fault at high IRQL %d, address %x\n",
|
||||
DPRINT1("Page fault at high IRQL %u, address %Ix\n",
|
||||
KeGetCurrentIrql(),
|
||||
Address);
|
||||
return STATUS_UNSUCCESSFUL;
|
||||
|
@ -711,7 +711,7 @@ MmAccessFaultCacheSection(KPROCESSOR_MODE Mode,
|
|||
/* Check permissions */
|
||||
if (Mode != KernelMode)
|
||||
{
|
||||
DPRINT1("Address: %x:%x\n", PsGetCurrentProcess(), Address);
|
||||
DPRINT1("Address: %p:%Ix\n", PsGetCurrentProcess(), Address);
|
||||
return STATUS_ACCESS_VIOLATION;
|
||||
}
|
||||
AddressSpace = MmGetKernelAddressSpace();
|
||||
|
@ -780,13 +780,13 @@ MmNotPresentFaultCacheSectionInner(KPROCESSOR_MODE Mode,
|
|||
{
|
||||
DPRINT1("No memory area\n");
|
||||
}
|
||||
DPRINT1("Process %x, Address %x\n",
|
||||
DPRINT1("Process %p, Address %Ix\n",
|
||||
MmGetAddressSpaceOwner(AddressSpace),
|
||||
Address);
|
||||
break;
|
||||
}
|
||||
|
||||
DPRINTC("Type %x (%x -> %x -> %x) in %x\n",
|
||||
DPRINTC("Type %x (%p -> %08Ix -> %p) in %p\n",
|
||||
MemoryArea->Type,
|
||||
MemoryArea->StartingAddress,
|
||||
Address,
|
||||
|
@ -816,9 +816,9 @@ MmNotPresentFaultCacheSectionInner(KPROCESSOR_MODE Mode,
|
|||
else if (Status == STATUS_SUCCESS + 1)
|
||||
{
|
||||
/* Wait page ... */
|
||||
DPRINT("Waiting for %x\n", Address);
|
||||
DPRINT("Waiting for %Ix\n", Address);
|
||||
MiWaitForPageEvent(MmGetAddressSpaceOwner(AddressSpace), Address);
|
||||
DPRINT("Done waiting for %x\n", Address);
|
||||
DPRINT("Done waiting for %Ix\n", Address);
|
||||
Status = STATUS_MM_RESTART_OPERATION;
|
||||
}
|
||||
else if (Status == STATUS_MM_RESTART_OPERATION)
|
||||
|
@ -831,7 +831,7 @@ MmNotPresentFaultCacheSectionInner(KPROCESSOR_MODE Mode,
|
|||
{
|
||||
if (Thread->ActiveFaultCount > 2)
|
||||
{
|
||||
DPRINTC("Already fault handling ... going to work item (%x)\n", Address);
|
||||
DPRINTC("Already fault handling ... going to work item (%Ix)\n", Address);
|
||||
Context.AddressSpace = AddressSpace;
|
||||
Context.MemoryArea = MemoryArea;
|
||||
Context.Required = &Resources;
|
||||
|
@ -850,13 +850,13 @@ MmNotPresentFaultCacheSectionInner(KPROCESSOR_MODE Mode,
|
|||
}
|
||||
else
|
||||
{
|
||||
DPRINT("DoAcquisition %x\n", Resources.DoAcquisition);
|
||||
DPRINT("DoAcquisition %p\n", Resources.DoAcquisition);
|
||||
|
||||
Status = Resources.DoAcquisition(AddressSpace,
|
||||
MemoryArea,
|
||||
&Resources);
|
||||
|
||||
DPRINT("DoAcquisition %x -> %x\n",
|
||||
DPRINT("DoAcquisition %p -> %x\n",
|
||||
Resources.DoAcquisition,
|
||||
Status);
|
||||
}
|
||||
|
@ -878,7 +878,7 @@ MmNotPresentFaultCacheSectionInner(KPROCESSOR_MODE Mode,
|
|||
}
|
||||
while (Status == STATUS_MM_RESTART_OPERATION);
|
||||
|
||||
DPRINTC("Completed page fault handling: %x:%x %x\n",
|
||||
DPRINTC("Completed page fault handling: %p:%Ix %x\n",
|
||||
MmGetAddressSpaceOwner(AddressSpace),
|
||||
Address,
|
||||
Status);
|
||||
|
@ -913,13 +913,13 @@ MmNotPresentFaultCacheSection(KPROCESSOR_MODE Mode,
|
|||
NTSTATUS Status;
|
||||
|
||||
Address &= ~(PAGE_SIZE - 1);
|
||||
DPRINT("MmNotPresentFault(Mode %d, Address %x)\n", Mode, Address);
|
||||
DPRINT("MmNotPresentFault(Mode %d, Address %Ix)\n", Mode, Address);
|
||||
|
||||
Thread = PsGetCurrentThread();
|
||||
|
||||
if (KeGetCurrentIrql() >= DISPATCH_LEVEL)
|
||||
{
|
||||
DPRINT1("Page fault at high IRQL %d, address %x\n",
|
||||
DPRINT1("Page fault at high IRQL %u, address %Ix\n",
|
||||
KeGetCurrentIrql(),
|
||||
Address);
|
||||
|
||||
|
@ -953,7 +953,7 @@ MmNotPresentFaultCacheSection(KPROCESSOR_MODE Mode,
|
|||
|
||||
ASSERT(Status != STATUS_UNSUCCESSFUL);
|
||||
ASSERT(Status != STATUS_INVALID_PARAMETER);
|
||||
DPRINT("MmAccessFault %x:%x -> %x\n",
|
||||
DPRINT("MmAccessFault %p:%Ix -> %x\n",
|
||||
MmGetAddressSpaceOwner(AddressSpace),
|
||||
Address,
|
||||
Status);
|
||||
|
|
6
reactos/ntoskrnl/cache/section/io.c
vendored
6
reactos/ntoskrnl/cache/section/io.c
vendored
|
@ -135,7 +135,7 @@ MiSimpleRead(PFILE_OBJECT FileObject,
|
|||
|
||||
ASSERT(DeviceObject);
|
||||
|
||||
DPRINT("PAGING READ: FileObject %p <%wZ> Offset %08x%08x Length %d\n",
|
||||
DPRINT("PAGING READ: FileObject %p <%wZ> Offset %08x%08x Length %ul\n",
|
||||
FileObject,
|
||||
&FileObject->FileName,
|
||||
FileOffset->HighPart,
|
||||
|
@ -222,10 +222,10 @@ _MiSimpleWrite(PFILE_OBJECT FileObject,
|
|||
DeviceObject = MmGetDeviceObjectForFile(FileObject);
|
||||
ASSERT(DeviceObject);
|
||||
|
||||
DPRINT("PAGING WRITE: FileObject %x <%wZ> Offset %x Length %d (%s:%d)\n",
|
||||
DPRINT("PAGING WRITE: FileObject %p <%wZ> Offset 0x%I64x Length %lu (%s:%d)\n",
|
||||
FileObject,
|
||||
&FileObject->FileName,
|
||||
FileOffset->LowPart,
|
||||
FileOffset->QuadPart,
|
||||
Length,
|
||||
File,
|
||||
Line);
|
||||
|
|
4
reactos/ntoskrnl/cache/section/newmm.h
vendored
4
reactos/ntoskrnl/cache/section/newmm.h
vendored
|
@ -36,12 +36,12 @@
|
|||
#define SEC_CACHE (0x20000000)
|
||||
|
||||
#define MiWaitForPageEvent(Process,Address) do { \
|
||||
DPRINT("MiWaitForPageEvent %x:%x #\n", Process, Address); \
|
||||
DPRINT("MiWaitForPageEvent %p:%Ix #\n", Process, Address); \
|
||||
KeWaitForSingleObject(&MmWaitPageEvent, 0, KernelMode, FALSE, NULL); \
|
||||
} while(0)
|
||||
|
||||
#define MiSetPageEvent(Process,Address) do { \
|
||||
DPRINT("MiSetPageEvent %x:%x #\n",Process, Address); \
|
||||
DPRINT("MiSetPageEvent %p:%p #\n",Process, (PVOID)(Address)); \
|
||||
KeSetEvent(&MmWaitPageEvent, IO_NO_INCREMENT, FALSE); \
|
||||
} while(0)
|
||||
|
||||
|
|
7
reactos/ntoskrnl/cache/section/reqtools.c
vendored
7
reactos/ntoskrnl/cache/section/reqtools.c
vendored
|
@ -145,11 +145,10 @@ MiReadFilePage(PMMSUPPORT AddressSpace,
|
|||
PMDL Mdl = (PMDL)MdlBase;
|
||||
KIRQL OldIrql;
|
||||
|
||||
DPRINTC("Pulling page %08x%08x from %wZ to %x\n",
|
||||
FileOffset->u.HighPart,
|
||||
FileOffset->u.LowPart,
|
||||
DPRINTC("Pulling page %I64x from %wZ to %Ix\n",
|
||||
FileOffset->QuadPart,
|
||||
&FileObject->FileName,
|
||||
Page);
|
||||
*Page);
|
||||
|
||||
Status = MmRequestPageMemoryConsumer(RequiredResources->Consumer,
|
||||
TRUE,
|
||||
|
|
19
reactos/ntoskrnl/cache/section/sptab.c
vendored
19
reactos/ntoskrnl/cache/section/sptab.c
vendored
|
@ -123,10 +123,9 @@ MiSectionPageTableGet(PRTL_GENERIC_TABLE Table,
|
|||
ENTRIES_PER_ELEMENT * PAGE_SIZE);
|
||||
PageTable = RtlLookupElementGenericTable(Table, &SearchFileOffset);
|
||||
|
||||
DPRINT("MiSectionPageTableGet(%08x,%08x%08x)\n",
|
||||
DPRINT("MiSectionPageTableGet(%p,%I64x)\n",
|
||||
Table,
|
||||
FileOffset->HighPart,
|
||||
FileOffset->LowPart);
|
||||
FileOffset->QuadPart);
|
||||
|
||||
return PageTable;
|
||||
}
|
||||
|
@ -154,10 +153,9 @@ MiSectionPageTableGetOrAllocate(PRTL_GENERIC_TABLE Table,
|
|||
sizeof(SectionZeroPageTable),
|
||||
NULL);
|
||||
if (!PageTableSlice) return NULL;
|
||||
DPRINT("Allocate page table %x (%08x%08x)\n",
|
||||
DPRINT("Allocate page table %p (%I64x)\n",
|
||||
PageTableSlice,
|
||||
PageTableSlice->FileOffset.u.HighPart,
|
||||
PageTableSlice->FileOffset.u.LowPart);
|
||||
PageTableSlice->FileOffset.QuadPart);
|
||||
}
|
||||
return PageTableSlice;
|
||||
}
|
||||
|
@ -283,11 +281,10 @@ MmFreePageTablesSectionSegment(PMM_SECTION_SEGMENT Segment,
|
|||
PCACHE_SECTION_PAGE_TABLE Element;
|
||||
DPRINT("MiFreePageTablesSectionSegment(%p)\n", &Segment->PageTable);
|
||||
while ((Element = RtlGetElementGenericTable(&Segment->PageTable, 0))) {
|
||||
DPRINT("Delete table for <%wZ> %x -> %08x%08x\n",
|
||||
DPRINT("Delete table for <%wZ> %p -> %I64x\n",
|
||||
Segment->FileObject ? &Segment->FileObject->FileName : NULL,
|
||||
Segment,
|
||||
Element->FileOffset.u.HighPart,
|
||||
Element->FileOffset.u.LowPart);
|
||||
Element->FileOffset.QuadPart);
|
||||
if (FreePage)
|
||||
{
|
||||
ULONG i;
|
||||
|
@ -299,10 +296,10 @@ MmFreePageTablesSectionSegment(PMM_SECTION_SEGMENT Segment,
|
|||
Entry = Element->PageEntries[i];
|
||||
if (Entry && !IS_SWAP_FROM_SSE(Entry))
|
||||
{
|
||||
DPRINT("Freeing page %x:%x @ %x\n",
|
||||
DPRINT("Freeing page %p:%Ix @ %I64x\n",
|
||||
Segment,
|
||||
Entry,
|
||||
Offset.LowPart);
|
||||
Offset.QuadPart);
|
||||
|
||||
FreePage(Segment, &Offset);
|
||||
}
|
||||
|
|
|
@ -337,16 +337,16 @@ CcCopyRead (
|
|||
PCACHE_SEGMENT current;
|
||||
|
||||
DPRINT("CcCopyRead(FileObject 0x%p, FileOffset %I64x, "
|
||||
"Length %d, Wait %d, Buffer 0x%p, IoStatus 0x%p)\n",
|
||||
"Length %lu, Wait %u, Buffer 0x%p, IoStatus 0x%p)\n",
|
||||
FileObject, FileOffset->QuadPart, Length, Wait,
|
||||
Buffer, IoStatus);
|
||||
|
||||
Bcb = FileObject->SectionObjectPointer->SharedCacheMap;
|
||||
ReadOffset = (ULONG)FileOffset->QuadPart;
|
||||
|
||||
DPRINT("AllocationSize %d, FileSize %d\n",
|
||||
(ULONG)Bcb->AllocationSize.QuadPart,
|
||||
(ULONG)Bcb->FileSize.QuadPart);
|
||||
DPRINT("AllocationSize %I64d, FileSize %I64d\n",
|
||||
Bcb->AllocationSize.QuadPart,
|
||||
Bcb->FileSize.QuadPart);
|
||||
|
||||
/*
|
||||
* Check for the nowait case that all the cache segments that would
|
||||
|
@ -456,7 +456,7 @@ CcCopyWrite (
|
|||
BOOLEAN Valid;
|
||||
|
||||
DPRINT("CcCopyWrite(FileObject 0x%p, FileOffset %I64x, "
|
||||
"Length %d, Wait %d, Buffer 0x%p)\n",
|
||||
"Length %lu, Wait %u, Buffer 0x%p)\n",
|
||||
FileObject, FileOffset->QuadPart, Length, Wait, Buffer);
|
||||
|
||||
Bcb = FileObject->SectionObjectPointer->SharedCacheMap;
|
||||
|
@ -626,7 +626,7 @@ CcZeroData (
|
|||
KEVENT Event;
|
||||
|
||||
DPRINT("CcZeroData(FileObject 0x%p, StartOffset %I64x, EndOffset %I64x, "
|
||||
"Wait %d)\n", FileObject, StartOffset->QuadPart, EndOffset->QuadPart,
|
||||
"Wait %u)\n", FileObject, StartOffset->QuadPart, EndOffset->QuadPart,
|
||||
Wait);
|
||||
|
||||
Length = EndOffset->u.LowPart - StartOffset->u.LowPart;
|
||||
|
|
|
@ -136,10 +136,10 @@ CcSetFileSizes (
|
|||
|
||||
DPRINT("CcSetFileSizes(FileObject 0x%p, FileSizes 0x%p)\n",
|
||||
FileObject, FileSizes);
|
||||
DPRINT("AllocationSize %d, FileSize %d, ValidDataLength %d\n",
|
||||
(ULONG)FileSizes->AllocationSize.QuadPart,
|
||||
(ULONG)FileSizes->FileSize.QuadPart,
|
||||
(ULONG)FileSizes->ValidDataLength.QuadPart);
|
||||
DPRINT("AllocationSize %I64d, FileSize %I64d, ValidDataLength %I64d\n",
|
||||
FileSizes->AllocationSize.QuadPart,
|
||||
FileSizes->FileSize.QuadPart,
|
||||
FileSizes->ValidDataLength.QuadPart);
|
||||
|
||||
Bcb = FileObject->SectionObjectPointer->SharedCacheMap;
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@ CcMapData (
|
|||
PINTERNAL_BCB iBcb;
|
||||
ULONG ROffset;
|
||||
|
||||
DPRINT("CcMapData(FileObject 0x%p, FileOffset %I64x, Length %d, Flags %d,"
|
||||
DPRINT("CcMapData(FileObject 0x%p, FileOffset %I64x, Length %lu, Flags 0x%lx,"
|
||||
" pBcb 0x%p, pBuffer 0x%p)\n", FileObject, FileOffset->QuadPart,
|
||||
Length, Flags, pBcb, pBuffer);
|
||||
|
||||
|
|
|
@ -76,7 +76,7 @@ static void CcRosCacheSegmentIncRefCount_ ( PCACHE_SEGMENT cs, const char* file,
|
|||
++cs->ReferenceCount;
|
||||
if ( cs->Bcb->Trace )
|
||||
{
|
||||
DbgPrint("(%s:%i) CacheSegment %p ++RefCount=%d, Dirty %d, PageOut %d\n",
|
||||
DbgPrint("(%s:%i) CacheSegment %p ++RefCount=%lu, Dirty %u, PageOut %lu\n",
|
||||
file, line, cs, cs->ReferenceCount, cs->Dirty, cs->PageOut );
|
||||
}
|
||||
}
|
||||
|
@ -85,7 +85,7 @@ static void CcRosCacheSegmentDecRefCount_ ( PCACHE_SEGMENT cs, const char* file,
|
|||
--cs->ReferenceCount;
|
||||
if ( cs->Bcb->Trace )
|
||||
{
|
||||
DbgPrint("(%s:%i) CacheSegment %p --RefCount=%d, Dirty %d, PageOut %d\n",
|
||||
DbgPrint("(%s:%i) CacheSegment %p --RefCount=%lu, Dirty %u, PageOut %lu\n",
|
||||
file, line, cs, cs->ReferenceCount, cs->Dirty, cs->PageOut );
|
||||
}
|
||||
}
|
||||
|
@ -131,7 +131,7 @@ CcRosTraceCacheMap (
|
|||
current = CONTAINING_RECORD(current_entry, CACHE_SEGMENT, BcbSegmentListEntry);
|
||||
current_entry = current_entry->Flink;
|
||||
|
||||
DPRINT1(" CacheSegment 0x%p enabled, RefCount %d, Dirty %d, PageOut %d\n",
|
||||
DPRINT1(" CacheSegment 0x%p enabled, RefCount %lu, Dirty %u, PageOut %lu\n",
|
||||
current, current->ReferenceCount, current->Dirty, current->PageOut );
|
||||
}
|
||||
KeReleaseSpinLock(&Bcb->BcbLock, oldirql);
|
||||
|
@ -188,7 +188,7 @@ CcRosFlushDirtyPages (
|
|||
NTSTATUS Status;
|
||||
LARGE_INTEGER ZeroTimeout;
|
||||
|
||||
DPRINT("CcRosFlushDirtyPages(Target %d)\n", Target);
|
||||
DPRINT("CcRosFlushDirtyPages(Target %lu)\n", Target);
|
||||
|
||||
(*Count) = 0;
|
||||
ZeroTimeout.QuadPart = 0;
|
||||
|
@ -300,7 +300,7 @@ CcRosTrimCache (
|
|||
ULONG i;
|
||||
BOOLEAN FlushedPages = FALSE;
|
||||
|
||||
DPRINT("CcRosTrimCache(Target %d)\n", Target);
|
||||
DPRINT("CcRosTrimCache(Target %lu)\n", Target);
|
||||
|
||||
InitializeListHead(&FreeList);
|
||||
|
||||
|
@ -381,7 +381,7 @@ retry:
|
|||
if (PagesFreed != 0)
|
||||
{
|
||||
/* Try again after flushing dirty pages */
|
||||
DPRINT("Flushed %d dirty cache pages to disk\n", PagesFreed);
|
||||
DPRINT("Flushed %lu dirty cache pages to disk\n", PagesFreed);
|
||||
goto retry;
|
||||
}
|
||||
}
|
||||
|
@ -394,7 +394,7 @@ retry:
|
|||
CcRosInternalFreeCacheSegment(current);
|
||||
}
|
||||
|
||||
DPRINT("Evicted %d cache pages\n", (*NrFreed));
|
||||
DPRINT("Evicted %lu cache pages\n", (*NrFreed));
|
||||
|
||||
return(STATUS_SUCCESS);
|
||||
}
|
||||
|
@ -413,7 +413,7 @@ CcRosReleaseCacheSegment (
|
|||
|
||||
ASSERT(Bcb);
|
||||
|
||||
DPRINT("CcReleaseCacheSegment(Bcb 0x%p, CacheSeg 0x%p, Valid %d)\n",
|
||||
DPRINT("CcReleaseCacheSegment(Bcb 0x%p, CacheSeg 0x%p, Valid %u)\n",
|
||||
Bcb, CacheSeg, Valid);
|
||||
|
||||
KeAcquireGuardedMutex(&ViewLock);
|
||||
|
@ -464,7 +464,7 @@ CcRosLookupCacheSegment (
|
|||
|
||||
ASSERT(Bcb);
|
||||
|
||||
DPRINT("CcRosLookupCacheSegment(Bcb -x%p, FileOffset %d)\n", Bcb, FileOffset);
|
||||
DPRINT("CcRosLookupCacheSegment(Bcb -x%p, FileOffset %lu)\n", Bcb, FileOffset);
|
||||
|
||||
KeAcquireGuardedMutex(&ViewLock);
|
||||
KeAcquireSpinLock(&Bcb->BcbLock, &oldIrql);
|
||||
|
@ -507,7 +507,7 @@ CcRosMarkDirtyCacheSegment (
|
|||
|
||||
ASSERT(Bcb);
|
||||
|
||||
DPRINT("CcRosMarkDirtyCacheSegment(Bcb 0x%p, FileOffset %d)\n", Bcb, FileOffset);
|
||||
DPRINT("CcRosMarkDirtyCacheSegment(Bcb 0x%p, FileOffset %lu)\n", Bcb, FileOffset);
|
||||
|
||||
CacheSeg = CcRosLookupCacheSegment(Bcb, FileOffset);
|
||||
if (CacheSeg == NULL)
|
||||
|
@ -554,7 +554,7 @@ CcRosUnmapCacheSegment (
|
|||
|
||||
ASSERT(Bcb);
|
||||
|
||||
DPRINT("CcRosUnmapCacheSegment(Bcb 0x%p, FileOffset %d, NowDirty %d)\n",
|
||||
DPRINT("CcRosUnmapCacheSegment(Bcb 0x%p, FileOffset %lu, NowDirty %u)\n",
|
||||
Bcb, FileOffset, NowDirty);
|
||||
|
||||
CacheSeg = CcRosLookupCacheSegment(Bcb, FileOffset);
|
||||
|
@ -1045,7 +1045,7 @@ CcFlushCache (
|
|||
NTSTATUS Status;
|
||||
KIRQL oldIrql;
|
||||
|
||||
DPRINT("CcFlushCache(SectionObjectPointers 0x%p, FileOffset 0x%p, Length %d, IoStatus 0x%p)\n",
|
||||
DPRINT("CcFlushCache(SectionObjectPointers 0x%p, FileOffset 0x%p, Length %lu, IoStatus 0x%p)\n",
|
||||
SectionObjectPointers, FileOffset, Length, IoStatus);
|
||||
|
||||
if (SectionObjectPointers && SectionObjectPointers->SharedCacheMap)
|
||||
|
@ -1333,7 +1333,7 @@ CcRosInitializeFileCache (
|
|||
PBCB Bcb;
|
||||
|
||||
Bcb = FileObject->SectionObjectPointer->SharedCacheMap;
|
||||
DPRINT("CcRosInitializeFileCache(FileObject 0x%p, Bcb 0x%p, CacheSegmentSize %d)\n",
|
||||
DPRINT("CcRosInitializeFileCache(FileObject 0x%p, Bcb 0x%p, CacheSegmentSize %lu)\n",
|
||||
FileObject, Bcb, CacheSegmentSize);
|
||||
|
||||
KeAcquireGuardedMutex(&ViewLock);
|
||||
|
|
|
@ -94,7 +94,7 @@ BootImageFadeIn(VOID)
|
|||
ClrUsed = sizeof(_MainPalette) / sizeof(_MainPalette[0]);
|
||||
RtlZeroMemory(PaletteBitmap, sizeof(BITMAPINFOHEADER));
|
||||
PaletteBitmap->biSize = sizeof(BITMAPINFOHEADER);
|
||||
PaletteBitmap->biBitCount = 4;
|
||||
PaletteBitmap->biBitCount = 4;
|
||||
PaletteBitmap->biClrUsed = ClrUsed;
|
||||
|
||||
/*
|
||||
|
@ -104,12 +104,12 @@ BootImageFadeIn(VOID)
|
|||
{
|
||||
for (Index = 0; Index < ClrUsed; Index++)
|
||||
{
|
||||
Palette[Index].rgbRed =
|
||||
_MainPalette[Index].rgbRed * Iteration / PALETTE_FADE_STEPS;
|
||||
Palette[Index].rgbGreen =
|
||||
_MainPalette[Index].rgbGreen * Iteration / PALETTE_FADE_STEPS;
|
||||
Palette[Index].rgbBlue =
|
||||
_MainPalette[Index].rgbBlue * Iteration / PALETTE_FADE_STEPS;
|
||||
Palette[Index].rgbRed = (UCHAR)
|
||||
(_MainPalette[Index].rgbRed * Iteration / PALETTE_FADE_STEPS);
|
||||
Palette[Index].rgbGreen = (UCHAR)
|
||||
(_MainPalette[Index].rgbGreen * Iteration / PALETTE_FADE_STEPS);
|
||||
Palette[Index].rgbBlue = (UCHAR)
|
||||
(_MainPalette[Index].rgbBlue * Iteration / PALETTE_FADE_STEPS);
|
||||
}
|
||||
|
||||
VidBitBlt(PaletteBitmapBuffer, 0, 0);
|
||||
|
@ -221,7 +221,7 @@ InbvDriverInitialize(IN PLOADER_PARAMETER_BLOCK LoaderBlock,
|
|||
{
|
||||
/* Now reset the display, but only if there's a custom boot logo */
|
||||
VidResetDisplay(CustomLogo);
|
||||
|
||||
|
||||
/* Find bitmap resources in the kernel */
|
||||
ResourceCount = min(IDB_CLUSTER_SERVER, Count);
|
||||
for (i = 1; i <= Count; i++)
|
||||
|
@ -709,7 +709,7 @@ DisplayBootBitmap(IN BOOLEAN TextMode)
|
|||
InbvSetTextColor(15);
|
||||
InbvSolidColorFill(0, 0, 639, 479, 7);
|
||||
InbvSolidColorFill(0, 421, 639, 479, 1);
|
||||
|
||||
|
||||
/* Get resources */
|
||||
Header = InbvGetResourceAddress(IDB_LOGO_HEADER);
|
||||
Band = InbvGetResourceAddress(IDB_LOGO_BAND);
|
||||
|
@ -768,7 +768,7 @@ DisplayBootBitmap(IN BOOLEAN TextMode)
|
|||
/* Normal edition */
|
||||
Text = InbvGetResourceAddress(IDB_SERVER_LOGO);
|
||||
}
|
||||
|
||||
|
||||
/* Server product, display appropriate status bar color */
|
||||
InbvGetResourceAddress(IDB_BAR_SERVER);
|
||||
}
|
||||
|
@ -805,7 +805,7 @@ DisplayBootBitmap(IN BOOLEAN TextMode)
|
|||
InbvScreenToBufferBlt(Buffer, 413, 237, 7, 7, 8);
|
||||
InbvSolidColorFill(418, 230, 454, 256, 0);
|
||||
InbvBufferToScreenBlt(Buffer, 413, 237, 7, 7, 8);
|
||||
|
||||
|
||||
/* In setup mode, you haven't selected a SKU yet */
|
||||
if (ExpInTextModeSetup) Text = NULL;
|
||||
}
|
||||
|
@ -851,7 +851,7 @@ DisplayFilter(PCHAR *String)
|
|||
{
|
||||
/* Remove the filter */
|
||||
InbvInstallDisplayStringFilter(NULL);
|
||||
|
||||
|
||||
DotHack = FALSE;
|
||||
|
||||
/* Draw text screen */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue