{"api_version":"1","generated_at":"2026-09-15T13:15:12+00:00","cve":"CVE-2026-89732","urls":{"html":"https://cve.report/CVE-2026-89732","api":"https://cve.report/api/cve/CVE-2026-89732.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2026-89732","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2026-89732"},"summary":{"title":"usb: gadget: f_fs: Prevent deadlock during ep0 read loop","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nusb: gadget: f_fs: Prevent deadlock during ep0 read loop\n\nCurrently, ffs_ep0_read() holds ffs->mutex when it prepares to go to\nsleep waiting for an event. When no setup events are pending, it calls\nwait_event_interruptible_exclusive_locked_irq() with the mutex still\nheld. The wait macro deliberately drops the waitqueue spinlock before\nsleeping but does not drop the mutex.\n\nIf a userspace daemon is polling ep0 via read() and the gadget is\nasynchronously torn down via configfs (e.g., echo \"\" > UDC), a\ndeadlock can occur:\n\n1. The configfs teardown calls functionfs_unbind(), which queues a\n   FUNCTIONFS_UNBIND event.\n2. The daemon wakes up, consumes the event, and drops the mutex.\n3. However, if the daemon loops and immediately issues another read()\n   before exiting, it reacquires ffs->mutex and again goes into an\n   interruptible sleep.\n4. Meanwhile, functionfs_unbind() continues execution and attempts to\n   acquire ffs->mutex to tear down ep0req.\n5. The kernel deadlocks because the configfs thread is stuck in an\n   uninterruptible sleep waiting for the mutex, while the userspace\n   daemon is in an interruptible sleep holding the mutex forever\n   because no more events will arrive.\n\nTo fix this, we drop both the waitqueue spinlock and ffs->mutex before\ngoing to sleep, and use wait_event_interruptible_exclusive() instead.\nUpon waking up, we jump back to the `retry` label to safely reacquire\nthe mutex and re-evaluate the state machine. By not sleeping with\nffs->mutex held, we natively decouple gadget teardowns (which require\nthe mutex) from userspace polling.","state":"PUBLISHED","assigner":"Linux","published_at":"2026-09-11 20:20:03","updated_at":"2026-09-14 13:19:22"},"problem_types":[],"metrics":[],"references":[{"url":"https://git.kernel.org/stable/c/fbe3db4b650c284df8eb4cb68eebcf270cf861b5","name":"https://git.kernel.org/stable/c/fbe3db4b650c284df8eb4cb68eebcf270cf861b5","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/30430509c156e1df2bdafd5f1cadb160e53db5d6","name":"https://git.kernel.org/stable/c/30430509c156e1df2bdafd5f1cadb160e53db5d6","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/569dd7e5dcffe1e1c6b26ca2cd3be57eb433e082","name":"https://git.kernel.org/stable/c/569dd7e5dcffe1e1c6b26ca2cd3be57eb433e082","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/34e88f53614640b59039a46717fb6142e9871022","name":"https://git.kernel.org/stable/c/34e88f53614640b59039a46717fb6142e9871022","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/b0a6bfac0c3c3edf5b2ecaee87a09234601fe78d","name":"https://git.kernel.org/stable/c/b0a6bfac0c3c3edf5b2ecaee87a09234601fe78d","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/eac233e63f9db82ba874e3cccafaafab162999e0","name":"https://git.kernel.org/stable/c/eac233e63f9db82ba874e3cccafaafab162999e0","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/fd20cc68bbdb5620696ac108e8f2efd180fe2c1a","name":"https://git.kernel.org/stable/c/fd20cc68bbdb5620696ac108e8f2efd180fe2c1a","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/bafddd0f20b5228760be303aa69c58502e92309c","name":"https://git.kernel.org/stable/c/bafddd0f20b5228760be303aa69c58502e92309c","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-89732","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-89732","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected ddf8abd2599491cbad959c700b90ba72a5dce8d0 fbe3db4b650c284df8eb4cb68eebcf270cf861b5 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected ddf8abd2599491cbad959c700b90ba72a5dce8d0 30430509c156e1df2bdafd5f1cadb160e53db5d6 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected ddf8abd2599491cbad959c700b90ba72a5dce8d0 bafddd0f20b5228760be303aa69c58502e92309c git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected ddf8abd2599491cbad959c700b90ba72a5dce8d0 b0a6bfac0c3c3edf5b2ecaee87a09234601fe78d git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected ddf8abd2599491cbad959c700b90ba72a5dce8d0 fd20cc68bbdb5620696ac108e8f2efd180fe2c1a git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected ddf8abd2599491cbad959c700b90ba72a5dce8d0 34e88f53614640b59039a46717fb6142e9871022 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected ddf8abd2599491cbad959c700b90ba72a5dce8d0 eac233e63f9db82ba874e3cccafaafab162999e0 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected ddf8abd2599491cbad959c700b90ba72a5dce8d0 569dd7e5dcffe1e1c6b26ca2cd3be57eb433e082 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 2.6.35","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 2.6.35 semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 5.10.270 5.10.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 5.15.221 5.15.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.1.188 6.1.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.6.157 6.6.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.12.109 6.12.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.18.50 6.18.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.2.4 7.2.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.3-rc1 * original_commit_for_fix","platforms":[]}],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[],"vendor_comments":[],"enrichments":{"kev":null,"epss":{"cve_year":"2026","cve_id":"89732","cve":"CVE-2026-89732","epss":"0.002150000","percentile":"0.119600000","score_date":"2026-09-14","updated_at":"2026-09-15 00:00:41"},"legacy_qids":[]},"source_records":{"cve_program":{"containers":{"cna":{"affected":[{"defaultStatus":"unaffected","product":"Linux","programFiles":["drivers/usb/gadget/function/f_fs.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"lessThan":"fbe3db4b650c284df8eb4cb68eebcf270cf861b5","status":"affected","version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","versionType":"git"},{"lessThan":"30430509c156e1df2bdafd5f1cadb160e53db5d6","status":"affected","version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","versionType":"git"},{"lessThan":"bafddd0f20b5228760be303aa69c58502e92309c","status":"affected","version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","versionType":"git"},{"lessThan":"b0a6bfac0c3c3edf5b2ecaee87a09234601fe78d","status":"affected","version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","versionType":"git"},{"lessThan":"fd20cc68bbdb5620696ac108e8f2efd180fe2c1a","status":"affected","version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","versionType":"git"},{"lessThan":"34e88f53614640b59039a46717fb6142e9871022","status":"affected","version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","versionType":"git"},{"lessThan":"eac233e63f9db82ba874e3cccafaafab162999e0","status":"affected","version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","versionType":"git"},{"lessThan":"569dd7e5dcffe1e1c6b26ca2cd3be57eb433e082","status":"affected","version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","versionType":"git"}]},{"defaultStatus":"affected","product":"Linux","programFiles":["drivers/usb/gadget/function/f_fs.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"status":"affected","version":"2.6.35"},{"lessThan":"2.6.35","status":"unaffected","version":"0","versionType":"semver"},{"lessThanOrEqual":"5.10.*","status":"unaffected","version":"5.10.270","versionType":"semver"},{"lessThanOrEqual":"5.15.*","status":"unaffected","version":"5.15.221","versionType":"semver"},{"lessThanOrEqual":"6.1.*","status":"unaffected","version":"6.1.188","versionType":"semver"},{"lessThanOrEqual":"6.6.*","status":"unaffected","version":"6.6.157","versionType":"semver"},{"lessThanOrEqual":"6.12.*","status":"unaffected","version":"6.12.109","versionType":"semver"},{"lessThanOrEqual":"6.18.*","status":"unaffected","version":"6.18.50","versionType":"semver"},{"lessThanOrEqual":"7.2.*","status":"unaffected","version":"7.2.4","versionType":"semver"},{"lessThanOrEqual":"*","status":"unaffected","version":"7.3-rc1","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"5.10.270","versionStartIncluding":"2.6.35","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"5.15.221","versionStartIncluding":"2.6.35","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.1.188","versionStartIncluding":"2.6.35","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.6.157","versionStartIncluding":"2.6.35","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.12.109","versionStartIncluding":"2.6.35","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.18.50","versionStartIncluding":"2.6.35","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.2.4","versionStartIncluding":"2.6.35","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.3-rc1","versionStartIncluding":"2.6.35","vulnerable":true}],"negate":false,"operator":"OR"}]}],"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nusb: gadget: f_fs: Prevent deadlock during ep0 read loop\n\nCurrently, ffs_ep0_read() holds ffs->mutex when it prepares to go to\nsleep waiting for an event. When no setup events are pending, it calls\nwait_event_interruptible_exclusive_locked_irq() with the mutex still\nheld. The wait macro deliberately drops the waitqueue spinlock before\nsleeping but does not drop the mutex.\n\nIf a userspace daemon is polling ep0 via read() and the gadget is\nasynchronously torn down via configfs (e.g., echo \"\" > UDC), a\ndeadlock can occur:\n\n1. The configfs teardown calls functionfs_unbind(), which queues a\n   FUNCTIONFS_UNBIND event.\n2. The daemon wakes up, consumes the event, and drops the mutex.\n3. However, if the daemon loops and immediately issues another read()\n   before exiting, it reacquires ffs->mutex and again goes into an\n   interruptible sleep.\n4. Meanwhile, functionfs_unbind() continues execution and attempts to\n   acquire ffs->mutex to tear down ep0req.\n5. The kernel deadlocks because the configfs thread is stuck in an\n   uninterruptible sleep waiting for the mutex, while the userspace\n   daemon is in an interruptible sleep holding the mutex forever\n   because no more events will arrive.\n\nTo fix this, we drop both the waitqueue spinlock and ffs->mutex before\ngoing to sleep, and use wait_event_interruptible_exclusive() instead.\nUpon waking up, we jump back to the `retry` label to safely reacquire\nthe mutex and re-evaluate the state machine. By not sleeping with\nffs->mutex held, we natively decouple gadget teardowns (which require\nthe mutex) from userspace polling."}],"providerMetadata":{"dateUpdated":"2026-09-14T12:02:20.311Z","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux"},"references":[{"url":"https://git.kernel.org/stable/c/fbe3db4b650c284df8eb4cb68eebcf270cf861b5"},{"url":"https://git.kernel.org/stable/c/30430509c156e1df2bdafd5f1cadb160e53db5d6"},{"url":"https://git.kernel.org/stable/c/bafddd0f20b5228760be303aa69c58502e92309c"},{"url":"https://git.kernel.org/stable/c/b0a6bfac0c3c3edf5b2ecaee87a09234601fe78d"},{"url":"https://git.kernel.org/stable/c/fd20cc68bbdb5620696ac108e8f2efd180fe2c1a"},{"url":"https://git.kernel.org/stable/c/34e88f53614640b59039a46717fb6142e9871022"},{"url":"https://git.kernel.org/stable/c/eac233e63f9db82ba874e3cccafaafab162999e0"},{"url":"https://git.kernel.org/stable/c/569dd7e5dcffe1e1c6b26ca2cd3be57eb433e082"}],"title":"usb: gadget: f_fs: Prevent deadlock during ep0 read loop","x_generator":{"engine":"bippy-1.2.0"}}},"cveMetadata":{"assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","assignerShortName":"Linux","cveId":"CVE-2026-89732","datePublished":"2026-09-11T19:46:41.974Z","dateReserved":"2026-09-11T19:38:34.760Z","dateUpdated":"2026-09-14T12:02:20.311Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.2"},"nvd":{"publishedDate":"2026-09-11 20:20:03","lastModifiedDate":"2026-09-14 13:19:22","problem_types":[],"metrics":[],"configurations":[]},"legacy_mitre":{"record":{"CveYear":"2026","CveId":"89732","Ordinal":"1","Title":"usb: gadget: f_fs: Prevent deadlock during ep0 read loop","CVE":"CVE-2026-89732","Year":"2026"},"notes":[{"CveYear":"2026","CveId":"89732","Ordinal":"1","NoteData":"In the Linux kernel, the following vulnerability has been resolved:\n\nusb: gadget: f_fs: Prevent deadlock during ep0 read loop\n\nCurrently, ffs_ep0_read() holds ffs->mutex when it prepares to go to\nsleep waiting for an event. When no setup events are pending, it calls\nwait_event_interruptible_exclusive_locked_irq() with the mutex still\nheld. The wait macro deliberately drops the waitqueue spinlock before\nsleeping but does not drop the mutex.\n\nIf a userspace daemon is polling ep0 via read() and the gadget is\nasynchronously torn down via configfs (e.g., echo \"\" > UDC), a\ndeadlock can occur:\n\n1. The configfs teardown calls functionfs_unbind(), which queues a\n   FUNCTIONFS_UNBIND event.\n2. The daemon wakes up, consumes the event, and drops the mutex.\n3. However, if the daemon loops and immediately issues another read()\n   before exiting, it reacquires ffs->mutex and again goes into an\n   interruptible sleep.\n4. Meanwhile, functionfs_unbind() continues execution and attempts to\n   acquire ffs->mutex to tear down ep0req.\n5. The kernel deadlocks because the configfs thread is stuck in an\n   uninterruptible sleep waiting for the mutex, while the userspace\n   daemon is in an interruptible sleep holding the mutex forever\n   because no more events will arrive.\n\nTo fix this, we drop both the waitqueue spinlock and ffs->mutex before\ngoing to sleep, and use wait_event_interruptible_exclusive() instead.\nUpon waking up, we jump back to the `retry` label to safely reacquire\nthe mutex and re-evaluate the state machine. By not sleeping with\nffs->mutex held, we natively decouple gadget teardowns (which require\nthe mutex) from userspace polling.","Type":"Description","Title":"usb: gadget: f_fs: Prevent deadlock during ep0 read loop"}]}}}