[PATCH] makedumpfile: Correct vmap_area_list support for i386 and ppc32.
Atsushi Kumagai
ats-kumagai at wm.jp.nec.com
Thu Apr 16 01:13:57 PDT 2015
Hello,
When vmap_area_list was exported instead of vmlist in linux 3.10,
we fixed makedumpfile to refer to both of them, but I found that
the fix is incomplete. This bug will be fixed in v1.5.9.
Thanks,
Atsushi Kumagai
From: Atsushi Kumagai <ats-kumagai at wm.jp.nec.com>
Date: Tue, 14 Apr 2015 09:14:47 +0900
Subject: [PATCH] Correct vmap_area_list support for i386 and ppc32.
This fix is for cee64e3d8b and 8145e413ab.
vaddr_to_paddr() should allow to refer to vmalloc_start if
either vmlist or vmap_area_list is exported from the kernel
since vmalloc_start can be gotten from them.
Signed-off-by: Atsushi Kumagai <ats-kumagai at wm.jp.nec.com>
---
arch/ppc.c | 7 +++++--
arch/x86.c | 7 +++++--
2 files changed, 10 insertions(+), 4 deletions(-)
diff --git a/arch/ppc.c b/arch/ppc.c
index a3e1a12..37c6a3b 100644
--- a/arch/ppc.c
+++ b/arch/ppc.c
@@ -101,8 +101,11 @@ vaddr_to_paddr_ppc(unsigned long vaddr)
if (paddr != NOT_PADDR)
return paddr;
- if ((SYMBOL(vmlist) == NOT_FOUND_SYMBOL)
- || (OFFSET(vm_struct.addr) == NOT_FOUND_STRUCTURE)) {
+ if (((SYMBOL(vmap_area_list) == NOT_FOUND_SYMBOL)
+ || (OFFSET(vmap_area.va_start) == NOT_FOUND_STRUCTURE)
+ || (OFFSET(vmap_area.list) == NOT_FOUND_STRUCTURE))
+ && ((SYMBOL(vmlist) == NOT_FOUND_SYMBOL)
+ || (OFFSET(vm_struct.addr) == NOT_FOUND_STRUCTURE))) {
ERRMSG("Can't get necessary information for vmalloc translation.\n");
return NOT_PADDR;
}
diff --git a/arch/x86.c b/arch/x86.c
index e397905..1b4d2b6 100644
--- a/arch/x86.c
+++ b/arch/x86.c
@@ -239,8 +239,11 @@ vaddr_to_paddr_x86(unsigned long vaddr)
if ((paddr = vaddr_to_paddr_general(vaddr)) != NOT_PADDR)
return paddr;
- if ((SYMBOL(vmlist) == NOT_FOUND_SYMBOL)
- || (OFFSET(vm_struct.addr) == NOT_FOUND_STRUCTURE)) {
+ if (((SYMBOL(vmap_area_list) == NOT_FOUND_SYMBOL)
+ || (OFFSET(vmap_area.va_start) == NOT_FOUND_STRUCTURE)
+ || (OFFSET(vmap_area.list) == NOT_FOUND_STRUCTURE))
+ && ((SYMBOL(vmlist) == NOT_FOUND_SYMBOL)
+ || (OFFSET(vm_struct.addr) == NOT_FOUND_STRUCTURE))) {
ERRMSG("Can't get necessary information for vmalloc translation.\n");
return NOT_PADDR;
}
--
1.9.0
More information about the kexec
mailing list