CVE-2026-139560: media: em28xx: hold the vb2 queue lock when releasing the queue on close

Published Nov 30, 2026
·
Updated

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

media: em28xx: hold the vb2 queue lock when releasing the queue on close

Commit de626073dfcb ("media: em28xx: drop 'users' field") replaced the vb2foprelease() call in em28xxv4l2close() with vb2foprelease(filp, NULL) under dev->lock. vb2foprelease() took the vb2 queue lock, but the new call takes no lock at all.

The video and VBI queues have their own locks (vbqueuelock and vbvbiqueuelock), and v4l2ioctlgetlock() serializes the queue ioctls with those rather than dev->lock. The queue can therefore be released on close while another file handle is in the middle of VIDIOCREQBUFS. vb2queuealloc() adds each buffer to the queue before allocating its planes, so the release can find an MMAP buffer whose mempriv is still NULL and hand it to vb2vmallocput():

BUG: kernel NULL pointer dereference, address: 0000000000000020 RIP: 0010:vb2vmallocput+0xe/0x50 [videobuf2vmalloc] Call Trace: vb2queuefree+0x14e/0x350 [videobuf2common] vb2corequeuerelease+0x3b/0x80 [videobuf2common] vb2foprelease+0x44/0x70 [videobuf2v4l2] em28xxv4l2close+0x60/0x140 [em28xxv4l] v4l2release+0x9d/0xf0 [videodev] fput+0xfd/0x280

This was hit with OBS on a MyGica iGrabber (card=105).

Pass the queue lock to vb2foprelease(). Taking it while holding dev->lock matches the existing order in em28xxv4l2fini(), where vb2videounregisterdevice() takes the queue lock under dev->lock.

Affected Software

4 affected componentsFixes available
Linux Linux kernel
linux/kernel>=7.3.0<7.3.6
7.3.6
debian/linux<7.3.6-1
7.3.6-1
debian/linux
7.3.6-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade linux/Kernel to a version that resolves this vulnerability.

    Fixed in 7.3.6
  2. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 7.3.6-1
  3. Compensating control

    In em28xx_v4l2_close(), pass the appropriate video or VBI queue lock to _vb2_fop_release() when releasing the queue.

Event History

Nov 30, 2026
CVE Published
via MITRE·01:35 PM
Data Sourced
via MITRE·01:35 PM
Description
Data Sourced
via OSV·01:35 PM
DescriptionAffected Software
Data Sourced
via NVD·02:19 PM
Description

Frequently Asked Questions

1

Which systems are exposed to this race condition?

Systems using the Linux kernel em28xx media driver with its V4L2 video or VBI queues are exposed when those queues are in use. The race involves separate queue locks rather than the device-wide lock.

2

What activity is required to trigger the issue?

At least two file handles must operate concurrently: one can close and release a queue while another is processing VIDIOC_REQBUFS. The failure described occurs when queue release encounters an MMAP buffer whose plane allocation has not completed.

3

What happens if the race is triggered?

The kernel can dereference a NULL mem_priv pointer in vb2_vmalloc_put(), causing a kernel NULL pointer dereference. The reported stack includes vb2_vmalloc_put, __vb2_queue_free, vb2_core_queue_release, and em28xx_v4l2_close.

4

What can be done before applying a fixed kernel?

Avoid concurrent queue allocation and file-handle close operations on affected em28xx V4L2 devices, particularly concurrent VIDIOC_REQBUFS and close activity. The referenced stable kernel commits contain the resolution.

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