[PATCH 2/2] drm/amdgpu: fix size calc error in bo_create_kernel_at
Chen, Guchun
Guchun.Chen at amd.com
Tue Sep 17 06:50:29 UTC 2019
Series is:
Reviewed-by: Guchun Chen <guchun.chen at amd.com>
Regards,
Guchun
-----Original Message-----
From: Zhou1, Tao <Tao.Zhou1 at amd.com>
Sent: Tuesday, September 17, 2019 2:17 PM
To: amd-gfx at lists.freedesktop.org; Chen, Guchun <Guchun.Chen at amd.com>; Koenig, Christian <Christian.Koenig at amd.com>; Zhang, Hawking <Hawking.Zhang at amd.com>
Cc: Zhou1, Tao <Tao.Zhou1 at amd.com>
Subject: [PATCH 2/2] drm/amdgpu: fix size calc error in bo_create_kernel_at
replace offset with size
Signed-off-by: Tao Zhou <tao.zhou1 at amd.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
index ecad84e1b4e2..2fcd2d14cbf0 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
@@ -366,7 +366,7 @@ int amdgpu_bo_create_kernel_at(struct amdgpu_device *adev,
int r;
offset &= PAGE_MASK;
- size = ALIGN(offset, PAGE_SIZE);
+ size = ALIGN(size, PAGE_SIZE);
r = amdgpu_bo_create_reserved(adev, size, PAGE_SIZE, domain, bo_ptr,
NULL, NULL);
--
2.17.1
More information about the amd-gfx
mailing list