From: WANG Chao <chaowang@redhat.com>
To: horms@verge.net.au, vgoyal@redhat.com, ebiederm@xmission.com,
hpa@zytor.com, trenn@suse.de, dyoung@redhat.com, linn@hp.com
Cc: kexec@lists.infradead.org
Subject: [PATCH v6 4/9] x86, cleanup: use dbgprint_mem_range for memory range debugging
Date: Mon, 14 Apr 2014 22:55:36 +0800 [thread overview]
Message-ID: <1397487341-17287-5-git-send-email-chaowang@redhat.com> (raw)
In-Reply-To: <1397487341-17287-1-git-send-email-chaowang@redhat.com>
Signed-off-by: WANG Chao <chaowang@redhat.com>
---
kexec/arch/i386/crashdump-x86.c | 26 +++-----------------------
1 file changed, 3 insertions(+), 23 deletions(-)
diff --git a/kexec/arch/i386/crashdump-x86.c b/kexec/arch/i386/crashdump-x86.c
index f97d79a..39c35ea 100644
--- a/kexec/arch/i386/crashdump-x86.c
+++ b/kexec/arch/i386/crashdump-x86.c
@@ -517,15 +517,7 @@ static int add_memmap(struct memory_range *memmap_p, int *nr_memmap,
memmap_p[tidx].type = type;
*nr_memmap = nr_entries + 1;
- dbgprintf("Memmap after adding segment\n");
- for (i = 0; i < CRASH_MAX_MEMMAP_NR; i++) {
- mstart = memmap_p[i].start;
- mend = memmap_p[i].end;
- if (mstart == 0 && mend == 0)
- break;
- dbgprintf("%016llx - %016llx\n",
- mstart, mend);
- }
+ dbgprint_mem_range("Memmap after adding segment", memmap_p, *nr_memmap);
return 0;
}
@@ -605,16 +597,7 @@ static int delete_memmap(struct memory_range *memmap_p, int *nr_memmap,
*nr_memmap = nr_entries - 1;
}
- dbgprintf("Memmap after deleting segment\n");
- for (i = 0; i < CRASH_MAX_MEMMAP_NR; i++) {
- mstart = memmap_p[i].start;
- mend = memmap_p[i].end;
- if (mstart == 0 && mend == 0) {
- break;
- }
- dbgprintf("%016llx - %016llx\n",
- mstart, mend);
- }
+ dbgprint_mem_range("Memmap after deleting segment", memmap_p, *nr_memmap);
return 0;
}
@@ -913,10 +896,7 @@ int load_crashdump_segments(struct kexec_info *info, char* mod_cmdline,
get_backup_area(info, mem_range, nr_ranges);
- dbgprintf("CRASH MEMORY RANGES\n");
-
- for(i = 0; i < nr_ranges; ++i)
- dbgprintf("%016Lx-%016Lx\n", mem_range[i].start, mem_range[i].end);
+ dbgprint_mem_range("CRASH MEMORY RANGES", mem_range, nr_ranges);
/*
* if the core type has not been set on command line, set it here
--
1.9.0
_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec
next prev parent reply other threads:[~2014-04-14 14:56 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-14 14:55 [PATCH v6 0/9] kexec-tools, x86: E820 memmap pass for kdump WANG Chao
2014-04-14 14:55 ` [PATCH v6 1/9] x86, cleanup: add extra arguments to add_memmap() and delete_memmap() WANG Chao
2014-04-14 14:55 ` [PATCH v6 2/9] x86, cleanup: add_memmap() only do alignment check on RANGE_RAM WANG Chao
2014-04-14 14:55 ` [PATCH v6 3/9] x86, cleanup: add other types of memory range for 2nd kernel boot to memmap_p WANG Chao
2014-04-14 14:55 ` WANG Chao [this message]
2014-04-14 14:55 ` [PATCH v6 5/9] x86, cleanup: increase CRASH_MAX_MEMMAP_NR up to CRASH_MAX_MEMORY_RANGES WANG Chao
2014-04-14 14:55 ` [PATCH v6 6/9] x86, cleanup: Store crash memory ranges kexec_info WANG Chao
2014-04-14 14:55 ` [PATCH v6 7/9] x86, cleanup: kexec memory range .end to be inclusive WANG Chao
2014-04-14 14:55 ` [PATCH v6 8/9] x86: add --pass-memmap-cmdline option WANG Chao
2014-04-14 14:55 ` [PATCH v6 9/9] x86: Pass memory range via E820 for kdump WANG Chao
2014-04-17 5:29 ` Dave Young
2014-04-17 5:35 ` Dave Young
2014-04-17 6:17 ` WANG Chao
2014-04-17 6:32 ` Dave Young
2014-04-17 6:44 ` Dave Young
2014-04-17 6:52 ` Dave Young
2014-04-17 7:05 ` WANG Chao
2014-04-17 6:57 ` WANG Chao
2014-04-17 7:07 ` Dave Young
2014-04-17 7:17 ` WANG Chao
2014-04-17 7:30 ` Dave Young
2014-04-17 8:42 ` WANG Chao
2014-04-17 9:45 ` Dave Young
2014-04-17 10:38 ` WANG Chao
2014-04-17 5:48 ` WANG Chao
2014-04-17 5:58 ` Dave Young
2014-04-21 0:01 ` Simon Horman
2014-04-21 2:49 ` WANG Chao
2014-04-21 15:16 ` Dave Young
2014-04-17 5:38 ` [PATCH v6 0/9] kexec-tools, x86: E820 memmap pass " Dave Young
2014-04-17 6:24 ` WANG Chao
2014-04-17 21:38 ` Linn Crosetto
2014-04-18 19:57 ` Linn Crosetto
2014-04-17 7:32 ` Dave Young
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1397487341-17287-5-git-send-email-chaowang@redhat.com \
--to=chaowang@redhat.com \
--cc=dyoung@redhat.com \
--cc=ebiederm@xmission.com \
--cc=horms@verge.net.au \
--cc=hpa@zytor.com \
--cc=kexec@lists.infradead.org \
--cc=linn@hp.com \
--cc=trenn@suse.de \
--cc=vgoyal@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox