From: Mike Rapoport <rppt@kernel.org>
To: Maxi Saparov <maxi.saparov@gmail.com>
Cc: Pasha Tatashin <pasha.tatashin@soleen.com>,
Pratyush Yadav <pratyush@kernel.org>,
Alexander Graf <graf@amazon.com>,
Evangelos Petrongonas <epetron@amazon.de>,
kexec@lists.infradead.org, linux-mm@kvack.org,
linux-kernel@vger.kernel.org, sdimitropoulos@coreweave.com,
Maxi Saparov <masaparov@coreweave.com>,
stable@vger.kernel.org
Subject: Re: [PATCH v2] kho: do not reserve scratch memory in the kdump kernel
Date: Sun, 16 Aug 2026 12:03:08 +0300 [thread overview]
Message-ID: <aoF8zPXiKpjt2Nsv@kernel.org> (raw)
In-Reply-To: <20260811161857.3096-1-maxi.saparov@gmail.com>
Hi,
Please don't send vN+1 as a reply to vN next time.
On Tue, Aug 11, 2026 at 12:18:57PM -0400, Maxi Saparov wrote:
> From: Maxi Saparov <masaparov@coreweave.com>
>
> If a kernel with CONFIG_KEXEC_HANDOVER_ENABLE_DEFAULT=y (or kho=on)
> does not receive a handover FDT, it reserves KHO scratch memory in
> kho_reserve_scratch().
>
> The kdump kernel always takes this path. Since commit a6715d7ec472
> ("kho: skip KHO for crash kernel"), the kernel does not add KHO
> metadata to the crash kimage. As a result, the kdump kernel never
> receives a handover FDT and always reserves scratch memory.
>
> The kdump kernel boots in the small crashkernel= memory reservation.
> On our x86 hosts, the kernel and initramfs make approximately 176 MB
> of early reservations. The scratch areas then use approximately
> 650 MB more of the crashkernel memory. When a large early allocation
> fails, the kdump kernel panics:
>
> bio: can't create integrity buf pool
>
> A kdump kernel has nothing to hand over: its only task is to dump the
> memory of the old kernel and reboot. Fix is to disable KHO at the top of
> kho_memory_init() so that the kdump kernel does not reserve scratch
> memory.
>
> Fixes: 3dc92c311498 ("kexec: add Kexec HandOver (KHO) generation helpers")
> Cc: stable@vger.kernel.org
> Signed-off-by: Maxi Saparov <masaparov@coreweave.com>
I queued this patch for v7.4, it'll appear in the liveupdate tree after the
merge window.
> ---
> v2: Move the kdump check to the top of kho_memory_init() as an early return.
> v1: https://lore.kernel.org/all/20260803193938.8778-1-maxi.saparov@gmail.com/
>
> kernel/liveupdate/kexec_handover.c | 7 +++++++
> 1 file changed, 7 insertions(+)
--
Sincerely yours,
Mike.
prev parent reply other threads:[~2026-08-16 9:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-03 19:39 [PATCH] kho: do not reserve scratch memory in the kdump kernel Maxi Saparov
2026-08-10 8:23 ` Mike Rapoport
2026-08-11 16:10 ` Maxi Saparov
2026-08-11 16:18 ` [PATCH v2] " Maxi Saparov
2026-08-16 9:03 ` Mike Rapoport [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aoF8zPXiKpjt2Nsv@kernel.org \
--to=rppt@kernel.org \
--cc=epetron@amazon.de \
--cc=graf@amazon.com \
--cc=kexec@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=masaparov@coreweave.com \
--cc=maxi.saparov@gmail.com \
--cc=pasha.tatashin@soleen.com \
--cc=pratyush@kernel.org \
--cc=sdimitropoulos@coreweave.com \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox