Skip to content
Snippets Groups Projects
Commit 4cc16d64 authored by majun258's avatar majun258 Committed by Alex Deucher
Browse files

drm/amdkfd: Fix the memory overrun


Fix the memory overrun issue caused by wrong array size.

Signed-off-by: default avatarMa Jun <Jun.Ma2@amd.com>
Reviewed-by: default avatarFelix Kuehling <Felix.Kuehling@amd.com>
Reported-by: default avatarcoverity-bot <keescook+coverity-bot@chromium.org>
Addresses-Coverity-ID: 1527133 ("Memory - corruptions")
Fixes: c0cc999f ("drm/amdkfd: Fix the warning of array-index-out-of-bounds")
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 407a5bdd
No related branches found
No related tags found
No related merge requests found
...@@ -1111,7 +1111,7 @@ static int kfd_parse_subtype_cache(struct crat_subtype_cache *cache, ...@@ -1111,7 +1111,7 @@ static int kfd_parse_subtype_cache(struct crat_subtype_cache *cache,
props->cache_latency = cache->cache_latency; props->cache_latency = cache->cache_latency;
memcpy(props->sibling_map, cache->sibling_map, memcpy(props->sibling_map, cache->sibling_map,
sizeof(props->sibling_map)); CRAT_SIBLINGMAP_SIZE);
/* set the sibling_map_size as 32 for CRAT from ACPI */ /* set the sibling_map_size as 32 for CRAT from ACPI */
props->sibling_map_size = CRAT_SIBLINGMAP_SIZE; props->sibling_map_size = CRAT_SIBLINGMAP_SIZE;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment