Subject: Re: [PATCH v15 00/23] arm64/riscv: Add support for crashkernel CMA reservation

From: Baoquan He <[email-masked]>
Date: Tue, 2 Jun 2026 11:06:11 +0800

On 06/02/26 at 09:43am, Jinjie Ruan wrote:
> 
> 
> On 6/1/2026 9:40 PM, Baoquan He wrote:
> > Hi Jinjie,
> > 
> > On 06/01/26 at 05:47pm, Jinjie Ruan wrote:
> > ...snip... 
> >> Changes in v15:
> >> - Unify the subject prefix formats as Huacai suggested.
> >> - Fix powerpc pre-existing NULL pointer dereference [Sashiko [1]]
> >> - Fix powerpc pre-existing __merge_memory_ranges() memory range
> >>   truncation [Sashiko [1]].
> >> - Fix pre-existing arm64 CMA page leaks [Sashiko[2]].
> >> - Fix pre-existing crash_load_dm_crypt_keys() Use-After-Free and
> >>   Double Free issue [Sashiko[3]].
> >> - Fix vfree(headers) and uninitialized variables issue
> >>   and simplify the fix [Sashiko[2]].
> >> - As walk_system_ram_res() and for_each_mem_range() use different
> >>   lock, unify and simplify the fix of TOCTOU buffer overflow via memory
> >>   region padding [Sashiko[4]].
> >> - Fix the arm64 crash dump issues in Sashiko[5].
> >> - Link to v14: https://lore.kernel.org/all/[email-masked]/
> > 
> > Do these Fixes have anything with the main target of this patch series
> > you mentioned in cover-letter:"arm64/riscv: Add support for crashkernel CMA"?
> > The patches become more and more in each new version, I am wondering if
> > it relies on these Fixes patches to implement your adding support for
> > crashkernel CMA on arm64/risc-v.
> > 
> > If not relying on them, could you split them into different patchset
> > on different purpose? 
> 
> Hi Baoquan,
> 
> Thank you for your valuable guidance.
> 
> You are absolutely right. Most of these fix patches are indeed not
> strictly related to the core implementation of the crashkernel CMA
> support. They are pre-existing bugs in the surrounding kexec/crash code
> that were flagged during our review.
> 
> Previously, Andrew suggested taking a look at the code review comments
> from the Sashiko AI system, which is why these fixes kept expanding. I
> completely agree with your advice that there is no need to keep them
> together. I will split them into two completely different patchsets
> based on their purpose:
> 
> 1. A cleaner version of this series, strictly focused on adding the core
> crashkernel CMA support for arm64/riscv.
> 
> 2. One standalone bugfix patchset dedicated entirely to fixing these
> pre-existing issues.
> 
> By the way, I would also appreciate some advice on how to handle further
> AI reviews. It seems that the more code we touch or refactor to fix
> these pre-existing issues, the more tangential bugs the AI flags in the
> newly exposed areas, making the series extremely difficult to converge.
> 
> Should I continue to address all AI-reported bugs associated with the
> surrounding code in this series, or should we draw a strict line
> and only focus on the core CMA logic moving forward?

Then please post patches to focus on the core implementation of the
crashkernel CMA support. If any AI reported bugs are raised but not
relatd to it, you can add note in cover-letter or explain somewhere
to tell whehter it's caused by the core code and how you want
to deal with it. Otherwise, you could go round and round of new posting
and still can't see when it ends up.