diff options
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_irq.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nouveau_irq.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_irq.c b/drivers/gpu/drm/nouveau/nouveau_irq.c index 794b0ee30cf6..9cc3259a54b9 100644 --- a/drivers/gpu/drm/nouveau/nouveau_irq.c +++ b/drivers/gpu/drm/nouveau/nouveau_irq.c | |||
@@ -35,6 +35,7 @@ | |||
35 | #include "nouveau_drm.h" | 35 | #include "nouveau_drm.h" |
36 | #include "nouveau_drv.h" | 36 | #include "nouveau_drv.h" |
37 | #include "nouveau_reg.h" | 37 | #include "nouveau_reg.h" |
38 | #include "nouveau_ramht.h" | ||
38 | #include <linux/ratelimit.h> | 39 | #include <linux/ratelimit.h> |
39 | 40 | ||
40 | /* needed for hotplug irq */ | 41 | /* needed for hotplug irq */ |
@@ -106,15 +107,16 @@ nouveau_fifo_swmthd(struct nouveau_channel *chan, uint32_t addr, uint32_t data) | |||
106 | const int mthd = addr & 0x1ffc; | 107 | const int mthd = addr & 0x1ffc; |
107 | 108 | ||
108 | if (mthd == 0x0000) { | 109 | if (mthd == 0x0000) { |
109 | struct nouveau_gpuobj_ref *ref = NULL; | 110 | struct nouveau_gpuobj *gpuobj; |
110 | 111 | ||
111 | if (nouveau_gpuobj_ref_find(chan, data, &ref)) | 112 | gpuobj = nouveau_ramht_find(chan, data); |
113 | if (!gpuobj) | ||
112 | return false; | 114 | return false; |
113 | 115 | ||
114 | if (ref->gpuobj->engine != NVOBJ_ENGINE_SW) | 116 | if (gpuobj->engine != NVOBJ_ENGINE_SW) |
115 | return false; | 117 | return false; |
116 | 118 | ||
117 | chan->sw_subchannel[subc] = ref->gpuobj->class; | 119 | chan->sw_subchannel[subc] = gpuobj->class; |
118 | nv_wr32(dev, NV04_PFIFO_CACHE1_ENGINE, nv_rd32(dev, | 120 | nv_wr32(dev, NV04_PFIFO_CACHE1_ENGINE, nv_rd32(dev, |
119 | NV04_PFIFO_CACHE1_ENGINE) & ~(0xf << subc * 4)); | 121 | NV04_PFIFO_CACHE1_ENGINE) & ~(0xf << subc * 4)); |
120 | return true; | 122 | return true; |
@@ -357,7 +359,7 @@ nouveau_graph_chid_from_grctx(struct drm_device *dev) | |||
357 | if (!chan || !chan->ramin_grctx) | 359 | if (!chan || !chan->ramin_grctx) |
358 | continue; | 360 | continue; |
359 | 361 | ||
360 | if (inst == chan->ramin_grctx->instance) | 362 | if (inst == chan->ramin_grctx->pinst) |
361 | break; | 363 | break; |
362 | } | 364 | } |
363 | } else { | 365 | } else { |
@@ -369,7 +371,7 @@ nouveau_graph_chid_from_grctx(struct drm_device *dev) | |||
369 | if (!chan || !chan->ramin) | 371 | if (!chan || !chan->ramin) |
370 | continue; | 372 | continue; |
371 | 373 | ||
372 | if (inst == chan->ramin->instance) | 374 | if (inst == chan->ramin->vinst) |
373 | break; | 375 | break; |
374 | } | 376 | } |
375 | } | 377 | } |
@@ -625,7 +627,7 @@ nv50_pfb_vm_trap(struct drm_device *dev, int display, const char *name) | |||
625 | if (!chan || !chan->ramin) | 627 | if (!chan || !chan->ramin) |
626 | continue; | 628 | continue; |
627 | 629 | ||
628 | if (trap[1] == chan->ramin->instance >> 12) | 630 | if (trap[1] == chan->ramin->vinst >> 12) |
629 | break; | 631 | break; |
630 | } | 632 | } |
631 | NV_INFO(dev, "%s - VM: Trapped %s at %02x%04x%04x status %08x %08x channel %d\n", | 633 | NV_INFO(dev, "%s - VM: Trapped %s at %02x%04x%04x status %08x %08x channel %d\n", |