linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Harry Yoo <harry.yoo@oracle.com>
To: Huacai Chen <chenhuacai@kernel.org>
Cc: Kees Cook <kees@kernel.org>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	"Harry (Hyeonggon) Yoo" <42.hyeyoo@gmail.com>,
	Huacai Chen <chenhuacai@loongson.cn>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-mm@kvack.org, Pavel Machek <pavel@kernel.org>,
	linux-pm@vger.kernel.org, GONG Ruiqi <gongruiqi@huaweicloud.com>,
	Xiu Jianfeng <xiujianfeng@huawei.com>,
	stable@vger.kernel.org, Yuli Wang <wangyuli@uniontech.com>,
	Vlastimil Babka <vbabka@suse.cz>,
	Christoph Lameter <cl@linux.com>,
	David Rientjes <rientjes@google.com>,
	Roman Gushchin <roman.gushchin@linux.dev>,
	Pekka Enberg <penberg@kernel.org>,
	Joonsoo Kim <iamjoonsoo.kim@lge.com>,
	GONG Ruiqi <gongruiqi1@huawei.com>,
	linux-arm-kernel@lists.infradead.org
Subject: ARM64 crashes when resuming from hibernation (randomization features enabled)
Date: Thu, 27 Feb 2025 11:50:39 +0900	[thread overview]
Message-ID: <Z7_S__ExtqvNmD-3@harry> (raw)
In-Reply-To: <CAAhV-H43RS9Kfj__eHrzffUcC6BSESYTc0JiKWsn+Bg2BJkyZw@mail.gmail.com>

On Wed, Feb 26, 2025 at 03:31:03PM +0800, Huacai Chen wrote:
> On Wed, Feb 26, 2025 at 4:41 AM Kees Cook <kees@kernel.org> wrote:
> >
> > On Tue, Feb 25, 2025 at 07:35:13PM +0800, Huacai Chen wrote:
> > > 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
> >
> > 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.
> >
> > > 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

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/
[2] https://lore.kernel.org/loongarch/20250225111812.3065545-1-chenhuacai@loongson.cn/T/#u
[3] https://lore.kernel.org/linux-mm/CAAhV-H7i=WJmdFCCtY5DgE2eN657ddJwJwHGK1jgLKRte+VnEg@mail.gmail.com/T/#m6ca3bd9fd3fe519161f28715279d0dc371027506

> Huacai
> 
> >
> > --
> > Kees Cook

-- 
Cheers,
Harry


  reply	other threads:[~2025-02-27  2:52 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-12 14:16 [PATCH] mm/slab: Initialise random_kmalloc_seed after initcalls Huacai Chen
2025-02-12 15:39 ` Harry (Hyeonggon) Yoo
2025-02-13  3:20   ` Huacai Chen
2025-02-14  9:33     ` How does swsusp work with randomization features? (was: mm/slab: Initialise random_kmalloc_seed after initcalls) Harry (Hyeonggon) Yoo
2025-02-14 10:02       ` Huacai Chen
2025-02-14 12:44         ` Harry (Hyeonggon) Yoo
2025-02-15  9:53           ` Huacai Chen
2025-02-15 14:05             ` Harry (Hyeonggon) Yoo
2025-02-16  5:08               ` Huacai Chen
2025-02-19 14:10                 ` How does swsusp work with randomization features? Vlastimil Babka
2025-02-19 17:25           ` How does swsusp work with randomization features? (was: mm/slab: Initialise random_kmalloc_seed after initcalls) Kees Cook
2025-02-19 18:09             ` Rafael J. Wysocki
2025-02-25 11:35               ` Huacai Chen
2025-02-25 20:41                 ` Kees Cook
2025-02-26  7:31                   ` Huacai Chen
2025-02-27  2:50                     ` Harry Yoo [this message]
2025-02-18  9:33 ` [PATCH] mm/slab: Initialise random_kmalloc_seed after initcalls WangYuli

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=Z7_S__ExtqvNmD-3@harry \
    --to=harry.yoo@oracle.com \
    --cc=42.hyeyoo@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=chenhuacai@kernel.org \
    --cc=chenhuacai@loongson.cn \
    --cc=cl@linux.com \
    --cc=gongruiqi1@huawei.com \
    --cc=gongruiqi@huaweicloud.com \
    --cc=iamjoonsoo.kim@lge.com \
    --cc=kees@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-mm@kvack.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=pavel@kernel.org \
    --cc=penberg@kernel.org \
    --cc=rafael@kernel.org \
    --cc=rientjes@google.com \
    --cc=roman.gushchin@linux.dev \
    --cc=stable@vger.kernel.org \
    --cc=vbabka@suse.cz \
    --cc=wangyuli@uniontech.com \
    --cc=xiujianfeng@huawei.com \
    /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