diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2011-12-13 11:57:55 +1000 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2012-03-13 17:05:46 +1000 |
commit | c70c41e89f0481f26749d8264aebc594566c2a6d (patch) | |
tree | 9a112ff10ccbda529d70eecbedc5d763113846a0 /drivers/gpu/drm/nouveau/nv50_vram.c | |
parent | 1072856a1c604726be6a8adfb6b2c86033e6a314 (diff) | |
download | linux-c70c41e89f0481f26749d8264aebc594566c2a6d.tar.gz linux-c70c41e89f0481f26749d8264aebc594566c2a6d.tar.bz2 linux-c70c41e89f0481f26749d8264aebc594566c2a6d.zip |
drm/nv50: hopefully handle the DDR2/DDR3 memtype detection somewhat better
M version 2 appears to have a table with some form of memory type info
available.
NVIDIA appear to ignore the table information except for this DDR2/DDR3
case (which has the same value in 0x100714). My guess is this is due to
some of the supported memory types not being represented in the table.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nv50_vram.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nv50_vram.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/nouveau/nv50_vram.c b/drivers/gpu/drm/nouveau/nv50_vram.c index 840696694611..1467efc6d61d 100644 --- a/drivers/gpu/drm/nouveau/nv50_vram.c +++ b/drivers/gpu/drm/nouveau/nv50_vram.c @@ -195,10 +195,10 @@ nv50_vram_init(struct drm_device *dev) switch (pfb714 & 0x00000007) { case 0: dev_priv->vram_type = NV_MEM_TYPE_DDR1; break; case 1: - if (0 /* some currently unknown condition */) - dev_priv->vram_type = NV_MEM_TYPE_DDR2; - else + if (nouveau_mem_vbios_type(dev) == NV_MEM_TYPE_DDR3) dev_priv->vram_type = NV_MEM_TYPE_DDR3; + else + dev_priv->vram_type = NV_MEM_TYPE_DDR2; break; case 2: dev_priv->vram_type = NV_MEM_TYPE_GDDR3; break; case 3: dev_priv->vram_type = NV_MEM_TYPE_GDDR4; break; |