In the Linux kernel, the following vulnerability has been resolved:
drm/amd/display: ASSERT when failing to find index by plane/stream id
[WHY] finddispcfgidxbyplaneid and finddispcfgidxbystreamid returns an array index and they return -1 when not found; however, -1 is not a valid index number.
[HOW] When this happens, call ASSERT(), and return a positive number (which is fewer than callers' array size) instead.
This fixes 4 OVERRUN and 2 NEGATIVE_RETURNS issues reported by Coverity.
[
{
"id": "CVE-2024-42117-3d79425b",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "105996256481571086465579399471418295418",
"length": 278.0
},
"target": {
"file": "drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c",
"function": "find_disp_cfg_idx_by_plane_id"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a9c047a5cf3135b8b66bd28fbe2c698b9cace0b3"
},
{
"id": "CVE-2024-42117-91e9225b",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"line_hashes": [
"132269305986891383137177403042416837250",
"256279101812881270162837653818968624916",
"335124190963374523209816019222252165512",
"30448543749521208360067447862274283539",
"76865516249523116765295986411024647361",
"256279101812881270162837653818968624916",
"243594204327428438785703109138351587806",
"18325916130073596384041586787248703754"
],
"threshold": 0.9
},
"target": {
"file": "drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@01eb50e53c1ce505bf449348d433181310288765"
},
{
"id": "CVE-2024-42117-948aa5c8",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "99706621931126232252958837380498909029",
"length": 280.0
},
"target": {
"file": "drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c",
"function": "find_disp_cfg_idx_by_stream_id"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@01eb50e53c1ce505bf449348d433181310288765"
},
{
"id": "CVE-2024-42117-c00071d6",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "105996256481571086465579399471418295418",
"length": 278.0
},
"target": {
"file": "drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c",
"function": "find_disp_cfg_idx_by_plane_id"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@01eb50e53c1ce505bf449348d433181310288765"
},
{
"id": "CVE-2024-42117-cbcaf3f6",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "99706621931126232252958837380498909029",
"length": 280.0
},
"target": {
"file": "drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c",
"function": "find_disp_cfg_idx_by_stream_id"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a9c047a5cf3135b8b66bd28fbe2c698b9cace0b3"
},
{
"id": "CVE-2024-42117-e4e30d31",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"line_hashes": [
"132269305986891383137177403042416837250",
"256279101812881270162837653818968624916",
"335124190963374523209816019222252165512",
"30448543749521208360067447862274283539",
"76865516249523116765295986411024647361",
"256279101812881270162837653818968624916",
"243594204327428438785703109138351587806",
"18325916130073596384041586787248703754"
],
"threshold": 0.9
},
"target": {
"file": "drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a9c047a5cf3135b8b66bd28fbe2c698b9cace0b3"
}
]