[RFC PATCH 03/36] arm64: hibernate: mask DAIF before restoring hibernated kernel
Vladimir Murzin
vladimir.murzin at arm.com
Tue Jul 14 02:09:06 PDT 2026
On 7/9/26 14:19, Jinjie Ruan wrote:
>
> On 7/9/2026 8:13 PM, Vladimir Murzin wrote:
>> From: Ada Couprie Diaz <ada.coupriediaz at arm.com>
>>
>> The arm64 hibernate code manages the exception masking in an unsound
>> way, leading to potential crashes and/or warnings during resume.
>>
>> When a hibernation image is saved in `swsusp_arch_suspend()`, all DAIF
>> exceptions are masked (by virtue of `local_daif_save()`), and the
>> suspended image is saved assuming that all DAIF exceptions will remain
>> masked when the image is restored.
>>
>> When a hibernation image is resumed by `swsusp_arch_resume()`, only
>> interrupts are masked (by virtue of `local_irq_save()` in
> local_irq_disable()?
Sorry, yes it should be local_irq_disable(). I'll fix that in next iteration.
Cheers
Vladimir
More information about the linux-arm-kernel
mailing list