CVE-2025-37893

LoongArch: BPF: Fix off-by-one error in build_prologue()

MEDIUM
5.5
CVSS Score
Published: April 18, 2025 at 07:01 AM UTC
Updated: August 5, 2026 at 12:44 PM UTC
1 product affected across 1 vendorLinux Kernel

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM5.5
Exploit prediction
EPSS 0.3%
SSVC
No known exploit

Description

In the Linux kernel, the following vulnerability has been resolved: LoongArch: BPF: Fix off-by-one error in build_prologue() Vincent reported that running BPF progs with tailcalls on LoongArch causes kernel hard lockup. Debugging the issues shows that the JITed image missing a jirl instruction at the end of the epilogue. There are two passes in JIT compiling, the first pass set the flags and the second pass generates JIT code based on those flags. With BPF progs mixing bpf2bpf and tailcalls, build_prologue() generates N insns in the first pass and then generates N+1 insns in the second pass. This makes epilogue_offset off by one and we will jump to some unexpected insn and cause lockup. Fix this by inserting a nop insn.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

6.1 ≤ v < 6.1.1346.1 ≤ v < 6.12.236.1 ≤ v < 6.13.116.1 ≤ v < 6.14.26.1 ≤ v < 6.156.1 ≤ v < 6.6.876.13 ≤ v < 6.13.116.14 ≤ v < 6.14.26.2 ≤ v < 6.6.876.7 ≤ v < 6.12.235dc615520c4dfb358245680f1904bad61116648e6.1
Vendor states this is fixed in 205a2182c51ffebaef54d643e3745e720cded08b (fixed)
Vendor states this is fixed in 48b904de2408af5f936f0e03f48dfcddeab58aa0 (fixed)
Vendor states this is fixed in 7e2586991e36663c9bc48c828b83eab180ad30a9 (fixed)
Vendor states this is fixed in b3ffad2f02db4aace6799fe0049508b8925eae45 (fixed)
Vendor states this is fixed in c74d95a5679741ef428974ab788f5b0758dc78ae (fixed)
Vendor states this is fixed in 6.1 (unaffected)
Affected range stops below 6.1.134, so it looks safe — our inference, not a vendor statement
Vendor states this is fixed in 6.12.23 (unaffected)
Vendor states this is fixed in 6.13.11 (unaffected)
Vendor states this is fixed in 6.14.2 (unaffected)
Vendor states this is fixed in 6.15 (unaffected)
Vendor states this is fixed in 6.6.87 (unaffected)

References (5)

Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/205a2182c51ffebaef54d643e3745e720cded08b
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/48b904de2408af5f936f0e03f48dfcddeab58aa0
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/7e2586991e36663c9bc48c828b83eab180ad30a9
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/b3ffad2f02db4aace6799fe0049508b8925eae45
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/c74d95a5679741ef428974ab788f5b0758dc78ae

SSVC — Action Prioritization

SSVCNo known exploitNot automatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

5.5MEDIUMCISA-ADP
Attack Vector
LOCAL
Complexity
LOW
Privileges
LOW
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-193

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card