Skip to content

Commit c02dd80

Browse files
Sergei Trofimovichgregkh
authored andcommitted
ia64: fix EFI_DEBUG build
[ Upstream commit e3db00b ] When enabled local debugging via `#define EFI_DEBUG 1` noticed build failure: arch/ia64/kernel/efi.c:564:8: error: 'i' undeclared (first use in this function) While at it fixed benign string format mismatches visible only when EFI_DEBUG is enabled: arch/ia64/kernel/efi.c:589:11: warning: format '%lx' expects argument of type 'long unsigned int', but argument 5 has type 'u64' {aka 'long long unsigned int'} [-Wformat=] Link: https://lkml.kernel.org/r/20210328212246.685601-1-slyfox@gentoo.org Fixes: 14fb420 ("efi: Merge EFI system table revision and vendor checks") Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org> Cc: Ard Biesheuvel <ardb@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent c6b7e0b commit c02dd80

1 file changed

Lines changed: 6 additions & 5 deletions

File tree

‎arch/ia64/kernel/efi.c‎

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -413,10 +413,10 @@ efi_get_pal_addr (void)
413413
mask = ~((1 << IA64_GRANULE_SHIFT) - 1);
414414

415415
printk(KERN_INFO "CPU %d: mapping PAL code "
416-
"[0x%lx-0x%lx) into [0x%lx-0x%lx)\n",
417-
smp_processor_id(), md->phys_addr,
418-
md->phys_addr + efi_md_size(md),
419-
vaddr & mask, (vaddr & mask) + IA64_GRANULE_SIZE);
416+
"[0x%llx-0x%llx) into [0x%llx-0x%llx)\n",
417+
smp_processor_id(), md->phys_addr,
418+
md->phys_addr + efi_md_size(md),
419+
vaddr & mask, (vaddr & mask) + IA64_GRANULE_SIZE);
420420
#endif
421421
return __va(md->phys_addr);
422422
}
@@ -558,6 +558,7 @@ efi_init (void)
558558
{
559559
efi_memory_desc_t *md;
560560
void *p;
561+
unsigned int i;
561562

562563
for (i = 0, p = efi_map_start; p < efi_map_end;
563564
++i, p += efi_desc_size)
@@ -584,7 +585,7 @@ efi_init (void)
584585
}
585586

586587
printk("mem%02d: %s "
587-
"range=[0x%016lx-0x%016lx) (%4lu%s)\n",
588+
"range=[0x%016llx-0x%016llx) (%4lu%s)\n",
588589
i, efi_md_typeattr_format(buf, sizeof(buf), md),
589590
md->phys_addr,
590591
md->phys_addr + efi_md_size(md), size, unit);

0 commit comments

Comments
 (0)