diff options
author | Michel Dänzer <michel.daenzer@amd.com> | 2015-01-21 17:36:37 +0900 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2015-01-22 11:48:03 -0500 |
commit | 16653dbae06609b9d0a7427de6c7f4c98d76523c (patch) | |
tree | 09980f77c2973cbcaefd3036fba4de248550093e /drivers/gpu/drm/radeon/radeon_vm.c | |
parent | 5636d2f842c7bd7800002868ead3d6b809d385a0 (diff) | |
download | talos-obmc-linux-16653dbae06609b9d0a7427de6c7f4c98d76523c.tar.gz talos-obmc-linux-16653dbae06609b9d0a7427de6c7f4c98d76523c.zip |
drm/radeon: Remove rdev->gart.pages_addr array
radeon_vm_map_gart can use rdev->gart.pages_entry instead.
Also move the masking of the page address to radeon_vm_map_gart from its
callers.
Reviewed-by: Christian König <christian.koenig@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/radeon/radeon_vm.c')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_vm.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_vm.c b/drivers/gpu/drm/radeon/radeon_vm.c index cde48c42b30a..06d2246d07f1 100644 --- a/drivers/gpu/drm/radeon/radeon_vm.c +++ b/drivers/gpu/drm/radeon/radeon_vm.c @@ -587,10 +587,8 @@ uint64_t radeon_vm_map_gart(struct radeon_device *rdev, uint64_t addr) uint64_t result; /* page table offset */ - result = rdev->gart.pages_addr[addr >> PAGE_SHIFT]; - - /* in case cpu page size != gpu page size*/ - result |= addr & (~PAGE_MASK); + result = rdev->gart.pages_entry[addr >> RADEON_GPU_PAGE_SHIFT]; + result &= ~RADEON_GPU_PAGE_MASK; return result; } |