aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_gart.h
diff options
context:
space:
mode:
authorMichel Dänzer <michel.daenzer@amd.com>2018-06-22 12:54:03 -0400
committerAlex Deucher <alexander.deucher@amd.com>2018-07-05 17:39:49 -0400
commit463d2fe85b0eacb3760febe100994d4eb8fedde9 (patch)
tree5d8feff37c8b1d8903f64402b86549b169c55c3c /drivers/gpu/drm/amd/amdgpu/amdgpu_gart.h
parent9735bf1930e658b074d72ea46bb317ad12483692 (diff)
drm/amdgpu: Add AMDGPU_GPU_PAGES_IN_CPU_PAGE define
To hopefully make the code dealing with GPU vs CPU pages a little clearer. Suggested-by: Christian König <christian.koenig@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Michel Dänzer <michel.daenzer@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_gart.h')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_gart.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gart.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_gart.h
index 456295c00291..9f9e9dc87da1 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gart.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gart.h
@@ -37,6 +37,8 @@ struct amdgpu_bo;
37#define AMDGPU_GPU_PAGE_SHIFT 12 37#define AMDGPU_GPU_PAGE_SHIFT 12
38#define AMDGPU_GPU_PAGE_ALIGN(a) (((a) + AMDGPU_GPU_PAGE_MASK) & ~AMDGPU_GPU_PAGE_MASK) 38#define AMDGPU_GPU_PAGE_ALIGN(a) (((a) + AMDGPU_GPU_PAGE_MASK) & ~AMDGPU_GPU_PAGE_MASK)
39 39
40#define AMDGPU_GPU_PAGES_IN_CPU_PAGE (PAGE_SIZE / AMDGPU_GPU_PAGE_SIZE)
41
40struct amdgpu_gart { 42struct amdgpu_gart {
41 u64 table_addr; 43 u64 table_addr;
42 struct amdgpu_bo *robj; 44 struct amdgpu_bo *robj;