man: add drm.7 overview page
[profile/ivi/libdrm.git] / nouveau / abi16.c
index 688a9ac..a67fbc1 100644 (file)
@@ -31,13 +31,10 @@ int
 abi16_chan_nv04(struct nouveau_object *obj)
 {
        struct nouveau_device *dev = (struct nouveau_device *)obj->parent;
-       struct drm_nouveau_channel_alloc req;
        struct nv04_fifo *nv04 = obj->data;
+       struct drm_nouveau_channel_alloc req = {nv04->vram, nv04->gart};
        int ret;
 
-       req.fb_ctxdma_handle = nv04->vram;
-       req.tt_ctxdma_handle = nv04->gart;
-
        ret = drmCommandWriteRead(dev->fd, DRM_NOUVEAU_CHANNEL_ALLOC,
                                  &req, sizeof(req));
        if (ret)
@@ -55,7 +52,7 @@ int
 abi16_chan_nvc0(struct nouveau_object *obj)
 {
        struct nouveau_device *dev = (struct nouveau_device *)obj->parent;
-       struct drm_nouveau_channel_alloc req;
+       struct drm_nouveau_channel_alloc req = {};
        struct nvc0_fifo *nvc0 = obj->data;
        int ret;
 
@@ -66,6 +63,7 @@ abi16_chan_nvc0(struct nouveau_object *obj)
 
        nvc0->base.channel = req.channel;
        nvc0->base.pushbuf = req.pushbuf_domains;
+       nvc0->notify = req.notifier_handle;
        nvc0->base.object->handle = req.channel;
        nvc0->base.object->length = sizeof(*nvc0);
        return 0;