{"document":{"category":"csaf_vex","csaf_version":"2.0","title":"CVE-2026-46280: lib: test_hmm: evict device pages on file close to avoid use-after-free","publisher":{"category":"vendor","name":"HarborGuard Database","namespace":"https://database.harborguard.co"},"tracking":{"id":"CVE-2026-46280","status":"final","version":"1","initial_release_date":"2026-06-08T15:41:23.095Z","current_release_date":"2026-06-14T04:29:58.926Z","revision_history":[{"date":"2026-06-08T15:41:23.095Z","number":"1","summary":"Initial machine-readable export from HarborGuard."}]},"distribution":{"tlp":{"label":"WHITE"},"text":"Public CVE data; freely redistributable."},"notes":[{"category":"description","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nlib: test_hmm: evict device pages on file close to avoid use-after-free\n\nPatch series \"Minor hmm_test fixes and cleanups\".\n\nTwo bugfixes a cleanup for the HMM kernel selftests.  These were mostly\nreported by Zenghui Yu with special thanks to Lorenzo for analysing and\npointing out the problems.\n\n\nThis patch (of 3):\n\nWhen dmirror_fops_release() is called it frees the dmirror struct but\ndoesn't migrate device private pages back to system memory first.  This\nleaves those pages with a dangling zone_device_data pointer to the freed\ndmirror.\n\nIf a subsequent fault occurs on those pages (eg.  during coredump) the\ndmirror_devmem_fault() callback dereferences the stale pointer causing a\nkernel panic.  This was reported [1] when running mm/ksft_hmm.sh on arm64,\nwhere a test failure triggered SIGABRT and the resulting coredump walked\nthe VMAs faulting in the stale device private pages.\n\nFix this by calling dmirror_device_evict_chunk() for each devmem chunk in\ndmirror_fops_release() to migrate all device private pages back to system\nmemory before freeing the dmirror struct.  The function is moved earlier\nin the file to avoid a forward declaration.","title":"CVE description"}],"references":[{"category":"self","summary":"CVE-2026-46280 on HarborGuard Database","url":"https://database.harborguard.co/cve/CVE-2026-46280"},{"category":"external","summary":"CVE Record","url":"https://www.cve.org/CVERecord?id=CVE-2026-46280"},{"category":"external","summary":"git.kernel.org","url":"https://git.kernel.org/stable/c/bf477abd448c76bb8ea51c9b4f63a3a17c4b6239"},{"category":"external","summary":"git.kernel.org","url":"https://git.kernel.org/stable/c/5846715b6382dd4c6a69b35a56ca6115d33bc2a0"},{"category":"external","summary":"git.kernel.org","url":"https://git.kernel.org/stable/c/38f113f81d3f0adc658a4475dd3ecaec985e21d3"},{"category":"external","summary":"git.kernel.org","url":"https://git.kernel.org/stable/c/9de1eb0aac2862d6144b8db0ec1388e79f8bc3e1"},{"category":"external","summary":"git.kernel.org","url":"https://git.kernel.org/stable/c/744dd97752ef1076a8d8672bb0d8aa2c7abc1144"}]},"product_tree":{"branches":[{"category":"vendor","name":"Linux","branches":[{"category":"product_name","name":"Linux","branches":[{"category":"product_version_range","name":">=b2ef9f5a5cb37643ca5def3516c546457074b882 <bf477abd448c76bb8ea51c9b4f63a3a17c4b6239","product":{"name":"Linux Linux >=b2ef9f5a5cb37643ca5def3516c546457074b882 <bf477abd448c76bb8ea51c9b4f63a3a17c4b6239","product_id":"CSAFPID-1","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:*:*:*:*:*:*:*:*"}}},{"category":"product_version_range","name":">=b2ef9f5a5cb37643ca5def3516c546457074b882 <5846715b6382dd4c6a69b35a56ca6115d33bc2a0","product":{"name":"Linux Linux >=b2ef9f5a5cb37643ca5def3516c546457074b882 <5846715b6382dd4c6a69b35a56ca6115d33bc2a0","product_id":"CSAFPID-2","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:*:*:*:*:*:*:*:*"}}},{"category":"product_version_range","name":">=b2ef9f5a5cb37643ca5def3516c546457074b882 <38f113f81d3f0adc658a4475dd3ecaec985e21d3","product":{"name":"Linux Linux >=b2ef9f5a5cb37643ca5def3516c546457074b882 <38f113f81d3f0adc658a4475dd3ecaec985e21d3","product_id":"CSAFPID-3","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:*:*:*:*:*:*:*:*"}}},{"category":"product_version_range","name":">=b2ef9f5a5cb37643ca5def3516c546457074b882 <9de1eb0aac2862d6144b8db0ec1388e79f8bc3e1","product":{"name":"Linux Linux >=b2ef9f5a5cb37643ca5def3516c546457074b882 <9de1eb0aac2862d6144b8db0ec1388e79f8bc3e1","product_id":"CSAFPID-4","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:*:*:*:*:*:*:*:*"}}},{"category":"product_version_range","name":">=b2ef9f5a5cb37643ca5def3516c546457074b882 <744dd97752ef1076a8d8672bb0d8aa2c7abc1144","product":{"name":"Linux Linux >=b2ef9f5a5cb37643ca5def3516c546457074b882 <744dd97752ef1076a8d8672bb0d8aa2c7abc1144","product_id":"CSAFPID-5","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:*:*:*:*:*:*:*:*"}}}]}]},{"category":"vendor","name":"Linux","branches":[{"category":"product_name","name":"Linux","branches":[{"category":"product_version","name":"5.8","product":{"name":"Linux Linux 5.8","product_id":"CSAFPID-6","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:5.8:*:*:*:*:*:*:*"}}},{"category":"product_version","name":"0","product":{"name":"Linux Linux 0","product_id":"CSAFPID-7","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:5.8:*:*:*:*:*:*:*"}}},{"category":"product_version","name":"6.6.140","product":{"name":"Linux Linux 6.6.140","product_id":"CSAFPID-8","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:5.8:*:*:*:*:*:*:*"}}},{"category":"product_version","name":"6.12.86","product":{"name":"Linux Linux 6.12.86","product_id":"CSAFPID-9","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:5.8:*:*:*:*:*:*:*"}}},{"category":"product_version","name":"6.18.27","product":{"name":"Linux Linux 6.18.27","product_id":"CSAFPID-10","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:5.8:*:*:*:*:*:*:*"}}},{"category":"product_version","name":"7.0.4","product":{"name":"Linux Linux 7.0.4","product_id":"CSAFPID-11","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:5.8:*:*:*:*:*:*:*"}}},{"category":"product_version","name":"7.1-rc1","product":{"name":"Linux Linux 7.1-rc1","product_id":"CSAFPID-12","product_identification_helper":{"cpe":"cpe:2.3:a:linux:linux:5.8:*:*:*:*:*:*:*"}}}]}]}]},"vulnerabilities":[{"cve":"CVE-2026-46280","title":"lib: test_hmm: evict device pages on file close to avoid use-after-free","notes":[{"category":"description","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nlib: test_hmm: evict device pages on file close to avoid use-after-free\n\nPatch series \"Minor hmm_test fixes and cleanups\".\n\nTwo bugfixes a cleanup for the HMM kernel selftests.  These were mostly\nreported by Zenghui Yu with special thanks to Lorenzo for analysing and\npointing out the problems.\n\n\nThis patch (of 3):\n\nWhen dmirror_fops_release() is called it frees the dmirror struct but\ndoesn't migrate device private pages back to system memory first.  This\nleaves those pages with a dangling zone_device_data pointer to the freed\ndmirror.\n\nIf a subsequent fault occurs on those pages (eg.  during coredump) the\ndmirror_devmem_fault() callback dereferences the stale pointer causing a\nkernel panic.  This was reported [1] when running mm/ksft_hmm.sh on arm64,\nwhere a test failure triggered SIGABRT and the resulting coredump walked\nthe VMAs faulting in the stale device private pages.\n\nFix this by calling dmirror_device_evict_chunk() for each devmem chunk in\ndmirror_fops_release() to migrate all device private pages back to system\nmemory before freeing the dmirror struct.  The function is moved earlier\nin the file to avoid a forward declaration.","title":"CVE description"}],"product_status":{"known_affected":["CSAFPID-1","CSAFPID-2","CSAFPID-3","CSAFPID-4","CSAFPID-5","CSAFPID-6"],"fixed":["CSAFPID-7","CSAFPID-8","CSAFPID-9","CSAFPID-10","CSAFPID-11","CSAFPID-12"]},"scores":[{"cvss_v3":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","baseScore":7.8,"baseSeverity":"HIGH"},"products":["CSAFPID-1","CSAFPID-2","CSAFPID-3","CSAFPID-4","CSAFPID-5","CSAFPID-6"]}],"remediations":[{"category":"vendor_fix","details":"Update to a fixed version: 0, 38f113f81d3f0adc658a4475dd3ecaec985e21d3, 5846715b6382dd4c6a69b35a56ca6115d33bc2a0, 6.6.140, 6.12.86, 6.18.27, 7.0.4, 7.1-rc1, 744dd97752ef1076a8d8672bb0d8aa2c7abc1144, 9de1eb0aac2862d6144b8db0ec1388e79f8bc3e1, bf477abd448c76bb8ea51c9b4f63a3a17c4b6239.","product_ids":["CSAFPID-1","CSAFPID-2","CSAFPID-3","CSAFPID-4","CSAFPID-5","CSAFPID-6"]}]}]}