Re: [PATCH v20 7/9] arm64: Block hibernate and kexec while RMM is active

From: Jonathan Cameron

Date: Wed Sep 30 2026 - 13:25:47 EST


On Tue, 29 Sep 2026 23:16:21 +0100
Suzuki K Poulose <suzuki.poulose@xxxxxxx> wrote:

> RMM can be deactivated only after all delegated granules have been
> reclaimed. If a new kernel is entered while any granules remain in the
> Realm PAS, accesses to that memory can raise a Granule Protection Fault
> and be fatal to the new kernel.
>
> Crash kexec/kdump needs separate handling. It can be supported only once
> the crash kernel can tolerate delegated memory inherited from the primary
> kernel. i.e., be able to read the pages safely and fixup the GPF. Until
> then disable the kexec completely.
>
> Hibernate has a similar problem. The image cannot be safely saved for
> delegated pages, as the RMM doesn't support exporting the pages.
>
> Disable both kexec and hiberation while the RMM is active.
>
> Signed-off-by: Suzuki K Poulose <suzuki.poulose@xxxxxxx>
Not my area of expertise but follows similar patterns to blocking these
for other reasons.

Reviewed-by: Jonathan Cameron <jonathan.cameron@xxxxxxxxxxxxxxxx>