{"id":"CVE-2025-40305","state":"PUBLISHED","title":"9p/trans_fd: p9_fd_request: kick rx thread if EPOLLIN","description":"In the Linux kernel, the following vulnerability has been resolved:\n\n9p/trans_fd: p9_fd_request: kick rx thread if EPOLLIN\n\np9_read_work() doesn't set Rworksched and doesn't do schedule_work(m->rq)\nif list_empty(&m->req_list).\n\nHowever, if the pipe is full, we need to read more data and this used to\nwork prior to commit aaec5a95d59615 (\"pipe_read: don't wake up the writer\nif the pipe is still full\").\n\np9_read_work() does p9_fd_read() -> ... -> anon_pipe_read() which (before\nthe commit above) triggered the unnecessary wakeup. This wakeup calls\np9_pollwake() which kicks p9_poll_workfn() -> p9_poll_mux(), p9_poll_mux()\nwill notice EPOLLIN and schedule_work(&m->rq).\n\nThis no longer happens after the optimization above, change p9_fd_request()\nto use p9_poll_mux() instead of only checking for EPOLLOUT.","publishedAt":"2025-12-08T00:46:30.327Z","updatedAt":"2026-05-11T21:46:46.952Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"aaec5a95d59615523db03dd53c2052f0a87beea7","status":"affected","lessThan":"242531004d7de8c159f9bfadebe33fe8060b1046","versionType":"git"},{"version":"aaec5a95d59615523db03dd53c2052f0a87beea7","status":"affected","lessThan":"e8fe3f07a357c39d429e02ca34f740692d88967a","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/9p/trans_fd.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.14","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.14","versionType":"semver"},{"version":"6.17.8","status":"unaffected","lessThanOrEqual":"6.17.*","versionType":"semver"},{"version":"6.18","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/9p/trans_fd.c"]}],"references":["https://git.kernel.org/stable/c/242531004d7de8c159f9bfadebe33fe8060b1046","https://git.kernel.org/stable/c/e8fe3f07a357c39d429e02ca34f740692d88967a"],"weaknesses":[],"ingestedAt":"2026-10-29T20:09:09.358Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2025/40xxx/CVE-2025-40305.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2025-40305","state":"PUBLISHED","datePublished":"2025-12-08T00:46:30.327Z","dateUpdated":"2026-05-11T21:46:46.952Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-04-16T07:20:57.185Z"},"containers":{"cna":{"title":"9p/trans_fd: p9_fd_request: kick rx thread if EPOLLIN","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\n9p/trans_fd: p9_fd_request: kick rx thread if EPOLLIN\n\np9_read_work() doesn't set Rworksched and doesn't do schedule_work(m->rq)\nif list_empty(&m->req_list).\n\nHowever, if the pipe is full, we need to read more data and this used to\nwork prior to commit aaec5a95d59615 (\"pipe_read: don't wake up the writer\nif the pipe is still full\").\n\np9_read_work() does p9_fd_read() -> ... -> anon_pipe_read() which (before\nthe commit above) triggered the unnecessary wakeup. This wakeup calls\np9_pollwake() which kicks p9_poll_workfn() -> p9_poll_mux(), p9_poll_mux()\nwill notice EPOLLIN and schedule_work(&m->rq).\n\nThis no longer happens after the optimization above, change p9_fd_request()\nto use p9_poll_mux() instead of only checking for EPOLLOUT."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"aaec5a95d59615523db03dd53c2052f0a87beea7","status":"affected","lessThan":"242531004d7de8c159f9bfadebe33fe8060b1046","versionType":"git"},{"version":"aaec5a95d59615523db03dd53c2052f0a87beea7","status":"affected","lessThan":"e8fe3f07a357c39d429e02ca34f740692d88967a","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/9p/trans_fd.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.14","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.14","versionType":"semver"},{"version":"6.17.8","status":"unaffected","lessThanOrEqual":"6.17.*","versionType":"semver"},{"version":"6.18","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/9p/trans_fd.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/242531004d7de8c159f9bfadebe33fe8060b1046"},{"url":"https://git.kernel.org/stable/c/e8fe3f07a357c39d429e02ca34f740692d88967a"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-05-11T21:46:46.952Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.14","versionEndExcluding":"6.17.8"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.14","versionEndExcluding":"6.18"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}