Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 286851
b: refs/heads/master
c: 93b525d
h: refs/heads/master
i:
  286849: 7915d36
  286847: db1b22e
v: v3
  • Loading branch information
Daniel Vetter authored and Keith Packard committed Jan 25, 2012
1 parent 0a5a73e commit b6ee036
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 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: 48467a92215ced69a65c89c1b064dd84728a5ed0
refs/heads/master: 93b525dccf212e50a895792d79d64bdb53312f5c
11 changes: 8 additions & 3 deletions trunk/drivers/gpu/drm/i915/i915_debugfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -1075,16 +1075,21 @@ static int gen6_drpc_info(struct seq_file *m)
struct drm_device *dev = node->minor->dev;
struct drm_i915_private *dev_priv = dev->dev_private;
u32 rpmodectl1, gt_core_status, rcctl1;
unsigned forcewake_count;
int count=0, ret;


ret = mutex_lock_interruptible(&dev->struct_mutex);
if (ret)
return ret;

if (atomic_read(&dev_priv->forcewake_count)) {
seq_printf(m, "RC information inaccurate because userspace "
"holds a reference \n");
spin_lock_irq(&dev_priv->gt_lock);
forcewake_count = dev_priv->forcewake_count;
spin_unlock_irq(&dev_priv->gt_lock);

if (forcewake_count) {
seq_printf(m, "RC information inaccurate because somebody "
"holds a forcewake reference \n");
} else {
/* NB: we cannot use forcewake, else we read the wrong values */
while (count++ < 50 && (I915_READ_NOTRACE(FORCEWAKE_ACK) & 1))
Expand Down

0 comments on commit b6ee036

Please sign in to comment.