usb: gadget: f_tcm: synchronize delayed set_alt with teardown
In the Linux kernel, the following vulnerability has been resolved: usb: gadget: f_tcm: synchronize delayed set_alt with teardown The f_tcm set_alt() path defers endpoint setup to a work item and completes the delayed status response from process context. The delayed work uses f_tcm private state and may complete the setup request after disconnect or function teardown has already moved on. Cancel and drain the delayed set_alt work when the function is unbound or freed. For disable paths, which are reached under the composite device lock, use a small state machine and a non-sleeping cancellation path instead of cancel_work_sync(). If the work is already running, mark it cancelled and let the worker own the cleanup; otherwise tcm_disable() can cancel the queued work and clean up immediately. Also serialize the final delayed-status completion with the cancellation check while holding the composite device lock. This prevents a disconnect from clearing delayed_status while the worker is about to complete the control request. Validation reproduced this kernel report: BUG: KASAN: slab-use-after-free in tcm_delayed_set_alt+0x6c/0xef0 Call Trace: dump_stack_lvl+0x66/0xa0 print_report+0xce/0x630 ? tcm_delayed_set_alt+0x6c/0xef0 ? srso_alias_return_thunk+0x5/0xfbef5 ? __virt_addr_valid+0x188/0x320 ? tcm_delayed_set_alt+0x6c/0xef0 kasan_report+0xe0/0x110 ? tcm_delayed_set_alt+0x6c/0xef0 tcm_delayed_set_alt+0x6c/0xef0 ? __pfx_tcm_delayed_set_alt+0x10/0x10 ? process_one_work+0x4cb/0xb90 ?
- Products
- Kernel
- Affected versions
- Not specified
- Fixed versions
- 5.10.266, 5.15.217, 6.1.184, 6.12.103, 6.18.42, 6.6.151, 7.1.6
- CVEs
- CVE-2026-68367
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 4 Nov 2026, 20:32 UTC · Revision 1
Source evidence
usb: gadget: f_tcm: synchronize delayed set_alt with teardown
core-osv · Original sourcePublished 10 Aug 2026, 12:03 UTC
In the Linux kernel, the following vulnerability has been resolved: usb: gadget: f_tcm: synchronize delayed set_alt with teardown The f_tcm set_alt() path defers endpoint setup to a work item and completes the delayed status response from process context. The delayed work uses f_tcm private state and may complete the setup request after disconnect or function teardown has already moved on. Cancel and drain the delayed set_alt work when the function is unbound or freed. For disable paths, which are reached under the composite device lock, use a small state machine and a non-sleeping cancellation path instead of cancel_work_sync(). If the work is already running, mark it cancelled and let the worker own the cleanup; otherwise tcm_disable() can cancel the queued work and clean up immediately. Also serialize the final delayed-status completion with the cancellation check while holding the composite device lock. This prevents a disconnect from clearing delayed_status while the worker is about to complete the control request. Validation reproduced this kernel report: BUG: KASAN: slab-use-after-free in tcm_delayed_set_alt+0x6c/0xef0 Call Trace: dump_stack_lvl+0x66/0xa0 print_report+0xce/0x630 ? tcm_delayed_set_alt+0x6c/0xef0 ? srso_alias_return_thunk+0x5/0xfbef5 ? __virt_addr_valid+0x188/0x320 ? tcm_delayed_set_alt+0x6c/0xef0 kasan_report+0xe0/0x110 ? tcm_delayed_set_alt+0x6c/0xef0 tcm_delayed_set_alt+0x6c/0xef0 ? __pfx_tcm_delayed_set_alt+0x10/0x10 ? process_one_work+0x4cb/0xb90 ?
osv:CVE-2026-68367
Kernel
Fixed versions: 5.10.266, 5.15.217, 6.1.184, 6.6.151, 6.12.103, 6.18.42, 7.1.6
Complete source record
{
"id": "58520f0b5cdeafbd631e5a9d6e512549d5cede38bb4aa28c8e02a6f1da607eea",
"url": "https://osv.dev/vulnerability/CVE-2026-68367",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "usb: gadget: f_tcm: synchronize delayed set_alt with teardown",
"summary": "In the Linux kernel, the following vulnerability has been resolved: usb: gadget: f_tcm: synchronize delayed set_alt with teardown The f_tcm set_alt() path defers endpoint setup to a work item and completes the delayed status response from process context. The delayed work uses f_tcm private state and may complete the setup request after disconnect or function teardown has already moved on. Cancel and drain the delayed set_alt work when the function is unbound or freed. For disable paths, which are reached under the composite device lock, use a small state machine and a non-sleeping cancellation path instead of cancel_work_sync(). If the work is already running, mark it cancelled and let the worker own the cleanup; otherwise tcm_disable() can cancel the queued work and clean up immediately. Also serialize the final delayed-status completion with the cancellation check while holding the composite device lock. This prevents a disconnect from clearing delayed_status while the worker is about to complete the control request. Validation reproduced this kernel report: BUG: KASAN: slab-use-after-free in tcm_delayed_set_alt+0x6c/0xef0 Call Trace: dump_stack_lvl+0x66/0xa0 print_report+0xce/0x630 ? tcm_delayed_set_alt+0x6c/0xef0 ? srso_alias_return_thunk+0x5/0xfbef5 ? __virt_addr_valid+0x188/0x320 ? tcm_delayed_set_alt+0x6c/0xef0 kasan_report+0xe0/0x110 ? tcm_delayed_set_alt+0x6c/0xef0 tcm_delayed_set_alt+0x6c/0xef0 ? __pfx_tcm_delayed_set_alt+0x10/0x10 ? process_one_work+0x4cb/0xb90 ? ",
"evidence": "osv:CVE-2026-68367",
"products": [
{
"name": {
"value": "Kernel",
"evidence": "/affected/1/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "5.10.266",
"evidence": "/affected/1/ranges"
},
{
"value": "5.15.217",
"evidence": "/affected/1/ranges"
},
{
"value": "6.1.184",
"evidence": "/affected/1/ranges"
},
{
"value": "6.6.151",
"evidence": "/affected/1/ranges"
},
{
"value": "6.12.103",
"evidence": "/affected/1/ranges"
},
{
"value": "6.18.42",
"evidence": "/affected/1/ranges"
},
{
"value": "7.1.6",
"evidence": "/affected/1/ranges"
}
],
"affected_versions": []
}
],
"severity": "unknown",
"structured": {
"id": "CVE-2026-68367",
"aliases": [
"CVE-2026-68367"
],
"affected": [
{
"ranges": [
{
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"type": "GIT",
"events": [
{
"introduced": "c52661d60f636d17e26ad834457db333bd1df494"
},
{
"fixed": "8fb317058d165c88f3344f59439c14872c162b3c"
},
{
"fixed": "90431d8523c0c1c9f8e3e3f0895727063f93da85"
},
{
"fixed": "ee07d09419f1c59c74f73107aa08444f2f2fc6c8"
},
{
"fixed": "3118bb872c7dff653294f193d5328a476619e04d"
},
{
"fixed": "a6eb5a0ae7cd313cfd7df78decd8f43b64c68703"
},
{
"fixed": "f282242906c12fd476b86757afba51f211d4f959"
},
{
"fixed": "4c6c6a5588b9a2f8437fb794e852d05fa60ebe53"
},
{
"fixed": "79e2d75725c85607f8a9d87ae9cace62a19f767d"
}
]
}
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-68367.json"
}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "3.5.0"
},
{
"fixed": "5.10.266"
}
]
},
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "5.11.0"
},
{
"fixed": "5.15.217"
}
]
},
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "5.16.0"
},
{
"fixed": "6.1.184"
}
]
},
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "6.2.0"
},
{
"fixed": "6.6.151"
}
]
},
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "6.7.0"
},
{
"fixed": "6.12.103"
}
]
},
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "6.13.0"
},
{
"fixed": "6.18.42"
}
]
},
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "6.19.0"
},
{
"fixed": "7.1.6"
}
]
}
],
"package": {
"name": "Kernel",
"ecosystem": "Linux"
},
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-68367.json"
}
}
],
"modified": "2026-10-28T02:30:39.153000786Z",
"provider": "osv",
"references": [
"https://git.kernel.org/stable/c/3118bb872c7dff653294f193d5328a476619e04d",
"https://git.kernel.org/stable/c/4c6c6a5588b9a2f8437fb794e852d05fa60ebe53",
"https://git.kernel.org/stable/c/79e2d75725c85607f8a9d87ae9cace62a19f767d",
"https://git.kernel.org/stable/c/8fb317058d165c88f3344f59439c14872c162b3c",
"https://git.kernel.org/stable/c/90431d8523c0c1c9f8e3e3f0895727063f93da85",
"https://git.kernel.org/stable/c/a6eb5a0ae7cd313cfd7df78decd8f43b64c68703",
"https://git.kernel.org/stable/c/ee07d09419f1c59c74f73107aa08444f2f2fc6c8",
"https://git.kernel.org/stable/c/f282242906c12fd476b86757afba51f211d4f959",
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/68xxx/CVE-2026-68367.json",
"https://nvd.nist.gov/vuln/detail/CVE-2026-68367",
"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"
],
"provider_metadata": {
"cna_assigner": "Linux",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/68xxx/CVE-2026-68367.json"
}
},
"related_cves": [
{
"value": "CVE-2026-68367",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": null
},
"source_id": "core-osv",
"document_id": 506715,
"published_at": "2026-08-10T12:03:44.6+00:00"
}