Re: [PATCH v2 2/4] s390/mm: Fix handling of secure storage access exceptions in vmalloc area
From: Alexander Gordeev
Date: Fri Jul 24 2026 - 05:02:10 EST
On Fri, Jul 17, 2026 at 11:24:13AM +0200, Heiko Carstens wrote:
> Secure storage access exceptions in vmalloc area need to be handled
> separately since folio_try_get() or virt_to_phys() do not work on such
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
virt_to_phys() is not called here directly while folio_try_get() does
not accept the addr parameter. Did you mean just virt_to_folio() or do
you imply something outside of the context of this patch?
> addresses. Given that there cannot be a valid access let such exceptions
> fail immediately. The kernel will either fixup or crash.
>
> Signed-off-by: Heiko Carstens <hca@xxxxxxxxxxxxx>
> ---
> arch/s390/mm/fault.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/arch/s390/mm/fault.c b/arch/s390/mm/fault.c
> index 028aeb9c48d6..392e46742039 100644
> --- a/arch/s390/mm/fault.c
> +++ b/arch/s390/mm/fault.c
> @@ -438,6 +438,8 @@ void do_secure_storage_access(struct pt_regs *regs)
> panic("Unexpected PGM 0x3d with TEID bit 61=0");
> }
> if (is_kernel_fault(regs)) {
> + if (is_vmalloc_addr((void *)addr))
> + return handle_fault_error_nolock(regs, 0);
> folio = virt_to_folio((void *)addr);
> if (unlikely(!folio_try_get(folio)))
> return;
> --
> 2.53.0
>
>