aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/radeon_ttm.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_ttm.c')
-rw-r--r--drivers/gpu/drm/radeon/radeon_ttm.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon/radeon_ttm.c
index 1882025a9dc..c421e77ace7 100644
--- a/drivers/gpu/drm/radeon/radeon_ttm.c
+++ b/drivers/gpu/drm/radeon/radeon_ttm.c
@@ -618,6 +618,11 @@ static int radeon_ttm_tt_populate(struct ttm_tt *ttm)
618 return 0; 618 return 0;
619 619
620 rdev = radeon_get_rdev(ttm->bdev); 620 rdev = radeon_get_rdev(ttm->bdev);
621#if __OS_HAS_AGP
622 if (rdev->flags & RADEON_IS_AGP) {
623 return ttm_agp_tt_populate(ttm);
624 }
625#endif
621 626
622#ifdef CONFIG_SWIOTLB 627#ifdef CONFIG_SWIOTLB
623 if (swiotlb_nr_tbl()) { 628 if (swiotlb_nr_tbl()) {
@@ -654,6 +659,12 @@ static void radeon_ttm_tt_unpopulate(struct ttm_tt *ttm)
654 unsigned i; 659 unsigned i;
655 660
656 rdev = radeon_get_rdev(ttm->bdev); 661 rdev = radeon_get_rdev(ttm->bdev);
662#if __OS_HAS_AGP
663 if (rdev->flags & RADEON_IS_AGP) {
664 ttm_agp_tt_unpopulate(ttm);
665 return;
666 }
667#endif
657 668
658#ifdef CONFIG_SWIOTLB 669#ifdef CONFIG_SWIOTLB
659 if (swiotlb_nr_tbl()) { 670 if (swiotlb_nr_tbl()) {