summaryrefslogtreecommitdiffstats
path: root/ArmPlatformPkg/Drivers
diff options
context:
space:
mode:
Diffstat (limited to 'ArmPlatformPkg/Drivers')
-rw-r--r--ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c b/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c
index 12a861267a..3ea858f46f 100644
--- a/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c
+++ b/ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashFvbDxe.c
@@ -628,10 +628,16 @@ FvbEraseBlocks (
}
// How many Lba blocks are we requested to erase?
- NumOfLba = VA_ARG (Args, UINT32);
+ NumOfLba = VA_ARG (Args, UINTN);
// All blocks must be within range
- DEBUG ((DEBUG_BLKIO, "FvbEraseBlocks: Check if: ( StartingLba=%ld + NumOfLba=%d - 1 ) > LastBlock=%ld.\n", Instance->StartLba + StartingLba, NumOfLba, Instance->Media.LastBlock));
+ DEBUG ((
+ DEBUG_BLKIO,
+ "FvbEraseBlocks: Check if: ( StartingLba=%ld + NumOfLba=%Lu - 1 ) > LastBlock=%ld.\n",
+ Instance->StartLba + StartingLba,
+ (UINT64)NumOfLba,
+ Instance->Media.LastBlock
+ ));
if ((NumOfLba == 0) || ((Instance->StartLba + StartingLba + NumOfLba - 1) > Instance->Media.LastBlock)) {
VA_END (Args);
DEBUG ((EFI_D_ERROR, "FvbEraseBlocks: ERROR - Lba range goes past the last Lba.\n"));
@@ -656,7 +662,7 @@ FvbEraseBlocks (
}
// How many Lba blocks are we requested to erase?
- NumOfLba = VA_ARG (Args, UINT32);
+ NumOfLba = VA_ARG (Args, UINTN);
// Go through each one and erase it
while (NumOfLba > 0) {