-----Original Message----- > Add a common feature for architectures to retrieve AX_PHYSMEM_BITS > from vmcoreinfo, which was added by kernel commit 1d50e5d0c505 (" > crash_core, vmcoreinfo: Append 'MAX_PHYSMEM_BITS' to vmcoreinfo"). > This makes makedumpfile adaptable for future MAX_PHYSMEM_BITS changes. > > Also ensure backward compatibility for kernel versions in which > MAX_PHYSMEM_BITS is not available in vmcoreinfo. > > Signed-off-by: Youling Tang <tangyouling@xxxxxxxxxxx> > --- > arch/mips64.c | 7 ++++++- > 1 file changed, 6 insertions(+), 1 deletion(-) > > diff --git a/arch/mips64.c b/arch/mips64.c > index c968082..d541c3e 100644 > --- a/arch/mips64.c > +++ b/arch/mips64.c > @@ -35,9 +35,14 @@ get_phys_base_mips64(void) > int > get_machdep_info_mips64(void) > { > - info->max_physmem_bits = _MAX_PHYSMEM_BITS; > info->section_size_bits = _SECTION_SIZE_BITS; > > + /* Check if we can get MAX_PHYSMEM_BITS from vmcoreinfo */ > + if (NUMBER(MAX_PHYSMEM_BITS) != NOT_FOUND_NUMBER) > + info->max_physmem_bits = NUMBER(MAX_PHYSMEM_BITS); > + else > + info->max_physmem_bits = _MAX_PHYSMEM_BITS; > + > DEBUG_MSG("max_physmem_bits : %lx\n", info->max_physmem_bits); > DEBUG_MSG("section_size_bits: %lx\n", info->section_size_bits); > > -- > 2.1.0 Thanks, I've edited the commit message a bit and applied: https://github.com/makedumpfile/makedumpfile/commit/974a507447e8d77df3a1e759cc569768372bfb8e Kazu _______________________________________________ kexec mailing list kexec@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/kexec