Lines Matching refs:abi16

44 	if (!cli->abi16) {  in nouveau_abi16()
45 struct nouveau_abi16 *abi16; in nouveau_abi16() local
46 cli->abi16 = abi16 = kzalloc(sizeof(*abi16), GFP_KERNEL); in nouveau_abi16()
47 if (cli->abi16) { in nouveau_abi16()
52 INIT_LIST_HEAD(&abi16->channels); in nouveau_abi16()
60 &abi16->device) == 0) in nouveau_abi16()
61 return cli->abi16; in nouveau_abi16()
63 kfree(cli->abi16); in nouveau_abi16()
64 cli->abi16 = NULL; in nouveau_abi16()
67 return cli->abi16; in nouveau_abi16()
76 return cli->abi16; in nouveau_abi16_get()
82 nouveau_abi16_put(struct nouveau_abi16 *abi16, int ret) in nouveau_abi16_put() argument
84 struct nouveau_cli *cli = (void *)abi16->device.object.client; in nouveau_abi16_put()
124 nouveau_abi16_chan_fini(struct nouveau_abi16 *abi16, in nouveau_abi16_chan_fini() argument
159 nouveau_abi16_fini(struct nouveau_abi16 *abi16) in nouveau_abi16_fini() argument
161 struct nouveau_cli *cli = (void *)abi16->device.object.client; in nouveau_abi16_fini()
165 list_for_each_entry_safe(chan, temp, &abi16->channels, head) { in nouveau_abi16_fini()
166 nouveau_abi16_chan_fini(abi16, chan); in nouveau_abi16_fini()
170 nvif_device_dtor(&abi16->device); in nouveau_abi16_fini()
172 kfree(cli->abi16); in nouveau_abi16_fini()
173 cli->abi16 = NULL; in nouveau_abi16_fini()
253 struct nouveau_abi16 *abi16 = nouveau_abi16_get(file_priv); in nouveau_abi16_ioctl_channel_alloc() local
259 if (unlikely(!abi16)) in nouveau_abi16_ioctl_channel_alloc()
263 return nouveau_abi16_put(abi16, -ENODEV); in nouveau_abi16_ioctl_channel_alloc()
265 device = &abi16->device; in nouveau_abi16_ioctl_channel_alloc()
277 return nouveau_abi16_put(abi16, -ENOSYS); in nouveau_abi16_ioctl_channel_alloc()
292 return nouveau_abi16_put(abi16, -EINVAL); in nouveau_abi16_ioctl_channel_alloc()
297 return nouveau_abi16_put(abi16, -ENOMEM); in nouveau_abi16_ioctl_channel_alloc()
300 list_add(&chan->head, &abi16->channels); in nouveau_abi16_ioctl_channel_alloc()
351 nouveau_abi16_chan_fini(abi16, chan); in nouveau_abi16_ioctl_channel_alloc()
352 return nouveau_abi16_put(abi16, ret); in nouveau_abi16_ioctl_channel_alloc()
356 nouveau_abi16_chan(struct nouveau_abi16 *abi16, int channel) in nouveau_abi16_chan() argument
360 list_for_each_entry(chan, &abi16->channels, head) { in nouveau_abi16_chan()
375 struct nouveau_abi16 *abi16; in nouveau_abi16_usif() local
390 if (!(abi16 = nouveau_abi16(file_priv))) in nouveau_abi16_usif()
394 if (!(chan = nouveau_abi16_chan(abi16, args->v0.token))) in nouveau_abi16_usif()
401 args->v0.object = nvif_handle(&abi16->device.object); in nouveau_abi16_usif()
410 struct nouveau_abi16 *abi16 = nouveau_abi16_get(file_priv); in nouveau_abi16_ioctl_channel_free() local
413 if (unlikely(!abi16)) in nouveau_abi16_ioctl_channel_free()
416 chan = nouveau_abi16_chan(abi16, req->channel); in nouveau_abi16_ioctl_channel_free()
418 return nouveau_abi16_put(abi16, -ENOENT); in nouveau_abi16_ioctl_channel_free()
419 nouveau_abi16_chan_fini(abi16, chan); in nouveau_abi16_ioctl_channel_free()
420 return nouveau_abi16_put(abi16, 0); in nouveau_abi16_ioctl_channel_free()
427 struct nouveau_abi16 *abi16 = nouveau_abi16_get(file_priv); in nouveau_abi16_ioctl_grobj_alloc() local
435 if (unlikely(!abi16)) in nouveau_abi16_ioctl_grobj_alloc()
439 return nouveau_abi16_put(abi16, -EINVAL); in nouveau_abi16_ioctl_grobj_alloc()
440 client = abi16->device.object.client; in nouveau_abi16_ioctl_grobj_alloc()
442 chan = nouveau_abi16_chan(abi16, init->channel); in nouveau_abi16_ioctl_grobj_alloc()
444 return nouveau_abi16_put(abi16, -ENOENT); in nouveau_abi16_ioctl_grobj_alloc()
448 return nouveau_abi16_put(abi16, ret); in nouveau_abi16_ioctl_grobj_alloc()
497 return nouveau_abi16_put(abi16, -EINVAL); in nouveau_abi16_ioctl_grobj_alloc()
501 return nouveau_abi16_put(abi16, -ENOMEM); in nouveau_abi16_ioctl_grobj_alloc()
512 return nouveau_abi16_put(abi16, ret); in nouveau_abi16_ioctl_grobj_alloc()
520 struct nouveau_abi16 *abi16 = nouveau_abi16_get(file_priv); in nouveau_abi16_ioctl_notifierobj_alloc() local
523 struct nvif_device *device = &abi16->device; in nouveau_abi16_ioctl_notifierobj_alloc()
528 if (unlikely(!abi16)) in nouveau_abi16_ioctl_notifierobj_alloc()
533 return nouveau_abi16_put(abi16, -EINVAL); in nouveau_abi16_ioctl_notifierobj_alloc()
534 client = abi16->device.object.client; in nouveau_abi16_ioctl_notifierobj_alloc()
536 chan = nouveau_abi16_chan(abi16, info->channel); in nouveau_abi16_ioctl_notifierobj_alloc()
538 return nouveau_abi16_put(abi16, -ENOENT); in nouveau_abi16_ioctl_notifierobj_alloc()
542 return nouveau_abi16_put(abi16, -ENOMEM); in nouveau_abi16_ioctl_notifierobj_alloc()
585 return nouveau_abi16_put(abi16, ret); in nouveau_abi16_ioctl_notifierobj_alloc()
592 struct nouveau_abi16 *abi16 = nouveau_abi16_get(file_priv); in nouveau_abi16_ioctl_gpuobj_free() local
597 if (unlikely(!abi16)) in nouveau_abi16_ioctl_gpuobj_free()
600 chan = nouveau_abi16_chan(abi16, fini->channel); in nouveau_abi16_ioctl_gpuobj_free()
602 return nouveau_abi16_put(abi16, -EINVAL); in nouveau_abi16_ioctl_gpuobj_free()
615 return nouveau_abi16_put(abi16, ret); in nouveau_abi16_ioctl_gpuobj_free()