]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu: fix return value check in kfd
authorShashank Sharma <shashank.sharma@amd.com>
Mon, 27 Feb 2023 14:42:28 +0000 (15:42 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 17 Mar 2023 07:50:29 +0000 (08:50 +0100)
commit5b9e109b4eb06af5d5faf7ccddf66e25d44a7bf1
tree348fee40cfc517aac652b20b0662881ef40b0827
parent6ae61f9668e8281b456d71a0301784a3290b9808
drm/amdgpu: fix return value check in kfd

[ Upstream commit 4e334e73d734b030d0e3f5446a813c3995aae20d ]

This patch fixes a return value check in kfd doorbell handling.
This function should return 0(error) only when the ida_simple_get
returns < 0(error), return > 0 is a success case.

Cc: Felix Kuehling <Felix.Kuehling@amd.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Fixes: 17cd15143613 ("drm/amdkfd: Allocate doorbells only when needed")
Acked-by: Christian Koenig <chriatian.koenig@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Shashank Sharma <shashank.sharma@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/amd/amdkfd/kfd_doorbell.c