CVE-2022-50757 in Linux
Summary
by MITRE • 12/24/2025
In the Linux kernel, the following vulnerability has been resolved:
media: camss: Clean up received buffers on failed start of streaming
It is required to return the received buffers, if streaming can not be started. For instance media_pipeline_start() may fail with EPIPE, if a link validation between entities is not passed, and in such a case a user gets a kernel warning:
WARNING: CPU: 1 PID: 520 at drivers/media/common/videobuf2/videobuf2-core.c:1592 vb2_start_streaming+0xec/0x160 <snip> Call trace: vb2_start_streaming+0xec/0x160 vb2_core_streamon+0x9c/0x1a0 vb2_ioctl_streamon+0x68/0xbc v4l_streamon+0x30/0x3c __video_do_ioctl+0x184/0x3e0 video_usercopy+0x37c/0x7b0 video_ioctl2+0x24/0x40 v4l2_ioctl+0x4c/0x70
The fix is to correct the error path in video_start_streaming() of camss.
If you want to get best quality of vulnerability data, you may have to visit VulDB.
Analysis
by VulDB Data Team • 04/21/2026
The vulnerability CVE-2022-50757 resides within the Linux kernel's media subsystem, specifically affecting the Qualcomm Camera Subsystem (camss) driver implementation. This issue represents a resource management flaw that occurs during video streaming initialization processes, where the system fails to properly clean up buffer allocations when streaming operations encounter failures. The vulnerability manifests when the media pipeline attempts to start streaming but encounters validation errors that result in an EPIPE error code, indicating a broken pipe or link validation failure between media entities. The core problem lies in the improper handling of buffer cleanup during error conditions, creating a situation where allocated buffers remain in an inconsistent state rather than being properly returned to the system.
The technical flaw occurs within the video_start_streaming() function of the camss driver implementation, where the error handling path does not adequately address the cleanup of received buffers when streaming initialization fails. This failure creates a memory management inconsistency that can lead to resource leakage and potential system instability. The vulnerability is particularly concerning because it operates at the kernel level where improper buffer handling can create persistent resource consumption issues that may degrade system performance over time. The specific error path involves the vb2_start_streaming function in the videobuf2-core subsystem, which is part of the standard video buffer management framework used across Linux media drivers. When media_pipeline_start() fails due to link validation issues, the system generates kernel warnings that indicate the presence of unhandled buffer states, as evidenced by the call trace showing vb2_start_streaming being invoked from multiple layers of the video ioctl handling stack.
The operational impact of this vulnerability extends beyond simple resource leakage, potentially creating persistent system instability and performance degradation in embedded systems that rely heavily on camera subsystems. Systems utilizing the Qualcomm camera subsystem may experience cumulative buffer exhaustion over time, leading to streaming failures and potential system crashes. The vulnerability affects devices where camera streaming operations are frequently initiated and terminated, particularly in mobile devices, automotive systems, and embedded platforms that depend on the Linux kernel's media framework. The EPIPE error condition that triggers this issue typically occurs during pipeline validation when connections between media entities are not properly established, which can happen during device initialization, configuration changes, or when hardware connectivity issues occur. This makes the vulnerability particularly relevant in environments where dynamic media pipeline reconfiguration is common, as the improper buffer cleanup can compound over multiple streaming attempts.
Mitigation strategies for this vulnerability focus on implementing proper error path handling within the camss driver's video_start_streaming function to ensure that all received buffers are properly returned when streaming operations fail. The fix requires modification of the error handling code to explicitly clean up allocated buffers before propagating error conditions to higher-level subsystems. System administrators should ensure that kernel updates containing the fix are applied promptly, particularly in production environments where camera subsystem reliability is critical. Organizations implementing embedded systems should conduct thorough testing of media pipeline operations to verify that buffer cleanup occurs properly during error conditions. The vulnerability aligns with CWE-404, which addresses improper resource cleanup, and relates to ATT&CK technique T1070.006 for indicator removal through cleaning, as improper buffer management can create persistent system artifacts. Additionally, this issue demonstrates the importance of proper error handling in kernel drivers and aligns with security best practices for resource management in real-time systems where buffer allocation and deallocation must be handled atomically to prevent system instability and potential denial-of-service conditions.