On Mon, Jun 08, 2026 at 03:34:54PM +0800, Jinjie Ruan wrote: > Subject: Re: [PATCH v16 05/10] x86: kexec_file: Use crash_prepare_headers() > helper to simplify code
Use proper subject prefix: "x86/crash: ..." > Use the newly introduced crash_prepare_headers() function to replace > the existing prepare_elf_headers(), allocate cmem and exclude crash kernel > memory in the crash core, which reduce code duplication. > > Only the following three architecture functions need to be implemented: > - arch_get_system_nr_ranges(). Call get_nr_ram_ranges_callback() > to pre-count the max number of memory ranges. > > - arch_crash_populate_cmem(). Use prepare_elf64_ram_headers_callback() > to collect the memory ranges and fills them into cmem. > > - arch_crash_exclude_ranges(). Exclude the low 1M for x86. > > By the way, remove the unused "nr_mem_ranges" in s/By the way/While at it/ > arch_crash_handle_hotplug_event(). > > Cc: Thomas Gleixner <[email protected]> > Cc: Ingo Molnar <[email protected]> > Cc: Borislav Petkov <[email protected]> > Cc: Dave Hansen <[email protected]> > Cc: Andrew Morton <[email protected]> > Cc: Vivek Goyal <[email protected]> > Reviewed-by: Sourabh Jain <[email protected]> > Acked-by: Baoquan He <[email protected]> > Acked-by: Mike Rapoport (Microsoft) <[email protected]> > Signed-off-by: Jinjie Ruan <[email protected]> > --- > arch/x86/kernel/crash.c | 89 +++++------------------------------------ > 1 file changed, 11 insertions(+), 78 deletions(-) With those nitpicks above addressed: Acked-by: Borislav Petkov (AMD) <[email protected]> -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette
