aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau/nvkm/engine/fifo/channv50.c
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2017-11-01 03:56:20 +1000
committerBen Skeggs <bskeggs@redhat.com>2017-11-02 13:32:33 +1000
commit832ca2ac3c95feb01e53c24fcd1a00b4cf05cbdc (patch)
treeec1505569b8cd26f590d2a2707724ee36602e2f8 /drivers/gpu/drm/nouveau/nvkm/engine/fifo/channv50.c
parentdrm/nouveau: switch to vmm limit (diff)
downloadlinux-dev-832ca2ac3c95feb01e53c24fcd1a00b4cf05cbdc.tar.xz
linux-dev-832ca2ac3c95feb01e53c24fcd1a00b4cf05cbdc.zip
drm/nouveau: pass handle of vmm object to channel allocation ioctls
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nvkm/engine/fifo/channv50.c')
-rw-r--r--drivers/gpu/drm/nouveau/nvkm/engine/fifo/channv50.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/channv50.c b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/channv50.c
index 01453279dbc0..85f7dbf53c99 100644
--- a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/channv50.c
+++ b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/channv50.c
@@ -228,15 +228,18 @@ nv50_fifo_chan_func = {
};
int
-nv50_fifo_chan_ctor(struct nv50_fifo *fifo, u64 vm, u64 push,
+nv50_fifo_chan_ctor(struct nv50_fifo *fifo, u64 vmm, u64 push,
const struct nvkm_oclass *oclass,
struct nv50_fifo_chan *chan)
{
struct nvkm_device *device = fifo->base.engine.subdev.device;
int ret;
+ if (!vmm)
+ return -EINVAL;
+
ret = nvkm_fifo_chan_ctor(&nv50_fifo_chan_func, &fifo->base,
- 0x10000, 0x1000, false, vm, push,
+ 0x10000, 0x1000, false, vmm, push,
(1ULL << NVKM_ENGINE_DMAOBJ) |
(1ULL << NVKM_ENGINE_SW) |
(1ULL << NVKM_ENGINE_GR) |