drm/radeon: fix R600_PTE_GART handling

That didn't worked correctly any more and opened up a security problem.

Signed-off-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Christian König
2014-07-22 17:42:20 +02:00
committed by Alex Deucher
parent ed5cb43f8f
commit 33fa9fe3dd
3 changed files with 5 additions and 7 deletions

View File

@@ -771,8 +771,7 @@ void cik_sdma_vm_set_page(struct radeon_device *rdev,
trace_radeon_vm_set_page(pe, addr, count, incr, flags);
/* XXX: How to distinguish between GART and other system memory pages? */
if (flags & R600_PTE_SYSTEM) {
if ((flags & R600_PTE_GART_MASK) == R600_PTE_GART_MASK) {
uint64_t src = rdev->gart.table_addr + (addr >> 12) * 8;
while (count) {
unsigned bytes = count * 8;