Skip to contentSkip to conversation

crash_dump-reuse-saved-dm-crypt-keys-for-cpu-memory-hot-plugging.patch removed from -mm tree

merged mm-nonmm-stable Andrew Morton 1 participant 1 message May 21, 2025

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: crash_dump: reuse saved dm crypt keys for CPU/memory hot-plugging
has been removed from the -mm tree. Its filename was
crash_dump-reuse-saved-dm-crypt-keys-for-cpu-memory-hot-plugging.patch

This patch was dropped because it was merged into the mm-nonmm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: Coiby Xu <[email protected]>
Subject: crash_dump: reuse saved dm crypt keys for CPU/memory hot-plugging
Date: Fri, 2 May 2025 09:12:38 +0800

When there are CPU and memory hot un/plugs, the dm crypt keys may need to be reloaded again depending on the solution for crash hotplug support. Currently, there are two solutions. One is to utilizes udev to instruct user space to reload the kdump kernel image and initrd, elfcorehdr and etc again. The other is to only update the elfcorehdr segment introduced in commit 247262756121 ("crash: add generic infrastructure for crash hotplug support").

For the 1st solution, the dm crypt keys need to be reloaded again. The user space can write true to /sys/kernel/config/crash_dm_crypt_key/reuse so the stored keys can be re-used.

For the 2nd solution, the dm crypt keys don't need to be reloaded. Currently, only x86 supports the 2nd solution. If the 2nd solution gets extended to all arches, this patch can be dropped.

Cc "Daniel P. Berrange" <[email protected]>
Cc Dave Hansen <[email protected]>
Cc Dave Young <[email protected]>
Cc Jan Pazdziora <[email protected]>
Cc Liu Pingfan <[email protected]>
Cc Milan Broz <[email protected]>
Cc Ondrej Kozina <[email protected]>
Cc Vitaly Kuznetsov <[email protected]>

---

 Documentation/admin-guide/kdump/kdump.rst |    4 +
 kernel/crash_dump_dm_crypt.c              |   52 ++++++++++++++++++--
 2 files changed, 52 insertions(+), 4 deletions(-)
Documentation/admin-guide/kdump/kdump.rst renamed from Documentation/admin-guide/kdump/kdump.rst~crash_dump-reuse-saved-dm-crypt-keys-for-cpu-memory-hot-plugging +4 -0
@@ -570,6 +570,10 @@ encrypted disk volume. User space can in
     cat /sys/kernel/config/crash_dm_crypt_keys/count
     2
 
+    # To support CPU/memory hot-plugging, re-use keys already saved to reserved
+    # memory
+    echo true > /sys/kernel/config/crash_dm_crypt_key/reuse
+
 2. Load the dump-capture kernel
 
 3. After the dump-capture kerne get booted, restore the keys to user keyring
kernel/crash_dump_dm_crypt.c renamed from kernel/crash_dump_dm_crypt.c~crash_dump-reuse-saved-dm-crypt-keys-for-cpu-memory-hot-plugging +48 -4

72 lines not on this page · raw message

_

Patches currently in -mm which might be from [email protected] are