CVE-2022-49254

media: ti-vpe: cal: Fix a NULL pointer dereference in cal_ctx_v4l2_init_formats()

State
Published
Severity
Not scored
Published
Feb 26, 2025
Updated
May 11, 2026
Reserved
Feb 26, 2025

Read the record on cve.org

Description

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

media: ti-vpe: cal: Fix a NULL pointer dereference in cal_ctx_v4l2_init_formats()

In cal_ctx_v4l2_init_formats(), devm_kzalloc() is assigned to ctx->active_fmt and there is a dereference of it after that, which could lead to NULL pointer dereference on failure of devm_kzalloc().

Fix this bug by adding a NULL check of ctx->active_fmt.

This bug was found by a static analyzer.

Builds with 'make allyesconfig' show no new warnings, and our static analyzer no longer warns about this code.

Scores

The record has no CVSS score.

Weaknesses

The record names no weakness.

Affected Products

ProductVersions
LinuxLinux
  • 7168155002cf7aadbfaa14a28f037c880a214764 to before aa613ac270292e102503e9767882e39200efe608Affected
  • 7168155002cf7aadbfaa14a28f037c880a214764 to before 91e2805579ab0783eed53acc2bf9fb553e939004Affected
  • 7168155002cf7aadbfaa14a28f037c880a214764 to before 1381f1a629a090c251965edb56f849ad648414a4Affected
  • 7168155002cf7aadbfaa14a28f037c880a214764 to before abd77889851d2ead0d0c9c4d29f1808801477b00Affected
LinuxLinux
  • 5.12Affected
  • before 5.12Not affected
  • 5.15.33 through 5.15.*Not affected
  • 5.16.19 through 5.16.*Not affected
  • 5.17.2 through 5.17.*Not affected
  • 5.18 and laterNot affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.