On 2021/12/16 19:17, Borislav Petkov wrote: > On Fri, Dec 10, 2021 at 02:55:28PM +0800, Zhen Lei wrote: >> + * reserve_crashkernel() - reserves memory for crash kernel >> + * >> + * This function reserves memory area given in "crashkernel=" kernel command >> + * line parameter. The memory reserved is used by dump capture kernel when >> + * primary kernel is crashing. >> + */ >> +void __init reserve_crashkernel(void) > > As I've already alluded to in another mail, ontop of this there should > be a patch or multiple patches which clean this up more and perhaps even > split it into separate functions doing stuff in this order: > > 1. Parse all crashkernel= cmdline options > > 2. Do all crash_base, crash_size etc checks > > 3. Do the memory reservations > > And all that supplied with comments explaining why stuff is being done. I agree with you. This makes the code look clear. I will do it, try to post v18 next Monday. > > This set of functions is a mess and there's no better time for cleaning > it up and documenting it properly than when you move it to generic code. > > Thx. > _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec
- Re: [PATCH v17 01/10] x86: kdump: replace t... Leizhen (ThunderTown)
- [PATCH v17 07/10] arm64: kdump: reimplement crashker... Zhen Lei
- Re: [PATCH v17 07/10] arm64: kdump: reimplement... john . p . donnelly
- [PATCH v17 06/10] arm64: kdump: introduce some macro... Zhen Lei
- Re: [PATCH v17 06/10] arm64: kdump: introduce s... john . p . donnelly
- [PATCH v17 05/10] x86: kdump: move reserve_crashkern... Zhen Lei
- Re: [PATCH v17 05/10] x86: kdump: move reserve_... john . p . donnelly
- Re: [PATCH v17 05/10] x86: kdump: move reserve_... Baoquan He
- Re: [PATCH v17 05/10] x86: kdump: move rese... Leizhen (ThunderTown)
- Re: [PATCH v17 05/10] x86: kdump: move reserve_... Borislav Petkov
- Re: [PATCH v17 05/10] x86: kdump: move rese... Leizhen (ThunderTown)
- Re: [PATCH v17 05/10] x86: kdump: move ... Borislav Petkov
- [PATCH v17 08/10] of: fdt: Aggregate the processing ... Zhen Lei
- Re: [PATCH v17 08/10] of: fdt: Aggregate the pr... Rob Herring
- Re: [PATCH v17 08/10] of: fdt: Aggregate the pr... john . p . donnelly
- [PATCH v17 10/10] kdump: update Documentation about ... Zhen Lei
- Re: [PATCH v17 10/10] kdump: update Documentati... john . p . donnelly
- [PATCH v17 09/10] of: fdt: Add memory for devices by... Zhen Lei
- Re: [PATCH v17 09/10] of: fdt: Add memory for d... Rob Herring
- Re: [PATCH v17 09/10] of: fdt: Add memory for d... john . p . donnelly
- Re: [PATCH v17 00/10] support reserving crashkernel ... Kefeng Wang