{"id":"CVE-2026-138831","summary":"mm/shmem: report RCU-tasks quiescent states while undoing a range","details":"In the Linux kernel, the following vulnerability has been resolved:\n\nmm/shmem: report RCU-tasks quiescent states while undoing a range\n\nThis shows up in the Meta fleet on ftruncate() of large tmpfs files:\n\n  INFO: rcu_tasks detected stalls on tasks:\n  00000000752fd185: .. nvcsw: 59455/59455 holdout: 1 idle_cpu: -1/0\n  task:rocksdb:bottom  state:R  running task\n    __folio_split\n    find_get_entry\n    find_get_entries\n    truncate_inode_partial_folio\n    shmem_undo_range\n    shmem_setattr\n    notify_change\n    do_ftruncate\n    __x64_sys_ftruncate\n    do_syscall_64\n\nshmem_undo_range() walks the whole of the requested range in folio_batch\nsized steps, twice, and its two cond_resched() calls are the only\nreschedule points in that walk.\n\ncond_resched() is not an RCU-tasks quiescent state.  Use\ncond_resched_tasks_rcu_qs() at both points so the walk reports an\nRCU-tasks quiescent state as it proceeds.","modified":"2026-12-01T21:02:33.378910924Z","published":"2026-11-30T13:25:23.464Z","database_specific":{"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/138xxx/CVE-2026-138831.json","cna_assigner":"Linux"},"references":[{"type":"WEB","url":"https://git.kernel.org/stable/c/1aefb97c6663c120f8643f94963ea8d907569ca8"},{"type":"WEB","url":"https://git.kernel.org/stable/c/2edb293e97e7f64a75919e28075763c6241c489b"},{"type":"WEB","url":"https://git.kernel.org/stable/c/72d72aa2b437c9c4d9742c138ec65f3399ee4ae6"},{"type":"WEB","url":"https://git.kernel.org/stable/c/958a8aa3f1abc9b6bbe501d1c88ad324f9bbab32"},{"type":"WEB","url":"https://git.kernel.org/stable/c/96c426b253ebc77d46c817ace18c42b78e4c4d23"},{"type":"WEB","url":"https://git.kernel.org/stable/c/9f8f6a2df0f9d3ce5406e4003da62f0a56771536"},{"type":"WEB","url":"https://git.kernel.org/stable/c/b5b95b5176045583130799e05cdd6d00735536e9"},{"type":"WEB","url":"https://git.kernel.org/stable/c/ebd1a08c192109c83a87ddf42793ed6283180faf"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/138xxx/CVE-2026-138831.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-138831"},{"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":"8315f42295d2667a7f942f154b73a86fd7cb2227"},{"fixed":"1aefb97c6663c120f8643f94963ea8d907569ca8"},{"fixed":"72d72aa2b437c9c4d9742c138ec65f3399ee4ae6"},{"fixed":"958a8aa3f1abc9b6bbe501d1c88ad324f9bbab32"},{"fixed":"96c426b253ebc77d46c817ace18c42b78e4c4d23"},{"fixed":"2edb293e97e7f64a75919e28075763c6241c489b"},{"fixed":"b5b95b5176045583130799e05cdd6d00735536e9"},{"fixed":"9f8f6a2df0f9d3ce5406e4003da62f0a56771536"},{"fixed":"ebd1a08c192109c83a87ddf42793ed6283180faf"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-138831.json"}},{"package":{"name":"Kernel","ecosystem":"Linux"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.18.0"},{"fixed":"5.10.275"}]},{"type":"ECOSYSTEM","events":[{"introduced":"5.11.0"},{"fixed":"5.15.226"}]},{"type":"ECOSYSTEM","events":[{"introduced":"5.16.0"},{"fixed":"6.1.193"}]},{"type":"ECOSYSTEM","events":[{"introduced":"6.2.0"},{"fixed":"6.6.163"}]},{"type":"ECOSYSTEM","events":[{"introduced":"6.7.0"},{"fixed":"6.12.117"}]},{"type":"ECOSYSTEM","events":[{"introduced":"6.13.0"},{"fixed":"6.18.63"}]},{"type":"ECOSYSTEM","events":[{"introduced":"6.19.0"},{"fixed":"7.3.4"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-138831.json"}}],"schema_version":"1.9.2"}