Re: [PATCH mm-unstable 1/2] mseal sysmap: generic vdso vvar mapping

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Mar 11, 2025 at 01:33:25PM +0100, Heiko Carstens wrote:
> With the introduction of the generic vdso data storage the VM_SEALED_SYSMAP
> vm flag must be moved from the architecture specific
> _install_special_mapping() call [1] [2] which maps the vvar mapping to
> generic code.
>
> [1] https://lkml.kernel.org/r/20250305021711.3867874-4-jeffxu@xxxxxxxxxx
> [2] https://lkml.kernel.org/r/20250305021711.3867874-5-jeffxu@xxxxxxxxxx
>
> Signed-off-by: Heiko Carstens <hca@xxxxxxxxxxxxx>

Since CONFIG_MSEAL_SYSTEM_MAPPINGS this relies upon
ARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGS, this is safe to do in generic code
(otherwise VM_SEALED_SYSMAP is VM_NONE).

So all good and:

Reviewed-by: Lorenzo Stoakes <lorenzo.stoakes@xxxxxxxxxx>

> ---
>  lib/vdso/datastore.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/lib/vdso/datastore.c b/lib/vdso/datastore.c
> index e227fbbcb796..b7c7386c98a9 100644
> --- a/lib/vdso/datastore.c
> +++ b/lib/vdso/datastore.c
> @@ -99,7 +99,8 @@ const struct vm_special_mapping vdso_vvar_mapping = {
>  struct vm_area_struct *vdso_install_vvar_mapping(struct mm_struct *mm, unsigned long addr)
>  {
>  	return _install_special_mapping(mm, addr, VDSO_NR_PAGES * PAGE_SIZE,
> -					VM_READ | VM_MAYREAD | VM_IO | VM_DONTDUMP | VM_PFNMAP,
> +					VM_READ | VM_MAYREAD | VM_IO | VM_DONTDUMP |
> +					VM_PFNMAP | VM_SEALED_SYSMAP,
>  					&vdso_vvar_mapping);
>  }
>
> --
> 2.45.2
>




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux