diff options
Diffstat (limited to 'drivers/gpu/drm/nouveau/nv50_fb.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nv50_fb.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nv50_fb.c b/drivers/gpu/drm/nouveau/nv50_fb.c index bdd2afe29205..f1e4b9e07d14 100644 --- a/drivers/gpu/drm/nouveau/nv50_fb.c +++ b/drivers/gpu/drm/nouveau/nv50_fb.c | |||
@@ -2,6 +2,7 @@ | |||
2 | #include "drm.h" | 2 | #include "drm.h" |
3 | #include "nouveau_drv.h" | 3 | #include "nouveau_drv.h" |
4 | #include "nouveau_drm.h" | 4 | #include "nouveau_drm.h" |
5 | #include "nouveau_fifo.h" | ||
5 | 6 | ||
6 | struct nv50_fb_priv { | 7 | struct nv50_fb_priv { |
7 | struct page *r100c08_page; | 8 | struct page *r100c08_page; |
@@ -212,6 +213,7 @@ static struct nouveau_enum vm_fault[] = { | |||
212 | void | 213 | void |
213 | nv50_fb_vm_trap(struct drm_device *dev, int display) | 214 | nv50_fb_vm_trap(struct drm_device *dev, int display) |
214 | { | 215 | { |
216 | struct nouveau_fifo_priv *pfifo = nv_engine(dev, NVOBJ_ENGINE_FIFO); | ||
215 | struct drm_nouveau_private *dev_priv = dev->dev_private; | 217 | struct drm_nouveau_private *dev_priv = dev->dev_private; |
216 | const struct nouveau_enum *en, *cl; | 218 | const struct nouveau_enum *en, *cl; |
217 | unsigned long flags; | 219 | unsigned long flags; |
@@ -236,7 +238,7 @@ nv50_fb_vm_trap(struct drm_device *dev, int display) | |||
236 | /* lookup channel id */ | 238 | /* lookup channel id */ |
237 | chinst = (trap[2] << 16) | trap[1]; | 239 | chinst = (trap[2] << 16) | trap[1]; |
238 | spin_lock_irqsave(&dev_priv->channels.lock, flags); | 240 | spin_lock_irqsave(&dev_priv->channels.lock, flags); |
239 | for (ch = 0; ch < dev_priv->engine.fifo.channels; ch++) { | 241 | for (ch = 0; ch < pfifo->channels; ch++) { |
240 | struct nouveau_channel *chan = dev_priv->channels.ptr[ch]; | 242 | struct nouveau_channel *chan = dev_priv->channels.ptr[ch]; |
241 | 243 | ||
242 | if (!chan || !chan->ramin) | 244 | if (!chan || !chan->ramin) |