From: Heiko Carstens Date: Tue, 11 Mar 2025 12:33:25 +0000 (+0100) Subject: mseal sysmap: generic vdso vvar mapping X-Git-Tag: v6.15-rc1~38^2~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1d6fad7b844cffc85024a362fdcc3bef696dfe2e;p=thirdparty%2Fkernel%2Flinux.git mseal sysmap: generic vdso vvar mapping 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@google.com [2] https://lkml.kernel.org/r/20250305021711.3867874-5-jeffxu@google.com Link: https://lkml.kernel.org/r/20250311123326.2686682-2-hca@linux.ibm.com Signed-off-by: Heiko Carstens Reviewed-by: Lorenzo Stoakes Cc: Alexander Gordeev Cc: Christian Borntraeger Cc: Jeff Xu Cc: Liam Howlett Cc: Sven Schnelle Cc: Thomas Weißschuh Cc: Vasily Gorbik Signed-off-by: Andrew Morton --- diff --git a/lib/vdso/datastore.c b/lib/vdso/datastore.c index c715e217ec657..3693c6caf2c4d 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); }