{"id":"CVE-2025-39910","aliases":["CVE-2025-39910"],"related":[],"kind":"vulnerability","state":"published","title":"mm/vmalloc, mm/kasan: respect gfp mask in kasan_populate_vmalloc()","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nmm/vmalloc, mm/kasan: respect gfp mask in kasan_populate_vmalloc()\n\nkasan_populate_vmalloc() and its helpers ignore the caller's gfp_mask and\nalways allocate memory using the hardcoded GFP_KERNEL flag.  This makes\nthem inconsistent with vmalloc(), which was recently extended to support\nGFP_NOFS and GFP_NOIO allocations.\n\nPage table allocations performed during shadow population also ignore the\nexternal gfp_mask.  To preserve the intended semantics of GFP_NOFS and\nGFP_NOIO, wrap the apply_to_page_range() calls into the appropriate\nmemalloc scope.\n\nxfs calls vmalloc with GFP_NOFS, so this bug could lead to deadlock.\n\nThere was a report here\nhttps://lkml.kernel.org/r/686ea951.050a0220.385921.0016.GAE@google.com\n\nThis patch:\n - Extends kasan_populate_vmalloc() and helpers to take gfp_mask;\n - Passes gfp_mask down to alloc_pages_bulk() and __get_free_page();\n - Enforces GFP_NOFS/NOIO semantics with memalloc_*_save()/restore()\n   around apply_to_page_range();\n - Updates vmalloc.c and percpu allocator call sites accordingly.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nmm/vmalloc, mm/kasan: respect gfp mask in kasan_populate_vmalloc()\n\nkasan_populate_vmalloc() and its helpers ignore the caller's gfp_mask and\nalways allocate memory using the hardcoded GFP_KERNEL flag.  This makes\nthem inconsistent with vmalloc(), which was recently extended to support\nGFP_NOFS and GFP_NOIO allocations.\n\nPage table allocations performed during shadow population also ignore the\nexternal gfp_mask.  To preserve the intended semantics of GFP_NOFS and\nGFP_NOIO, wrap the apply_to_page_range() calls into the appropriate\nmemalloc scope.\n\nxfs calls vmalloc with GFP_NOFS, so this bug could lead to deadlock.\n\nThere was a report here\nhttps://lkml.kernel.org/r/686ea951.050a0220.385921.0016.GAE@google.com\n\nThis patch:\n - Extends kasan_populate_vmalloc() and helpers to take gfp_mask;\n - Passes gfp_mask down to alloc_pages_bulk() and __get_free_page();\n - Enforces GFP_NOFS/NOIO semantics with memalloc_*_save()/restore()\n   around apply_to_page_range();\n - Updates vmalloc.c and percpu allocator call sites accordingly.","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\nmm/vmalloc, mm/kasan: respetar la máscara gfp en kasan_populate_vmalloc()\n\nkasan_populate_vmalloc() y sus funciones auxiliares ignoran la gfp_mask del llamador y siempre asignan memoria utilizando la bandera GFP_KERNEL codificada. Esto los hace inconsistentes con vmalloc(), que fue extendida recientemente para soportar asignaciones GFP_NOFS y GFP_NOIO.\n\nLas asignaciones de tablas de páginas realizadas durante la población de sombra también ignoran la gfp_mask externa. Para preservar la semántica prevista de GFP_NOFS y GFP_NOIO, envuelva las llamadas a apply_to_page_range() dentro del ámbito memalloc apropiado.\n\nxfs llama a vmalloc con GFP_NOFS, por lo que este error podría llevar a un interbloqueo.\n\nHubo un informe aquí https://lkml.kernel.org/r/686ea951.050a0220.385921.0016.GAE@google.com\n\nEste parche:\n - Extiende kasan_populate_vmalloc() y sus funciones auxiliares para que acepten gfp_mask;\n - Pasa gfp_mask a alloc_pages_bulk() y __get_free_page();\n - Aplica la semántica de GFP_NOFS/NOIO con memalloc_*_save()/restore() alrededor de apply_to_page_range();\n - Actualiza los sitios de llamada del asignador vmalloc.c y percpu en consecuencia.","source":"nvd"}],"published":"2025-10-01T07:44:33.759Z","modified":"2026-10-30T13:18:11.187Z","severity":{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"}],"cwes":["CWE-667"],"affected":[{"ranges":[{"type":"git","introduced":"451769ebb7e792c3404db53b3c2a422990de654e","fixed":"c136f2e4f2edd58a62a3425d4dd373d82834d1f9","status":"affected"},{"type":"git","introduced":"451769ebb7e792c3404db53b3c2a422990de654e","fixed":"9598c83a50a5f9d57fd0c12fc08d9425c1ce9537","status":"affected"},{"type":"git","introduced":"451769ebb7e792c3404db53b3c2a422990de654e","fixed":"aa1b4b7a1b92743297f9da741424df4703a8e11b","status":"affected"},{"type":"git","introduced":"451769ebb7e792c3404db53b3c2a422990de654e","fixed":"33b95d90427cb4babf32059e323a6d0c027610fe","status":"affected"},{"type":"git","introduced":"451769ebb7e792c3404db53b3c2a422990de654e","fixed":"79357cd06d41d0f5a11b17d7c86176e395d10ef2","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"5.17","status":"affected"},{"type":"semver","introduced":"0","fixed":"5.17","status":"unaffected"},{"type":"semver","introduced":"6.1.191","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.160","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.114","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.16.8","lastAffected":"6.16.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.17","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"5.17","fixed":"6.16.8"},{"status":"affected","version":"6.17"},{"status":"affected","version":"6.17"},{"status":"affected","version":"6.17"},{"status":"affected","version":"6.17"},{"status":"affected","version":"6.17"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/c136f2e4f2edd58a62a3425d4dd373d82834d1f9","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/9598c83a50a5f9d57fd0c12fc08d9425c1ce9537","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/aa1b4b7a1b92743297f9da741424df4703a8e11b","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/33b95d90427cb4babf32059e323a6d0c027610fe","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/79357cd06d41d0f5a11b17d7c86176e395d10ef2","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-01-14T17:42:43.252Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-39910","url":"https://www.cve.org/CVERecord?id=CVE-2025-39910","licence":"CVE Terms of Use","modified":"2026-10-30T12:22:36.341Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-39910","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-39910","licence":"Public domain","modified":"2026-10-30T13:18:11.187Z"}],"updatedAt":"2026-11-25T22:59:05.388Z","epss":{"score":0.00157,"percentile":0.05077,"date":"2026-12-01T12:00:22.000Z"}}