From 5f846360c46f5a989f5d0fde6d251cdbd61d4968 Mon Sep 17 00:00:00 2001 From: Alex Deucher Date: Wed, 7 Oct 2009 17:01:55 -0400 Subject: radeon: clamp the internal FB map to the aperture size We don't use the invisible memory yet and on cards with large amounts of vram this can cause the top of GART calculation to overflow. Fixes bug fdo bug 24301: http://bugs.freedesktop.org/show_bug.cgi?id=24301 --- src/radeon_driver.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/radeon_driver.c b/src/radeon_driver.c index d039920..d5704d3 100644 --- a/src/radeon_driver.c +++ b/src/radeon_driver.c @@ -1403,6 +1403,15 @@ static void RADEONInitMemoryMap(ScrnInfoPtr pScrn) if (aper_size > mem_size) mem_size = aper_size; + /* don't map the whole FB in the internal address space. + * we don't currently use fb space larger than the aperture + * size and on cards with 1 GB of vram, this can overflow + * the internal top of gart calculation on some systems. + * See fdo bug 24301. + */ + if (mem_size > aper_size) + mem_size = aper_size; + #ifdef XF86DRI /* Apply memory map limitation if using an old DRI */ if (info->directRenderingEnabled && !info->dri->newMemoryMap) { -- cgit v1.2.3