]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdkfd: bug fix for out of bounds mem on gpu cache filling info
authorAlex Sierra <alex.sierra@amd.com>
Thu, 24 Oct 2019 18:14:31 +0000 (13:14 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 30 Oct 2019 15:06:51 +0000 (11:06 -0400)
commit0ffe2c7cd21e7b6121d4ab40381a7b1ed5305fdc
tree534bd220d67bd7acd80e4c93b0371dd48f2c0c46
parent333884694191979e4c0fd5ecfd0fce6875f43870
drm/amdkfd: bug fix for out of bounds mem on gpu cache filling info

The bitmap in cu_info structure is defined as a 4x4 size array. In
Acturus, this matrix is initialized as a 4x2. Based on the 8 shaders.
In the gpu cache filling initialization, the access to the bitmap matrix
was done as an 8x1 instead of 4x2. Causing an out of bounds memory
access error.
Due to this, the number of GPU cache entries was inconsistent.

Signed-off-by: Alex Sierra <alex.sierra@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdkfd/kfd_crat.c