mirror of
https://github.com/reactos/reactos.git
synced 2025-08-03 20:05:41 +00:00
[BOOTLIB] Fix 64 bit issues (#433)
This commit is contained in:
parent
8bbbab534a
commit
3be4081607
18 changed files with 85 additions and 58 deletions
|
@ -48,7 +48,7 @@ MmBapCompareBlockAllocatorTableEntry (
|
|||
)
|
||||
{
|
||||
PBL_BLOCK_DESCRIPTOR BlockInfo = (PBL_BLOCK_DESCRIPTOR)Entry;
|
||||
ULONG BlockId = (ULONG)Argument1;
|
||||
ULONG BlockId = PtrToUlong(Argument1);
|
||||
|
||||
/* Check if the block ID matches */
|
||||
return BlockInfo->BlockId == BlockId;
|
||||
|
@ -67,7 +67,7 @@ MmBapFindBlockInformation (
|
|||
MmBlockAllocatorTableEntries,
|
||||
&EntryId,
|
||||
MmBapCompareBlockAllocatorTableEntry,
|
||||
(PVOID)EntryId,
|
||||
UlongToPtr(EntryId),
|
||||
NULL,
|
||||
NULL,
|
||||
NULL);
|
||||
|
|
|
@ -567,7 +567,7 @@ MmHaInitialize (
|
|||
|
||||
PVOID
|
||||
BlMmAllocateHeap (
|
||||
_In_ ULONG Size
|
||||
_In_ SIZE_T Size
|
||||
)
|
||||
{
|
||||
ULONG BufferSize;
|
||||
|
@ -581,8 +581,8 @@ BlMmAllocateHeap (
|
|||
}
|
||||
|
||||
/* Align the buffer size to the minimum size required */
|
||||
BufferSize = ALIGN_UP(Size + FIELD_OFFSET(BL_BUSY_HEAP_ENTRY, Buffer),
|
||||
FIELD_OFFSET(BL_BUSY_HEAP_ENTRY, Buffer));
|
||||
BufferSize = ALIGN_UP_BY(Size + FIELD_OFFSET(BL_BUSY_HEAP_ENTRY, Buffer),
|
||||
FIELD_OFFSET(BL_BUSY_HEAP_ENTRY, Buffer));
|
||||
|
||||
/* Watch out for overflow */
|
||||
if (BufferSize <= Size)
|
||||
|
|
|
@ -865,7 +865,7 @@ MmPapAllocatePagesInRange (
|
|||
Type);
|
||||
|
||||
/* Return the allocated address */
|
||||
*PhysicalAddress = (PVOID)BaseAddress.LowPart;
|
||||
*PhysicalAddress = PhysicalAddressToPtr(BaseAddress);
|
||||
}
|
||||
|
||||
Exit:
|
||||
|
@ -1639,7 +1639,7 @@ MmSelectMappingAddress (
|
|||
if (MmTranslationType == BlNone)
|
||||
{
|
||||
/* Just return the physical address as the mapping address */
|
||||
PreferredAddress = (PVOID)PhysicalAddress.LowPart;
|
||||
PreferredAddress = PhysicalAddressToPtr(PhysicalAddress);
|
||||
goto Success;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue