Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 281396
b: refs/heads/master
c: af69592
h: refs/heads/master
v: v3
  • Loading branch information
Rob Clark authored and Greg Kroah-Hartman committed Dec 16, 2011
1 parent b60b2ec commit f348c0a
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 510d4d32f25f49dedd7da88c29fdb4d0aada5815
refs/heads/master: af69592aa098ff8cd640e8109ba946db3c1cdb4e
16 changes: 14 additions & 2 deletions trunk/drivers/staging/omapdrm/omap_gem.c
Original file line number Diff line number Diff line change
Expand Up @@ -538,10 +538,22 @@ int omap_gem_roll(struct drm_gem_object *obj, uint32_t roll)
return -EINVAL;
}

mutex_lock(&obj->dev->struct_mutex);

omap_obj->roll = roll;

if (in_atomic() || mutex_is_locked(&obj->dev->struct_mutex)) {
/* this can get called from fbcon in atomic context.. so
* just ignore it and wait for next time called from
* interruptible context to update the PAT.. the result
* may be that user sees wrap-around instead of scrolling
* momentarily on the screen. If we wanted to be fancier
* we could perhaps schedule some workqueue work at this
* point.
*/
return 0;
}

mutex_lock(&obj->dev->struct_mutex);

/* if we aren't mapped yet, we don't need to do anything */
if (omap_obj->block) {
struct page **pages;
Expand Down

0 comments on commit f348c0a

Please sign in to comment.