CVE-2022-50340
media: vimc: Fix wrong function called when vimc_init() fails
Mitigation
- No fix listed yet: follow the vendor advisory.
Who should check
- Anyone running Linux >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 14d85b600bb1f6f8ef61fa8fc1907e2e623d8350; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 9c9ff35d68691aaea85b2e93763772e23930b3a3; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 681ac2902039d9b497b3ae18fdc204314979e61e; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < f38df8984ef1b45ba23888d0e232cc21a95bd04b; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < f74d3f326d1d5b8951ce263c59a121ecfa65e7c0
- Anyone running Linux 4.13
Vulnerability facts
- Affected
- Linux >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 14d85b600bb1f6f8ef61fa8fc1907e2e623d8350; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 9c9ff35d68691aaea85b2e93763772e23930b3a3; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 681ac2902039d9b497b3ae18fdc204314979e61e; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < f38df8984ef1b45ba23888d0e232cc21a95bd04b; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < f74d3f326d1d5b8951ce263c59a121ecfa65e7c0; Linux 4.13
- Fixed in
- Linux 14d85b600bb1f6f8ef61fa8fc1907e2e623d8350, Linux 9c9ff35d68691aaea85b2e93763772e23930b3a3, Linux 681ac2902039d9b497b3ae18fdc204314979e61e
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Not remotely exploitable (local or adjacent access needed)
- CVSS
- 5.5 (v3.1, CNA)CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:HOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Local
- Attack complexity: Low
- Privileges required: Low
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: None
- Integrity impact: None
- Availability impact: High
- EPSS
- 0.23% chance of exploitation in 30 days (percentile 8, 2026-11-26)
- CWE
- CWE-617
- Modified
Description
In the Linux kernel, the following vulnerability has been resolved: media: vimc: Fix wrong function called when vimc_init() fails In vimc_init(), when platform_driver_register(&vimc_pdrv) fails, platform_driver_unregister(&vimc_pdrv) is wrongly called rather than platform_device_unregister(&vimc_pdev), which causes kernel warning: Unexpected driver unregister! WARNING: CPU: 1 PID: 14517 at drivers/base/driver.c:270 driver_unregister+0x8f/0xb0 RIP: 0010:driver_unregister+0x8f/0xb0 Call Trace: <TASK> vimc_init+0x7d/0x1000 [vimc] do_one_initcall+0xd0/0x4e0 do_init_module+0x1cf/0x6b0 load_module+0x65c2/0x7820
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Linux | >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 14d85b600bb1f6f8ef61fa8fc1907e2e623d8350; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 9c9ff35d68691aaea85b2e93763772e23930b3a3; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 681ac2902039d9b497b3ae18fdc204314979e61e; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < f38df8984ef1b45ba23888d0e232cc21a95bd04b; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < f74d3f326d1d5b8951ce263c59a121ecfa65e7c0 | — | cvelist |
| Linux | 4.13 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2022-50340. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2022-50340.md Affected: Linux >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 14d85b600bb1f6f8ef61fa8fc1907e2e623d8350; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 9c9ff35d68691aaea85b2e93763772e23930b3a3; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 681ac2902039d9b497b3ae18fdc204314979e61e; >= 4a29b70907496aa9da79112… Fixed in: Linux 14d85b600bb1f6f8ef61fa8fc1907e2e623d8350, Linux 9c9ff35d68691aaea85b2e93763772e23930b3a3, Linux 681ac2902039d9b497b3ae18fdc204314979e61e 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.
References
Patches
- https://git.kernel.org/stable/c/14d85b600bb1f6f8ef61fa8fc1907e2e623d8350
- https://git.kernel.org/stable/c/9c9ff35d68691aaea85b2e93763772e23930b3a3
- https://git.kernel.org/stable/c/681ac2902039d9b497b3ae18fdc204314979e61e
- https://git.kernel.org/stable/c/f38df8984ef1b45ba23888d0e232cc21a95bd04b
- https://git.kernel.org/stable/c/f74d3f326d1d5b8951ce263c59a121ecfa65e7c0
FAQ
Is CVE-2022-50340 being exploited?
There is no confirmed exploitation: CVE-2022-50340 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.23% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2022-50340?
Medium: CVSS 5.5 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).
Which versions are affected by CVE-2022-50340?
Linux >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 14d85b600bb1f6f8ef61fa8fc1907e2e623d8350; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 9c9ff35d68691aaea85b2e93763772e23930b3a3; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < 681ac2902039d9b497b3ae18fdc204314979e61e; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < f38df8984ef1b45ba23888d0e232cc21a95bd04b; >= 4a29b70907496aa9da79112ec31cf9cf2b972c3f, < f74d3f326d1d5b8951ce263c59a121ecfa65e7c0; Linux 4.13.
Is there a fix for CVE-2022-50340?
Yes. Fixed in Linux 14d85b600bb1f6f8ef61fa8fc1907e2e623d8350, Linux 9c9ff35d68691aaea85b2e93763772e23930b3a3, Linux 681ac2902039d9b497b3ae18fdc204314979e61e. No fix listed yet: follow the vendor advisory.
How do I check if I'm affected by CVE-2022-50340?
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.