aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
diff options
context:
space:
mode:
authorAndrey Grodzovsky <[email protected]>2021-06-22 16:23:38 +0000
committerAndrey Grodzovsky <[email protected]>2021-06-23 18:59:39 +0000
commitea7acd7c5967542353430947f3faf699e70602e5 (patch)
tree59832b6b475f2fca980b1ac81f7705793a6f44ba /drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
parentdrm/amdgpu: switch gtt_mgr to counting used pages (diff)
downloadkernel-ea7acd7c5967542353430947f3faf699e70602e5.tar.gz
kernel-ea7acd7c5967542353430947f3faf699e70602e5.zip
drm/amdgpu: Fix BUG_ON assert
With added CPU domain to placement you can have now 3 placemnts at once. CC: [email protected] Signed-off-by: Andrey Grodzovsky <[email protected]> Reviewed-by: Christian König <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_object.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_object.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
index d13490975ac3..22fb4ab43eef 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
@@ -180,7 +180,7 @@ void amdgpu_bo_placement_from_domain(struct amdgpu_bo *abo, u32 domain)
c++;
}
- BUG_ON(c >= AMDGPU_BO_MAX_PLACEMENTS);
+ BUG_ON(c > AMDGPU_BO_MAX_PLACEMENTS);
placement->num_placement = c;
placement->placement = places;