Skip to content

Commit

Permalink
Merge pull request #2065 from VOGL-electronic/bios_little_warning_fix
Browse files Browse the repository at this point in the history
bios: boot.c: fix warnings
  • Loading branch information
enjoy-digital authored Sep 11, 2024
2 parents dc8b74c + 3966e34 commit 11c7b69
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions litex/soc/software/bios/boot.c
Original file line number Diff line number Diff line change
Expand Up @@ -589,14 +589,14 @@ static unsigned int check_image_in_flash(unsigned int base_address)

length = MMPTR(base_address);
if((length < 32) || (length > 16*1024*1024)) {
printf("Error: Invalid image length 0x%08x\n", length);
printf("Error: Invalid image length 0x%08lx\n", length);
return 0;
}

crc = MMPTR(base_address + 4);
got_crc = crc32((unsigned char *)(base_address + 8), length);
if(crc != got_crc) {
printf("CRC failed (expected %08x, got %08x)\n", crc, got_crc);
printf("CRC failed (expected %08lx, got %08lx)\n", crc, got_crc);
return 0;
}

Expand All @@ -611,7 +611,7 @@ static int copy_image_from_flash_to_ram(unsigned int flash_address, unsigned lon

length = check_image_in_flash(flash_address);
if(length > 0) {
printf("Copying 0x%08x to 0x%08lx (%d bytes)...\n", flash_address, ram_address, length);
printf("Copying 0x%08x to 0x%08lx (%ld bytes)...\n", flash_address, ram_address, length);
offset = 0;
init_progression_bar(length);
while (length > 0) {
Expand Down

0 comments on commit 11c7b69

Please sign in to comment.