CVE-2026-89735: usb: gadget: midi2: remove default configfs groups on teardown

Published Sep 11, 2026
·
Updated

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

usb: gadget: midi2: remove default configfs groups on teardown

fmidi2allocinst() creates default configfs child groups for the default endpoint and default block using configfsadddefaultgroup(), setting their internal refcount to 1.

However, during function teardown in fmidi2freeinst() or EP cleanup in fmidi2epoptsrelease(), configfsremovedefaultgroups() is never called, therefore never dropping the refcount and leaking struct fmidi2epopts and fmidi2blockopts.

Add the missing configfsremovedefaultgroups() in the afformentioned functions to free the structs properly.

Affected Software

1 affected component
Linux Linux kernel

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Configuration

    Update the midi2 teardown/cleanup path so that configfs_remove_default_groups() is called (e.g., in f_midi2_ep_opts_release(), which currently never calls it). This ensures the default configfs child groups created by f_midi2_alloc_inst() are removed on teardown, dropping the reference count and preventing struct leaks.

    Linux kernel USB gadget midi2 configfs_remove_default_groups() = call configfs_remove_default_groups() during teardown

Event History

Sep 11, 2026
CVE Published
via MITRE·07:46 PM
Data Sourced
via MITRE·07:46 PM
Description

Frequently Asked Questions

1

How can I verify whether a kernel contains the fix?

Check whether the kernel source or history includes one of the referenced stable commits: 4beda67ee72e0c8df5b49951dd8b96f6adb25e02, a15c2acd3083461f91725760e59dff88b33c28f6, or 9ea5dfb2bfef4f8a7e704d1921d8a790cb7fb700. The provided data does not list affected or fixed kernel version ranges.

2

What is the operational impact of the missing cleanup?

Default configfs endpoint and block option structures remain referenced after MIDI2 function teardown or endpoint cleanup. This causes leaks of struct f_midi2_ep_opts and struct f_midi2_block_opts rather than freeing them properly.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203