{"id":"CVE-2025-40311","aliases":["CVE-2025-40311"],"related":[],"kind":"vulnerability","state":"published","title":"accel/habanalabs: support mapping cb with vmalloc-backed coherent memory","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\naccel/habanalabs: support mapping cb with vmalloc-backed coherent memory\n\nWhen IOMMU is enabled, dma_alloc_coherent() with GFP_USER may return\naddresses from the vmalloc range. If such an address is mapped without\nVM_MIXEDMAP, vm_insert_page() will trigger a BUG_ON due to the\nVM_PFNMAP restriction.\n\nFix this by checking for vmalloc addresses and setting VM_MIXEDMAP\nin the VMA before mapping. This ensures safe mapping and avoids kernel\ncrashes. The memory is still driver-allocated and cannot be accessed\ndirectly by userspace.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\naccel/habanalabs: support mapping cb with vmalloc-backed coherent memory\n\nWhen IOMMU is enabled, dma_alloc_coherent() with GFP_USER may return\naddresses from the vmalloc range. If such an address is mapped without\nVM_MIXEDMAP, vm_insert_page() will trigger a BUG_ON due to the\nVM_PFNMAP restriction.\n\nFix this by checking for vmalloc addresses and setting VM_MIXEDMAP\nin the VMA before mapping. This ensures safe mapping and avoids kernel\ncrashes. The memory is still driver-allocated and cannot be accessed\ndirectly by userspace.","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\naccel/habanalabs: soporte para mapear cb con memoria coherente respaldada por vmalloc\n\nCuando IOMMU está habilitado, dma_alloc_coherent() con GFP_USER puede devolver direcciones del rango de vmalloc. Si dicha dirección se mapea sin VM_MIXEDMAP, vm_insert_page() activará un BUG_ON debido a la restricción de VM_PFNMAP.\n\nSolucione esto verificando las direcciones de vmalloc y configurando VM_MIXEDMAP en el VMA antes del mapeo. Esto asegura un mapeo seguro y evita fallos del kernel. La memoria sigue siendo asignada por el controlador y no puede ser accedida directamente por el espacio de usuario.","source":"nvd"}],"published":"2025-12-08T00:46:36.903Z","modified":"2026-10-30T13:18:15.057Z","severities":[],"cwes":[],"affected":[{"ranges":[{"type":"git","introduced":"ac0ae6a96aa58eeba4aed97b12ef1dea8c5bf399","fixed":"8de421db5b1b2b37e9643ea7f6ade90fd756892d","status":"affected"},{"type":"git","introduced":"ac0ae6a96aa58eeba4aed97b12ef1dea8c5bf399","fixed":"7ec8ac9f73d4a9438c2186768d6de27ace37531e","status":"affected"},{"type":"git","introduced":"ac0ae6a96aa58eeba4aed97b12ef1dea8c5bf399","fixed":"d1dfe21a332d38a6a09658ec29a55940afb5fe36","status":"affected"},{"type":"git","introduced":"ac0ae6a96aa58eeba4aed97b12ef1dea8c5bf399","fixed":"73c7c2cdb442fc4160d2a2a4bfffbd162af06cb9","status":"affected"},{"type":"git","introduced":"ac0ae6a96aa58eeba4aed97b12ef1dea8c5bf399","fixed":"513024d5a0e34fd34247043f1876b6138ca52847","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"5.8","status":"affected"},{"type":"semver","introduced":"0","fixed":"5.8","status":"unaffected"},{"type":"semver","introduced":"6.1.191","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.117","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.58","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.17.8","lastAffected":"6.17.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.18","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"}],"references":[{"url":"https://git.kernel.org/stable/c/8de421db5b1b2b37e9643ea7f6ade90fd756892d","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/7ec8ac9f73d4a9438c2186768d6de27ace37531e","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/d1dfe21a332d38a6a09658ec29a55940afb5fe36","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/73c7c2cdb442fc4160d2a2a4bfffbd162af06cb9","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/513024d5a0e34fd34247043f1876b6138ca52847","tags":[],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-40311","url":"https://www.cve.org/CVERecord?id=CVE-2025-40311","licence":"CVE Terms of Use","modified":"2026-10-30T12:22:59.945Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-40311","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-40311","licence":"Public domain","modified":"2026-10-30T13:18:15.057Z"}],"updatedAt":"2026-11-25T22:59:08.399Z","epss":{"score":0.00207,"percentile":0.11365,"date":"2026-12-01T12:00:22.000Z"}}