Thread (17 messages) 17 messages, 8 authors, 2025-02-27

ARM64 crashes when resuming from hibernation (randomization features enabled)

From: Harry Yoo <hidden>
Date: 2025-02-27 02:52:30
Also in: linux-mm, stable

On Wed, Feb 26, 2025 at 03:31:03PM +0800, Huacai Chen wrote:
On Wed, Feb 26, 2025 at 4:41 AM Kees Cook [off-list ref] wrote:
quoted
On Tue, Feb 25, 2025 at 07:35:13PM +0800, Huacai Chen wrote:
quoted
I have investigated deeper, and then found it is an arch-specific
problem (at least for LoongArch), and the correct solution is here:
https://lore.kernel.org/loongarch/20250225111812.3065545-1-chenhuacai@loongson.cn/T/#u (local)
Ah-ha, so it seems like some system start was being incorrectly shared
between restoration image and hibernated image? Yeah, that's important
to fix.
quoted
But I don't know how to fix arm64.
Is arm64 broken in this same way?
ARM64 is broken but I don't know whether it is in the same way, I just
know this patch can solve ARM64's problem:
https://lore.kernel.org/linux-mm/CAAhV-H7i=WJmdFCCtY5DgE2eN657ddJwJwHGK1jgLKRte+VnEg@mail.gmail.com/T/#m6ca3bd9fd3fe519161f28715279d0dc371027506 (local)
Let's Cc ARM folks :)

A bit of context: LoongArch and ARM64 crash when resuming from hibernation if
CONFIG_RANDOM_KMALLOC_CACHES=y. Initially it was argued that kmalloc
randomization should be disabled during early boot. Kees and Rafael
thinks [1] randomization features should not be the root cause of the bug.
Later, Huacai fixed [2] the issue on LoongArch side by addressing
LoongArch-specific problem.

A similar crash related to the kmalloc randomization feature was reported [3]
on a ARM64-based laptop. ARM64 might be broken in a similar way, but
we don't know for sure yet.

[1] https://lore.kernel.org/linux-mm/CAJZ5v0hZZdRPwp=OgPw4w8r9X=VbL6Hn6R4ZX6ZujNhBmMV3_A@mail.gmail.com/ (local)
[2] https://lore.kernel.org/loongarch/20250225111812.3065545-1-chenhuacai@loongson.cn/T/#u (local)
[3] https://lore.kernel.org/linux-mm/CAAhV-H7i=WJmdFCCtY5DgE2eN657ddJwJwHGK1jgLKRte+VnEg@mail.gmail.com/T/#m6ca3bd9fd3fe519161f28715279d0dc371027506 (local)
Huacai
quoted
--
Kees Cook
-- 
Cheers,
Harry
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help