summaryrefslogtreecommitdiffstats
path: root/drivers/char/drm/radeon_cp.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dtor_core@ameritech.net>2005-12-21 05:03:50 +0100
committerDmitry Torokhov <dtor_core@ameritech.net>2005-12-21 05:03:50 +0100
commit041387d98460b3947587929ef3a4773b8c48538f (patch)
tree3330eebba3fa1aa7c13479e527f07b03d7fb53ed /drivers/char/drm/radeon_cp.c
parentInput: add the fn key to hid-debug.h (diff)
parentMerge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 (diff)
downloadlinux-041387d98460b3947587929ef3a4773b8c48538f.tar.xz
linux-041387d98460b3947587929ef3a4773b8c48538f.zip
Manual merge with Linus (conflict in drivers/input/misc/wistron_bnts.c)
Diffstat (limited to 'drivers/char/drm/radeon_cp.c')
-rw-r--r--drivers/char/drm/radeon_cp.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/drivers/char/drm/radeon_cp.c b/drivers/char/drm/radeon_cp.c
index 03839ea31092..501e557cbc86 100644
--- a/drivers/char/drm/radeon_cp.c
+++ b/drivers/char/drm/radeon_cp.c
@@ -1311,7 +1311,9 @@ static void radeon_set_pcigart(drm_radeon_private_t * dev_priv, int on)
static int radeon_do_init_cp(drm_device_t * dev, drm_radeon_init_t * init)
{
- drm_radeon_private_t *dev_priv = dev->dev_private;;
+ drm_radeon_private_t *dev_priv = dev->dev_private;
+ unsigned int mem_size;
+
DRM_DEBUG("\n");
dev_priv->is_pci = init->is_pci;
@@ -1521,8 +1523,11 @@ static int radeon_do_init_cp(drm_device_t * dev, drm_radeon_init_t * init)
+ dev_priv->fb_location) >> 10));
dev_priv->gart_size = init->gart_size;
- dev_priv->gart_vm_start = dev_priv->fb_location
- + RADEON_READ(RADEON_CONFIG_APER_SIZE);
+
+ mem_size = RADEON_READ(RADEON_CONFIG_MEMSIZE);
+ if (mem_size == 0)
+ mem_size = 0x800000;
+ dev_priv->gart_vm_start = dev_priv->fb_location + mem_size;
#if __OS_HAS_AGP
if (!dev_priv->is_pci)