projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6a591a9
)
drm/vmwgfx: Make sure to unpin old and pin new framebuffer.
author
Jakob Bornecrantz
<
[email protected]
>
Fri, 28 May 2010 09:21:56 +0000
(11:21 +0200)
committer
Dave Airlie
<
[email protected]
>
Mon, 31 May 2010 23:37:09 +0000
(09:37 +1000)
Signed-off-by: Jakob Bornecrantz <
[email protected]
>
Signed-off-by: Thomas Hellstrom <
[email protected]
>
Signed-off-by: Dave Airlie <
[email protected]
>
drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c
b/drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c
index a348fec221376bec8e45dc8bfafd573d69133d70..e1b3cf539b4a18b3a5fea2407e17ee3c39eaba00 100644
(file)
--- a/
drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c
+++ b/
drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c
@@
-150,6
+150,15
@@
static int vmw_ldu_add_active(struct vmw_private *vmw_priv,
struct vmw_legacy_display_unit *entry;
struct list_head *at;
+ BUG_ON(!ld->num_active && ld->fb);
+ if (vfb != ld->fb) {
+ if (ld->fb && ld->fb->unpin)
+ ld->fb->unpin(ld->fb);
+ if (vfb->pin)
+ vfb->pin(vfb);
+ ld->fb = vfb;
+ }
+
if (!list_empty(&ldu->active))
return 0;
@@
-162,12
+171,8
@@
static int vmw_ldu_add_active(struct vmw_private *vmw_priv,
}
list_add(&ldu->active, at);
- if (ld->num_active++ == 0) {
- BUG_ON(ld->fb);
- if (vfb->pin)
- vfb->pin(vfb);
- ld->fb = vfb;
- }
+
+ ld->num_active++;
return 0;
}