summaryrefslogtreecommitdiff
path: root/shared-core/nouveau_irq.c
diff options
context:
space:
mode:
Diffstat (limited to 'shared-core/nouveau_irq.c')
-rw-r--r--shared-core/nouveau_irq.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/shared-core/nouveau_irq.c b/shared-core/nouveau_irq.c
index 427ef474..3c0d192c 100644
--- a/shared-core/nouveau_irq.c
+++ b/shared-core/nouveau_irq.c
@@ -201,7 +201,7 @@ static int
nouveau_graph_chid_from_grctx(struct drm_device *dev)
{
struct drm_nouveau_private *dev_priv = dev->dev_private;
- uint32_t inst;
+ uint32_t inst, tmp;
int i;
if (dev_priv->card_type < NV_40)
@@ -222,7 +222,11 @@ nouveau_graph_chid_from_grctx(struct drm_device *dev)
if (inst == chan->ramin_grctx->instance)
break;
} else {
- if (inst == INSTANCE_RD(chan->ramin_grctx->gpuobj, 0))
+ dev_priv->engine.instmem.prepare_access(dev, false);
+ tmp = INSTANCE_RD(chan->ramin_grctx->gpuobj, 0);
+ dev_priv->engine.instmem.finish_access(dev);
+
+ if (inst == tmp)
break;
}
}