Re: [PATCH v3 08/17] crash: Extract crash_get_memory_ranges() helper

Mike Rapoport <[email protected]>
Newsgroups gmane.linux.ports.ppc.embedded
Message-ID <178829364020.3691424.10343800427604677653.b4-review__4095.42329596064$1788293701$gmane$org@b4>
Hi,

> Factor out the crash memory range collection logic from
> crash_prepare_headers() into a separate function. This allows
> the memory hotplug path to obtain and modify the range list
> (e.g. remove offlined memory) before generating the elfcorehdr.
> 
> Cc: Andrew Morton <[email protected]>
> Cc: Baoquan He <[email protected]>
> Cc: Mike Rapoport <[email protected]>
> Cc: Pasha Tatashin <[email protected]>
> Cc: Pratyush Yadav <[email protected]>
> Cc: Dave Young <[email protected]>
> Signed-off-by: Jinjie Ruan <[email protected]>
>
> diff --git a/include/linux/crash_core.h b/include/linux/crash_core.h
> index bc087124cd78e..619af312bd9a5 100644
> --- a/include/linux/crash_core.h
> +++ b/include/linux/crash_core.h
> @@ -62,6 +62,7 @@ extern int crash_prepare_elf64_headers(struct crash_mem *mem, int need_kernel_ma
>  extern int crash_prepare_headers(int need_kernel_map, void **addr,
>  				 unsigned long *sz, unsigned long *nr_mem_ranges);
>  extern int crash_exclude_core_ranges(struct crash_mem **cmem);
> +extern int crash_get_memory_ranges(struct crash_mem **mem_ranges);

No need for extern here as well.

-- 
Sincerely yours,
Mike.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.