summaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2012-01-24 11:03:14 +1000
committerBen Skeggs <bskeggs@redhat.com>2012-03-13 17:08:51 +1000
commit0ce71415587b1fd56f67294ac46f860b8b679b95 (patch)
treef039e53e3247f71871ba992d388f57210ecde290 /drivers/gpu
parent1a7287ea6f37c930a092123f6584b0b24cfe2d13 (diff)
drm/nv50: fix detection of second vram rank
Goes a long way to correcting NVS295 memory reclocking issues. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Martin Peres <martin.peres@labri.fr>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/nouveau/nv50_vram.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nv50_vram.c b/drivers/gpu/drm/nouveau/nv50_vram.c
index a52b9a51e01..9ed9ae397d7 100644
--- a/drivers/gpu/drm/nouveau/nv50_vram.c
+++ b/drivers/gpu/drm/nouveau/nv50_vram.c
@@ -207,7 +207,7 @@ nv50_vram_init(struct drm_device *dev)
break;
}
- dev_priv->vram_rank_B = (nv_rd32(dev, NV04_PFB_CFG0) & 0x100) >> 8;
+ dev_priv->vram_rank_B = !!(nv_rd32(dev, 0x100200) & 0x4);
dev_priv->vram_size = nv_rd32(dev, 0x10020c);
dev_priv->vram_size |= (dev_priv->vram_size & 0xff) << 32;
dev_priv->vram_size &= 0xffffffff00ULL;