diff options
author | Jérôme Glisse <jglisse@redhat.com> | 2017-08-04 17:26:58 -0400 |
---|---|---|
committer | Jérôme Glisse <jglisse@redhat.com> | 2017-08-29 10:35:01 -0400 |
commit | f40471939f9a45a04d819881de535ff4afb6085a (patch) | |
tree | f5cbbb10dbca5910445e263e0144ca3eba4c6b66 /drivers/gpu/drm/nouveau/compote/compote.h | |
parent | a3cb1db3b4fbcab074ab98b3e9e07624abd5d65d (diff) |
drm/nouveau/compote: add channel support
Channel infrastructure.
Signed-off-by: Jérôme Glisse <jglisse@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/compote/compote.h')
-rw-r--r-- | drivers/gpu/drm/nouveau/compote/compote.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/compote/compote.h b/drivers/gpu/drm/nouveau/compote/compote.h index 4d9d2166faf4..0a37d0a1922d 100644 --- a/drivers/gpu/drm/nouveau/compote/compote.h +++ b/drivers/gpu/drm/nouveau/compote/compote.h @@ -33,6 +33,8 @@ struct compote_file { struct compote_device *cdevice; struct file *file; struct nouveau_cli nvclient; + struct list_head channels; + struct rw_semaphore rwsem; }; struct compote_mo { @@ -53,9 +55,21 @@ struct compote_mo_va { const struct vm_operations_struct *ttm_vm_ops; }; +struct compote_channel { + struct list_head list; + struct compote_file *cfile; + struct nouveau_channel *nvchan; + struct kref kref; +}; + long compote_ioctl_mem_alloc(struct compote_file *cfile, void __user *uarg); long compote_ioctl_mem_free(struct compote_file *cfile, void __user *uarg); +int compote_ioctl_channel_alloc(struct compote_file *cfile, void __user *uarg); +int compote_ioctl_channel_free(struct compote_file *cfile, void __user *uarg); +void compote_channel_ref(struct compote_channel *channel); +void compote_channel_unref(struct compote_channel *channel); + void compote_mo_ref(struct compote_mo *mo); void compote_mo_unref(struct compote_mo *mo); int compote_mo_mmap(struct compote_file *cfile, |