aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/gma500/framebuffer.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2013-06-11 08:16:10 +1000
committerDave Airlie <airlied@redhat.com>2013-06-11 08:16:10 +1000
commite6eea1536e077b2b7bfc8c173f09d01ef72d2c7b (patch)
treeebc934628fdb13ddf521bbf6b565780245073098 /drivers/gpu/drm/gma500/framebuffer.c
parentab0296319a8cb970f4e42659472bb40fbfae3e56 (diff)
parent70b1304eeedf211fc9fa185b43350bd9ab4c119c (diff)
Merge branch 'gma500-fixes' of git://github.com/patjak/drm-gma500 into drm-fixes
Patrik writes: Two fixes for memory leaks split into Cedarview and Poulsbo versions, and a fix for properly setting the pipe base when using fbdev. It's on my todo-list to start unifying the chips since they are very similar, but until then I'd like to split them up in case there are side-effects on Cedarview that I cannot currently test. airled: Verified pull from github matches what I expected. * 'gma500-fixes' of git://github.com/patjak/drm-gma500: drm/gma500/cdv: Fix cursor gem obj referencing on cdv drm/gma500/psb: Fix cursor gem obj referencing on psb drm/gma500/cdv: Unpin framebuffer on crtc disable drm/gma500/psb: Unpin framebuffer on crtc disable drm/gma500: Add fb gtt offset to fb base
Diffstat (limited to 'drivers/gpu/drm/gma500/framebuffer.c')
-rw-r--r--drivers/gpu/drm/gma500/framebuffer.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/gma500/framebuffer.c b/drivers/gpu/drm/gma500/framebuffer.c
index 1534e220097..8b1b6d923ab 100644
--- a/drivers/gpu/drm/gma500/framebuffer.c
+++ b/drivers/gpu/drm/gma500/framebuffer.c
@@ -121,8 +121,8 @@ static int psbfb_vm_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
unsigned long address;
int ret;
unsigned long pfn;
- /* FIXME: assumes fb at stolen base which may not be true */
- unsigned long phys_addr = (unsigned long)dev_priv->stolen_base;
+ unsigned long phys_addr = (unsigned long)dev_priv->stolen_base +
+ psbfb->gtt->offset;
page_num = (vma->vm_end - vma->vm_start) >> PAGE_SHIFT;
address = (unsigned long)vmf->virtual_address - (vmf->pgoff << PAGE_SHIFT);