GHSA-VFGH-4P3F-75PQ

Vulnerability from github – Published: 2026-12-03 06:30 – Updated: 2026-12-03 06:30
VLAI
Details

In the Linux kernel, the following vulnerability has been resolved:

driver core: take parent lock in async device attach

For device types with need_parent_lock set (only USB interfaces), probe() must run with the parent device locked. A synchronous attach after device_add() gets this from the caller, e.g. usb_set_configuration() holds the udev lock while adding interfaces. __device_attach_async_helper() runs the probe from an async worker instead, where that lock isn't held, and only takes device_lock(dev).

With async probing enabled for the hub driver (e.g. driver_async_probe=* or driver_async_probe=hub), this races when a multi-TT hub is configured. For multi-TT hubs, hub_probe() calls usb_set_interface(hdev, 0, 1) to select the TT-per-port altsetting, and usb_set_interface() creates the endpoint devices of the interface a second time:

usb_set_configuration() async worker [udev locked] device_add(intf) queues the probe ----------> __device_attach_async_helper() [intf locked, udev not locked] hub_probe() usb_set_interface(hdev, 0, 1) create_intf_ep_devs(intf) create_intf_ep_devs(intf)

create_intf_ep_devs() checks and sets intf->ep_devs_created without a lock of its own. If usb_set_configuration() has created ep_81 but not yet set the flag, usb_set_interface() skips removing the endpoint devices of the old altsetting and creates ep_81 again. With a synchronous probe, hub_probe() runs inside device_add() with the udev lock held, and usb_set_configuration() then finds ep_devs_created already set.

Single-TT hubs don't call usb_set_interface() from hub_probe() and don't show this warning, but their probe runs without the udev lock as well.

On an i.MX8MM board with an onboard USB2514 hub this hit 11 of 100 boots:

sysfs: cannot create duplicate filename '.../1-1/1-1:1.0/ep_81' Call trace: sysfs_warn_dup usb_create_ep_devs create_intf_ep_devs usb_set_interface hub_probe usb_probe_interface really_probe __device_attach_async_helper async_run_entry_fn

It also shows on v7.3-rc6 in QEMU, with dummy_hcd and a raw-gadget program emulating a multi-TT hub: re-authorizing the hub in a loop, while a SCHED_FIFO task preempts the writing task at random points for 3 ms, hit the warning in 29 of 6000 iterations.

Take the parent lock in __device_attach_async_helper() as well, like __driver_attach_async_helper() does, and move __device_driver_lock/unlock() up for that. With this the warning was gone in 300 boots on the board and in 6000 iterations in QEMU.

[ johan: switch to async_schedule_dev_nocall() to avoid deadlock if async_schedule_dev() runs synchronously when parent lock is held ] [ Fold the nested conditions into a single if statement; correct commit message to mention "device types" rather than "buses" for "need_parent_lock". - Danilo ]

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2026-142804"
  ],
  "database_specific": {
    "cwe_ids": [],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2026-12-03T04:18:14Z",
    "severity": null
  },
  "details": "In the Linux kernel, the following vulnerability has been resolved:\n\ndriver core: take parent lock in async device attach\n\nFor device types with need_parent_lock set (only USB interfaces),\nprobe() must run with the parent device locked. A synchronous attach\nafter device_add() gets this from the caller, e.g.\nusb_set_configuration() holds the udev lock while adding interfaces.\n__device_attach_async_helper() runs the probe from an async worker\ninstead, where that lock isn\u0027t held, and only takes device_lock(dev).\n\nWith async probing enabled for the hub driver (e.g. driver_async_probe=*\nor driver_async_probe=hub), this races when a multi-TT hub is\nconfigured. For multi-TT hubs, hub_probe() calls\nusb_set_interface(hdev, 0, 1) to select the TT-per-port altsetting, and\nusb_set_interface() creates the endpoint devices of the interface a\nsecond time:\n\n  usb_set_configuration()           async worker\n    [udev locked]\n    device_add(intf)\n      queues the probe  ----------\u003e __device_attach_async_helper()\n                                      [intf locked, udev not locked]\n                                      hub_probe()\n                                        usb_set_interface(hdev, 0, 1)\n    create_intf_ep_devs(intf)             create_intf_ep_devs(intf)\n\ncreate_intf_ep_devs() checks and sets intf-\u003eep_devs_created without a\nlock of its own. If usb_set_configuration() has created ep_81 but not\nyet set the flag, usb_set_interface() skips removing the endpoint\ndevices of the old altsetting and creates ep_81 again. With a\nsynchronous probe, hub_probe() runs inside device_add() with the udev\nlock held, and usb_set_configuration() then finds ep_devs_created\nalready set.\n\nSingle-TT hubs don\u0027t call usb_set_interface() from hub_probe() and\ndon\u0027t show this warning, but their probe runs without the udev lock as\nwell.\n\nOn an i.MX8MM board with an onboard USB2514 hub this hit 11 of 100\nboots:\n\n  sysfs: cannot create duplicate filename \u0027.../1-1/1-1:1.0/ep_81\u0027\n  Call trace:\n   sysfs_warn_dup\n   usb_create_ep_devs\n   create_intf_ep_devs\n   usb_set_interface\n   hub_probe\n   usb_probe_interface\n   really_probe\n   __device_attach_async_helper\n   async_run_entry_fn\n\nIt also shows on v7.3-rc6 in QEMU, with dummy_hcd and a raw-gadget\nprogram emulating a multi-TT hub: re-authorizing the hub in a loop,\nwhile a SCHED_FIFO task preempts the writing task at random points for\n3 ms, hit the warning in 29 of 6000 iterations.\n\nTake the parent lock in __device_attach_async_helper() as well, like\n__driver_attach_async_helper() does, and move\n__device_driver_lock/unlock() up for that. With this the warning was\ngone in 300 boots on the board and in 6000 iterations in QEMU.\n\n[ johan: switch to async_schedule_dev_nocall() to avoid deadlock if\n         async_schedule_dev() runs synchronously when parent lock is\n\t held ]\n[ Fold the nested conditions into a single if statement; correct commit\n  message to mention \"device types\" rather than \"buses\" for\n  \"need_parent_lock\". - Danilo ]",
  "id": "GHSA-vfgh-4p3f-75pq",
  "modified": "2026-12-03T06:30:34Z",
  "published": "2026-12-03T06:30:34Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-142804"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/027caf8870b8f1763cd804b2b6895aa4d3311579"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/0efcfd3afbd7ac3737979732099f9e1efe378a58"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/16da5d271322e0947ecce0edc54daa248cf8101e"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/187a62f99da29b1a55602b0d401a783d8dc86161"
    },
    {
      "type": "WEB",
      "url": "https://git.kernel.org/stable/c/1f1a7cdcc7a9a73b5496a45390fb13b7bf7b088f"
    }
  ],
  "schema_version": "1.4.0",
  "severity": []
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Drag nodes to arrange them. Double-click a related vulnerability to open it, or a source to visit its link. The Physics button on the left tunes the layout and the simulation; the legend at the bottom left hides or shows nodes by kind and by sighting type.

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Vulnerability timeline

Sightings and recorded dates, grouped by day · UTC

JSON
How durations are calculated

Following the VTEM framework (Black Hat USA 2015), time to patch starts when the vendor or a coordinator was informed, total time to patch at discovery, and disclosure to patch at public disclosure; vendor response time runs from the report to its acknowledgement. Time to exploit and time unpatched start at the earliest discovery or report, falling back to public disclosure. Unpatched time ends at the first recorded patch, or the calculation time when no patch is recorded. Exploitation to patch shows the interval between those two events; a published proof of concept is a public exploit, not exploitation. The method is described in a publication.

Each result shows its source dates. A negative interval means the end event came first; when date-only inputs leave the order open, the result says so. Date-only inputs are approximate. The earliest evidence wins: KEV report dates and sightings are labelled as such. Records describing another vulnerability are listed but never calculated from, and a PoC alone does not establish exploitation. Missing patch evidence does not prove that no patch exists. Filters below change the event list only.

Events included in the timeline

Loading timeline…


    Loading…

    Loading…

    Loading…

    Related by attack behaviour

    Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.