In the Linux kernel, the following vulnerability has been resolved:
drm/amd/display: Do not return negative stream id for array
[WHY] resourcestreamtostreamidx returns an array index and it return -1 when not found; however, -1 is not a valid array index number.
[HOW] When this happens, call ASSERT(), and return a zero instead.
This fixes an OVERRUN and an NEGATIVE_RETURNS issues reported by Coverity.
{ "vanir_signatures": [ { "id": "CVE-2024-42118-49070ce4", "signature_type": "Function", "target": { "file": "drivers/gpu/drm/amd/display/dc/core/dc_resource.c", "function": "resource_stream_to_stream_idx" }, "deprecated": false, "digest": { "length": 216.0, "function_hash": "251981065733176407400459005397939079282" }, "signature_version": "v1", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3ac31c9a707dd1c7c890b95333182f955e9dcb57" }, { "id": "CVE-2024-42118-f202dea8", "signature_type": "Line", "target": { "file": "drivers/gpu/drm/amd/display/dc/core/dc_resource.c" }, "deprecated": false, "digest": { "line_hashes": [ "235693729205639228391750421861418344753", "278943477716875900042239502659029715456", "5553980351730179171734167349505237313", "107433688815963892872116732409393220937" ], "threshold": 0.9 }, "signature_version": "v1", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3ac31c9a707dd1c7c890b95333182f955e9dcb57" } ] }