# CVE-2026-89887: media: i2c: ov7740: fix use-after-destroy in remove

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.18% (percentile 4, 2026-11-26)
- **Published:** 2026-09-16T10:31:51.195Z
- **Modified:** 2026-10-19T09:18:33.657Z

## Who should check

- Anyone running Linux \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 9e4693436c7dcf8584002500ce4b434b79bbf9ed; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 81e9765878d3ac8ad18e3a683332b5d6bc3a0e33; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 8a02ee6c1c4e88f3a0442bd60d3c77db9a30db5e; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 7512838a19af0a284a58435292243fad21e57ff1; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 25e2505866c577db2661e4d431f0907c6ec9a3b4; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< af81f35e4f429e769b784754e1aa4d7a922470ac; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 09453b467990e8ef8fe09f45a685f9a625248d33; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 5d1b3dea5a44124bab6c14a2d71b977dabed54e7
- Anyone running Linux 4.16

## Description

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

media: i2c: ov7740: fix use-after-destroy in remove

The ov7740\_remove() function had a severe teardown order bug where it
destroyed the driver's mutex before freeing the V4L2 control handler
which relies on that mutex, leading to a use-after-destroy kernel panic.
Furthermore, the driver explicitly called v4l2\_ctrl\_handler\_free() and
mutex\_destroy() sequentially, but then called ov7740\_free\_controls()
which invokes both of them a second time, resulting in a double-free.

This patch fixes the issue by unregistering the subdevice first, and
relying exclusively on ov7740\_free\_controls() to safely tear down the
mutex and control handler in the correct order.

## Affected and fixed versions

- Linux: \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 9e4693436c7dcf8584002500ce4b434b79bbf9ed; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 81e9765878d3ac8ad18e3a683332b5d6bc3a0e33; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 8a02ee6c1c4e88f3a0442bd60d3c77db9a30db5e; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 7512838a19af0a284a58435292243fad21e57ff1; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 25e2505866c577db2661e4d431f0907c6ec9a3b4; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< af81f35e4f429e769b784754e1aa4d7a922470ac; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 09453b467990e8ef8fe09f45a685f9a625248d33; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 5d1b3dea5a44124bab6c14a2d71b977dabed54e7 (cvelist)
- Linux: 4.16 (cvelist)

## Mitigation

- Upgrade Linux to 5d1b3dea5a44124bab6c14a2d71b977dabed54e7 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-89887. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-89887.md
Affected: Linux >= 39c5c4471b8d793daf868bd004e56ed420e89707, < 9e4693436c7dcf8584002500ce4b434b79bbf9ed; >= 39c5c4471b8d793daf868bd004e56ed420e89707, < 81e9765878d3ac8ad18e3a683332b5d6bc3a0e33; >= 39c5c4471b8d793daf868bd004e56ed420e89707, < 8a02ee6c1c4e88f3a0442bd60d3c77db9a30db5e; >= 39c5c4471b8d793daf868bd…
Fixed in: Linux 9e4693436c7dcf8584002500ce4b434b79bbf9ed, Linux 81e9765878d3ac8ad18e3a683332b5d6bc3a0e33, Linux 8a02ee6c1c4e88f3a0442bd60d3c77db9a30db5e, Linux 7512838a19af0a284a58435292243fad21e57ff1, Linux 25e2505866c577db2661e4d431f0907c6ec9a3b4, Linux 09453b467990e8ef8fe09f45a685f9a625248d33, Linux 5d1b3…

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2026-89887 being exploited?

There is no confirmed exploitation: CVE-2026-89887 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.18% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2026-89887?

High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2026-89887?

Linux \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 9e4693436c7dcf8584002500ce4b434b79bbf9ed; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 81e9765878d3ac8ad18e3a683332b5d6bc3a0e33; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 8a02ee6c1c4e88f3a0442bd60d3c77db9a30db5e; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 7512838a19af0a284a58435292243fad21e57ff1; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 25e2505866c577db2661e4d431f0907c6ec9a3b4; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< af81f35e4f429e769b784754e1aa4d7a922470ac; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 09453b467990e8ef8fe09f45a685f9a625248d33; \>= 39c5c4471b8d793daf868bd004e56ed420e89707, \< 5d1b3dea5a44124bab6c14a2d71b977dabed54e7; Linux 4.16.

### Is there a fix for CVE-2026-89887?

Yes. Fixed in Linux 9e4693436c7dcf8584002500ce4b434b79bbf9ed, Linux 81e9765878d3ac8ad18e3a683332b5d6bc3a0e33, Linux 8a02ee6c1c4e88f3a0442bd60d3c77db9a30db5e, Linux 7512838a19af0a284a58435292243fad21e57ff1, Linux 25e2505866c577db2661e4d431f0907c6ec9a3b4, Linux 09453b467990e8ef8fe09f45a685f9a625248d33, Linux 5d1b3dea5a44124bab6c14a2d71b977dabed54e7. Upgrade Linux to 5d1b3dea5a44124bab6c14a2d71b977dabed54e7 or later.

### How do I check if I'm affected by CVE-2026-89887?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- other: <https://git.kernel.org/stable/c/9e4693436c7dcf8584002500ce4b434b79bbf9ed>
- other: <https://git.kernel.org/stable/c/81e9765878d3ac8ad18e3a683332b5d6bc3a0e33>
- other: <https://git.kernel.org/stable/c/8a02ee6c1c4e88f3a0442bd60d3c77db9a30db5e>
- other: <https://git.kernel.org/stable/c/7512838a19af0a284a58435292243fad21e57ff1>
- other: <https://git.kernel.org/stable/c/25e2505866c577db2661e4d431f0907c6ec9a3b4>
- other: <https://git.kernel.org/stable/c/af81f35e4f429e769b784754e1aa4d7a922470ac>
- other: <https://git.kernel.org/stable/c/09453b467990e8ef8fe09f45a685f9a625248d33>
- other: <https://git.kernel.org/stable/c/5d1b3dea5a44124bab6c14a2d71b977dabed54e7>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-89887>

HTML: <https://flawdb.com/CVE-2026-89887> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-89887>
