From 58bbe25523e607f5c22411107a6db9f517712cef Mon Sep 17 00:00:00 2001 From: Martin Pieuchot Date: Thu, 8 Aug 2013 18:23:46 +0200 Subject: If the AGP aperture base address is 0 assume that the bridge does not support remapping for processor accesses. In this case do not map the GTT. --- sys/dev/pci/drm/radeon/radeon_agp.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'sys/dev/pci/drm/radeon/radeon_agp.c') diff --git a/sys/dev/pci/drm/radeon/radeon_agp.c b/sys/dev/pci/drm/radeon/radeon_agp.c index 885a060e8b1..fdc140b1c66 100644 --- a/sys/dev/pci/drm/radeon/radeon_agp.c +++ b/sys/dev/pci/drm/radeon/radeon_agp.c @@ -251,9 +251,11 @@ int radeon_agp_init(struct radeon_device *rdev) dev_info(rdev->dev, "GTT: %lluM 0x%08llX - 0x%08llX\n", rdev->mc.gtt_size >> 20, rdev->mc.gtt_start, rdev->mc.gtt_end); - start = atop(bus_space_mmap(rdev->memt, rdev->mc.gtt_start, 0, 0, 0)); - end = start + atop(rdev->mc.gtt_size); - uvm_page_physload(start, end, start, end, PHYSLOAD_DEVICE); + if (!rdev->ddev->agp->cant_use_aperture) { + start = atop(bus_space_mmap(rdev->memt, rdev->mc.gtt_start, 0, 0, 0)); + end = start + atop(rdev->mc.gtt_size); + uvm_page_physload(start, end, start, end, PHYSLOAD_DEVICE); + } /* workaround some hw issues */ if (rdev->family < CHIP_R200) { -- cgit v1.2.3