{"id":"CVE-2026-89991","state":"PUBLISHED","title":"bpf: Fix infinite loop in pcpu_freelist push with one possible CPU","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf: Fix infinite loop in pcpu_freelist push with one possible CPU\n\n__pcpu_freelist_push() can loop forever when only one CPU is possible\nand an NMI re-enters pcpu_freelist_push() while the interrupted context\nholds that CPU's freelist lock.\n\nAfter the current-CPU fast path fails, the fallback loop walks\ncpu_possible_mask while skipping the current CPU. With CONFIG_SMP=n, or\nwhen an SMP kernel is limited to one possible CPU with nr_cpus=1 or\npossible_cpus=1, there are no other possible CPUs to examine. The loop\ntherefore makes no lock acquisition attempt and can never make progress.\n\nThe following stack was observed on a UP system:\n\n  NMI context:\n    pcpu_freelist_push\n    free_htab_elem\n    htab_map_delete_elem\n    [perf-event BPF program]\n    __perf_event_overflow\n    perf_event_nmi_handler\n    exc_nmi\n\n  Interrupted context:\n    __pcpu_freelist_push\n    pcpu_freelist_push\n    free_htab_elem\n    htab_map_delete_elem\n    [raw_tp/sys_enter BPF program]\n    __bpf_trace_sys_enter\n    do_syscall_64\n\nraw_res_spin_lock() detects the same-CPU recursive acquisition and\nreturns -EDEADLK, but the subsequent fallback loop has no candidate head\non a system with one possible CPU.\n\nRestore the extra fallback head that existed before the rqspinlock\nconversion. Keep the current-CPU fast path, then try the other possible\nCPUs and finally the extra head. The additional head lets a push, which\ncannot fail without losing a preallocated element, make progress when the\nonly per-CPU head is held by the interrupted context.\n\nAlso check the extra head from the pop path so that nodes placed there\ncan be reused.","publishedAt":"2026-09-16T10:33:05.097Z","updatedAt":"2026-10-19T08:56:05.536Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"f2ac0e5d1c4dcc55d6510dcaefb8f45661a9a1fb","status":"affected","lessThan":"a24a146ae2cb5d9faeea96d10010fcb6579abe1f","versionType":"git"},{"version":"f2ac0e5d1c4dcc55d6510dcaefb8f45661a9a1fb","status":"affected","lessThan":"a5b5e62baceff9e252c6535cf42a027d04f226cf","versionType":"git"},{"version":"f2ac0e5d1c4dcc55d6510dcaefb8f45661a9a1fb","status":"affected","lessThan":"efebf6496685c93150df5bb0794363ae70c5f58a","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/bpf/percpu_freelist.c","kernel/bpf/percpu_freelist.h"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.15","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.15","versionType":"semver"},{"version":"6.18.51","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.2.5","status":"unaffected","lessThanOrEqual":"7.2.*","versionType":"semver"},{"version":"7.3","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/bpf/percpu_freelist.c","kernel/bpf/percpu_freelist.h"]}],"references":["https://git.kernel.org/stable/c/a24a146ae2cb5d9faeea96d10010fcb6579abe1f","https://git.kernel.org/stable/c/a5b5e62baceff9e252c6535cf42a027d04f226cf","https://git.kernel.org/stable/c/efebf6496685c93150df5bb0794363ae70c5f58a"],"weaknesses":[],"ingestedAt":"2026-10-29T20:13:26.108Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/89xxx/CVE-2026-89991.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-89991","state":"PUBLISHED","datePublished":"2026-09-16T10:33:05.097Z","dateUpdated":"2026-10-19T08:56:05.536Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-09-11T19:38:34.780Z"},"containers":{"cna":{"title":"bpf: Fix infinite loop in pcpu_freelist push with one possible CPU","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf: Fix infinite loop in pcpu_freelist push with one possible CPU\n\n__pcpu_freelist_push() can loop forever when only one CPU is possible\nand an NMI re-enters pcpu_freelist_push() while the interrupted context\nholds that CPU's freelist lock.\n\nAfter the current-CPU fast path fails, the fallback loop walks\ncpu_possible_mask while skipping the current CPU. With CONFIG_SMP=n, or\nwhen an SMP kernel is limited to one possible CPU with nr_cpus=1 or\npossible_cpus=1, there are no other possible CPUs to examine. The loop\ntherefore makes no lock acquisition attempt and can never make progress.\n\nThe following stack was observed on a UP system:\n\n  NMI context:\n    pcpu_freelist_push\n    free_htab_elem\n    htab_map_delete_elem\n    [perf-event BPF program]\n    __perf_event_overflow\n    perf_event_nmi_handler\n    exc_nmi\n\n  Interrupted context:\n    __pcpu_freelist_push\n    pcpu_freelist_push\n    free_htab_elem\n    htab_map_delete_elem\n    [raw_tp/sys_enter BPF program]\n    __bpf_trace_sys_enter\n    do_syscall_64\n\nraw_res_spin_lock() detects the same-CPU recursive acquisition and\nreturns -EDEADLK, but the subsequent fallback loop has no candidate head\non a system with one possible CPU.\n\nRestore the extra fallback head that existed before the rqspinlock\nconversion. Keep the current-CPU fast path, then try the other possible\nCPUs and finally the extra head. The additional head lets a push, which\ncannot fail without losing a preallocated element, make progress when the\nonly per-CPU head is held by the interrupted context.\n\nAlso check the extra head from the pop path so that nodes placed there\ncan be reused."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"f2ac0e5d1c4dcc55d6510dcaefb8f45661a9a1fb","status":"affected","lessThan":"a24a146ae2cb5d9faeea96d10010fcb6579abe1f","versionType":"git"},{"version":"f2ac0e5d1c4dcc55d6510dcaefb8f45661a9a1fb","status":"affected","lessThan":"a5b5e62baceff9e252c6535cf42a027d04f226cf","versionType":"git"},{"version":"f2ac0e5d1c4dcc55d6510dcaefb8f45661a9a1fb","status":"affected","lessThan":"efebf6496685c93150df5bb0794363ae70c5f58a","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/bpf/percpu_freelist.c","kernel/bpf/percpu_freelist.h"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.15","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.15","versionType":"semver"},{"version":"6.18.51","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.2.5","status":"unaffected","lessThanOrEqual":"7.2.*","versionType":"semver"},{"version":"7.3","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/bpf/percpu_freelist.c","kernel/bpf/percpu_freelist.h"]}],"references":[{"url":"https://git.kernel.org/stable/c/a24a146ae2cb5d9faeea96d10010fcb6579abe1f"},{"url":"https://git.kernel.org/stable/c/a5b5e62baceff9e252c6535cf42a027d04f226cf"},{"url":"https://git.kernel.org/stable/c/efebf6496685c93150df5bb0794363ae70c5f58a"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-10-19T08:56:05.536Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.15","versionEndExcluding":"6.18.51"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.15","versionEndExcluding":"7.2.5"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.15","versionEndExcluding":"7.3"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}