{"id":"CVE-2025-21919","summary":"sched/fair: Fix potential memory corruption in child_cfs_rq_on_list","details":"In the Linux kernel, the following vulnerability has been resolved:\n\nsched/fair: Fix potential memory corruption in child_cfs_rq_on_list\n\nchild_cfs_rq_on_list attempts to convert a 'prev' pointer to a cfs_rq.\nThis 'prev' pointer can originate from struct rq's leaf_cfs_rq_list,\nmaking the conversion invalid and potentially leading to memory\ncorruption. Depending on the relative positions of leaf_cfs_rq_list and\nthe task group (tg) pointer within the struct, this can cause a memory\nfault or access garbage data.\n\nThe issue arises in list_add_leaf_cfs_rq, where both\ncfs_rq-\u003eleaf_cfs_rq_list and rq-\u003eleaf_cfs_rq_list are added to the same\nleaf list. Also, rq-\u003etmp_alone_branch can be set to rq-\u003eleaf_cfs_rq_list.\n\nThis adds a check `if (prev == &rq-\u003eleaf_cfs_rq_list)` after the main\nconditional in child_cfs_rq_on_list. This ensures that the container_of\noperation will convert a correct cfs_rq struct.\n\nThis check is sufficient because only cfs_rqs on the same CPU are added\nto the list, so verifying the 'prev' pointer against the current rq's list\nhead is enough.\n\nFixes a potential memory corruption issue that due to current struct\nlayout might not be manifesting as a crash but could lead to unpredictable\nbehavior when the layout changes.","modified":"2026-04-02T12:45:17.253533Z","published":"2025-04-01T15:40:54.075Z","related":["ALSA-2025:11850","ALSA-2025:11851","ALSA-2025:9302","SUSE-SU-2025:01919-1","SUSE-SU-2025:01951-1","SUSE-SU-2025:01964-1","SUSE-SU-2025:01965-1","SUSE-SU-2025:01967-1","SUSE-SU-2025:01972-1","SUSE-SU-2025:02000-1","SUSE-SU-2025:20408-1","SUSE-SU-2025:20413-1","SUSE-SU-2025:20419-1","SUSE-SU-2025:20421-1"],"database_specific":{"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/21xxx/CVE-2025-21919.json","cna_assigner":"Linux"},"references":[{"type":"WEB","url":"https://git.kernel.org/stable/c/000c9ee43928f2ce68a156dd40bab7616256f4dd"},{"type":"WEB","url":"https://git.kernel.org/stable/c/3b4035ddbfc8e4521f85569998a7569668cccf51"},{"type":"WEB","url":"https://git.kernel.org/stable/c/5cb300dcdd27e6a351ac02541e0231261c775852"},{"type":"WEB","url":"https://git.kernel.org/stable/c/9cc7f0018609f75a349e42e3aebc3b0e905ba775"},{"type":"WEB","url":"https://git.kernel.org/stable/c/b5741e4b9ef3567613b2351384f91d3f16e59986"},{"type":"WEB","url":"https://git.kernel.org/stable/c/e1dd09df30ba86716cb2ffab97dc35195c01eb8f"},{"type":"WEB","url":"https://lists.debian.org/debian-lts-announce/2025/05/msg00045.html"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/21xxx/CVE-2025-21919.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-21919"},{"type":"PACKAGE","url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"fdaba61ef8a268d4136d0a113d153f7a89eb9984"},{"fixed":"5cb300dcdd27e6a351ac02541e0231261c775852"},{"fixed":"000c9ee43928f2ce68a156dd40bab7616256f4dd"},{"fixed":"9cc7f0018609f75a349e42e3aebc3b0e905ba775"},{"fixed":"b5741e4b9ef3567613b2351384f91d3f16e59986"},{"fixed":"e1dd09df30ba86716cb2ffab97dc35195c01eb8f"},{"fixed":"3b4035ddbfc8e4521f85569998a7569668cccf51"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-21919.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"}]}