mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 10:31:46 +09:00
drm/amdgpu: Fix signedness bug in sdma_v4_0_process_trap_irq()
commit 6769a23697f17f9bf9365ca8ed62fe37e361a05a upstream.
The "instance" variable needs to be signed for the error handling to work.
Fixes: 8b2faf1a4f3b ("drm/amdgpu: add error handle to avoid out-of-bounds")
Reviewed-by: Bob Zhou <bob.zhou@amd.com>
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: Siddh Raman Pant <siddh.raman.pant@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
c18e82d3ee
commit
e8dfbf83a8
@@ -2045,7 +2045,7 @@ static int sdma_v4_0_process_trap_irq(struct amdgpu_device *adev,
|
|||||||
struct amdgpu_irq_src *source,
|
struct amdgpu_irq_src *source,
|
||||||
struct amdgpu_iv_entry *entry)
|
struct amdgpu_iv_entry *entry)
|
||||||
{
|
{
|
||||||
uint32_t instance;
|
int instance;
|
||||||
|
|
||||||
DRM_DEBUG("IH: SDMA trap\n");
|
DRM_DEBUG("IH: SDMA trap\n");
|
||||||
instance = sdma_v4_0_irq_id_to_seq(entry->client_id);
|
instance = sdma_v4_0_irq_id_to_seq(entry->client_id);
|
||||||
|
|||||||
Reference in New Issue
Block a user