[U-Boot] [PATCH v2] efi_loader: Add debug output for efi_add_memory_map()

Tracing the arguments has been helpful for pinpointing overflows.
Cc: Alexander Graf agraf@suse.de Signed-off-by: Andreas Färber afaerber@suse.de --- lib/efi_loader/efi_memory.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/lib/efi_loader/efi_memory.c b/lib/efi_loader/efi_memory.c index df2381e..df3547c 100644 --- a/lib/efi_loader/efi_memory.c +++ b/lib/efi_loader/efi_memory.c @@ -130,6 +130,9 @@ uint64_t efi_add_memory_map(uint64_t start, uint64_t pages, int memory_type, bool carve_again; uint64_t carved_pages = 0;
+ debug("%s: 0x%" PRIx64 " 0x%" PRIx64 " %d %s\n", __func__, + start, pages, memory_type, overlap_only_ram ? "yes" : "no"); + if (!pages) return start;

Am 17.07.2016 um 06:57 schrieb Andreas Färber:
Tracing the arguments has been helpful for pinpointing overflows.
Cc: Alexander Graf agraf@suse.de Signed-off-by: Andreas Färber afaerber@suse.de
lib/efi_loader/efi_memory.c | 3 +++ 1 file changed, 3 insertions(+)
v2 uses debug(), rebased on the DEBUG_EFI cleanup, requested by Tom.
diff --git a/lib/efi_loader/efi_memory.c b/lib/efi_loader/efi_memory.c index df2381e..df3547c 100644 --- a/lib/efi_loader/efi_memory.c +++ b/lib/efi_loader/efi_memory.c @@ -130,6 +130,9 @@ uint64_t efi_add_memory_map(uint64_t start, uint64_t pages, int memory_type, bool carve_again; uint64_t carved_pages = 0;
- debug("%s: 0x%" PRIx64 " 0x%" PRIx64 " %d %s\n", __func__,
start, pages, memory_type, overlap_only_ram ? "yes" : "no");
- if (!pages) return start;

Am 17.07.2016 um 06:57 schrieb Andreas Färber afaerber@suse.de:
Tracing the arguments has been helpful for pinpointing overflows.
Cc: Alexander Graf agraf@suse.de Signed-off-by: Andreas Färber afaerber@suse.de
Reviewed-by: Alexander Graf agraf@suse.de
Thanks :)
Alex

On Sun, Jul 17, 2016 at 06:57:11AM +0200, Andreas Färber wrote:
Tracing the arguments has been helpful for pinpointing overflows.
Cc: Alexander Graf agraf@suse.de Signed-off-by: Andreas Färber afaerber@suse.de Reviewed-by: Alexander Graf agraf@suse.de
Applied to u-boot/master, thanks!
participants (3)
-
Alexander Graf
-
Andreas Färber
-
Tom Rini