summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2008-08-06 15:59:31 +1000
committerDave Airlie <airlied@redhat.com>2008-08-06 15:59:31 +1000
commit8c042a0b0531117f2663ae6932d299cb47941607 (patch)
tree14847297f68adcf3a98e5cab609455159fc88449
parent64359586730268fc83ccc0db0487e217a894335b (diff)
radeon: fixup PCI GART table with GEM enabled
-rw-r--r--linux-core/radeon_gem.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/linux-core/radeon_gem.c b/linux-core/radeon_gem.c
index 1aa3afbf..1ee48514 100644
--- a/linux-core/radeon_gem.c
+++ b/linux-core/radeon_gem.c
@@ -485,6 +485,7 @@ static int radeon_gart_init(struct drm_device *dev)
/* setup a 32MB GART */
dev_priv->gart_size = dev_priv->mm.gart_size;
+ dev_priv->gart_info.table_size = RADEON_PCIGART_TABLE_SIZE;
#if __OS_HAS_AGP
/* setup VRAM vs GART here */
@@ -547,8 +548,8 @@ static int radeon_gart_init(struct drm_device *dev)
dev_priv->gart_info.gart_reg_if = DRM_ATI_GART_IGP;
else
dev_priv->gart_info.gart_reg_if = DRM_ATI_GART_PCI;
- dev_priv->gart_info.addr = NULL;
- dev_priv->gart_info.bus_addr = 0;
+ dev_priv->gart_info.addr = dev_priv->gart_info.table_handle->vaddr;
+ dev_priv->gart_info.bus_addr = dev_priv->gart_info.table_handle->busaddr;
}
/* gart values setup - start the GART */
@@ -843,7 +844,7 @@ static int radeon_gem_ib_init(struct drm_device *dev)
if (!dev_priv->ib_objs)
goto free_all;
- for (i = 0; i < RADEON_NUM_IB; i++) {
+ for (i = 0; i < RADEON_NUM_IB; i++) {
dev_priv->ib_objs[i] = drm_calloc(1, sizeof(struct radeon_mm_obj), DRM_MEM_DRIVER);
if (!dev_priv->ib_objs[i])
goto free_all;