Skip to main content
Network Thinking Solutions Logo

CVE-2024-40925

In the Linux kernel, the following vulnerability has been resolved: block: fix request.

All CVEs
CVE-2024-40925Published 7/12/2024

In the Linux kernel, the following vulnerability has been resolved: block: fix request.

Vendor advisory
CVSS7.8High

Overview

In the Linux kernel, the following vulnerability has been resolved: block: fix request.queuelist usage in flush Friedrich Weber reported a kernel crash problem and bisected to commit 81ada09cc25e ("blk-flush: reuse rq queuelist in flush state machine"). The root cause is that we use "list_move_tail(&rq->queuelist, pending)" in the PREFLUSH/POSTFLUSH sequences. But rq->queuelist.next == xxx since it's popped out from plug->cached_rq in __blk_mq_alloc_requests_batch(). We don't initialize its queuelist just for this first request, although the queuelist of all later popped requests will be initialized. Fix it by changing to use "list_add_tail(&rq->queuelist, pending)" so rq->queuelist doesn't need to be initialized. It should be ok since rq can't be on any list when PREFLUSH or POSTFLUSH, has no move actually. Please note the commit 81ada09cc25e ("blk-flush: reuse rq queuelist in flush state machine") also has another requirement that no drivers would touch rq->queuelist after blk_mq_end_request() since we will reuse it to add rq to the post-flush pending list in POSTFLUSH. If this is not true, we will have to revert that commit IMHO. This updated version adds "list_del_init(&rq->queuelist)" in flush rq callback since the dm layer may submit request of a weird invalid format (REQ_FSEQ_PREFLUSH | REQ_FSEQ_POSTFLUSH), which causes double list_add if without this "list_del_init(&rq->queuelist)". The weird invalid format problem should be fixed in dm layer.

Published
7/12/2024
Last modified
8/4/2026
CVE assigner
Not available
NVD analysis
Not available

Exploitation

No CISA KEV flag in the saved record

An absent KEV flag does not establish that exploitation has never occurred. Verify current intelligence before prioritizing work.

EPSS predictions and CISA SSVC assessments are not imported here. Review additional intelligence on Cloudflare

Affected products

Affected-version rules published in the advisory. Conditions and uncertain comparisons require verification.

Vendor / productAffected versionsPlatform / conditionsEvidence
linux kernel
linux
≥ 6.6, < 6.6.35

Verify advisory

Source
linux kernel
linux
≥ 6.7, < 6.9.6

Verify advisory

Source
linux kernel
linux
6.10

Verify advisory

The advisory has platform, edition, hardware, or configuration conditions not verified by software inventory.

Source
Linux
Linux
≥ 81ada09cc25e4bf2de7d2951925fb409338a545d, < fe1e395563ccb051e9dbd8fa99859f5caaad2e71

Verify advisory

Source
Linux
Linux
≥ 81ada09cc25e4bf2de7d2951925fb409338a545d, < 87907bd69721a8506618a954d41a1de3040e88aa

Verify advisory

Source
Linux
Linux
≥ 81ada09cc25e4bf2de7d2951925fb409338a545d, < d0321c812d89c5910d8da8e4b10c891c6b96ff70

Verify advisory

Source
Linux
Linux
6.6

Verify advisory

Source

Recommended actions

Verify the product, installed version, platform, and advisory prerequisites on each system. Apply the vendor's applicable fixed release or mitigation. An affected-range boundary alone is not a universal update recommendation.

Vendor advisory links

Derived from non-aggregator references because the source record has no vendor tags. Verify the advisory before acting on it.

Severity

CVSS describes technical impact. It is separate from exploitation evidence.

Published headline score: 7.8. Score version, vector, and attribution are not available in this record. Additional score details appear when the source record is next refreshed.

Sources & references

Sources: Official CVE List, NVD and cve.now (summaries CC BY 4.0). Uses NVD data; not endorsed by NVD.