diff options
author | Maarten Lankhorst <maarten.lankhorst@canonical.com> | 2014-07-01 06:57:43 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-07-08 16:36:52 -0400 |
commit | 9b495a5887994a6d74d5c261d012083a92b94738 (patch) | |
tree | 513e525cdc0bbce66f76632058bf6379c368184e /include/linux/dma-buf.h | |
parent | 0ba6b8fb91fc051535c7612f6241c8197d92323b (diff) |
dma-buf: add poll support, v3
Thanks to Fengguang Wu for spotting a missing static cast.
v2:
- Kill unused variable need_shared.
v3:
- Clarify the BUG() in dma_buf_release some more. (Rob Clark)
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Acked-by: Sumit Semwal <sumit.semwal@linaro.org>
Acked-by: Daniel Vetter <daniel@ffwll.ch>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/dma-buf.h')
-rw-r--r-- | include/linux/dma-buf.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/include/linux/dma-buf.h b/include/linux/dma-buf.h index fd7def2e0ae2..694e1fe1c4b4 100644 --- a/include/linux/dma-buf.h +++ b/include/linux/dma-buf.h | |||
@@ -30,6 +30,8 @@ | |||
30 | #include <linux/list.h> | 30 | #include <linux/list.h> |
31 | #include <linux/dma-mapping.h> | 31 | #include <linux/dma-mapping.h> |
32 | #include <linux/fs.h> | 32 | #include <linux/fs.h> |
33 | #include <linux/fence.h> | ||
34 | #include <linux/wait.h> | ||
33 | 35 | ||
34 | struct device; | 36 | struct device; |
35 | struct dma_buf; | 37 | struct dma_buf; |
@@ -130,6 +132,16 @@ struct dma_buf { | |||
130 | struct list_head list_node; | 132 | struct list_head list_node; |
131 | void *priv; | 133 | void *priv; |
132 | struct reservation_object *resv; | 134 | struct reservation_object *resv; |
135 | |||
136 | /* poll support */ | ||
137 | wait_queue_head_t poll; | ||
138 | |||
139 | struct dma_buf_poll_cb_t { | ||
140 | struct fence_cb cb; | ||
141 | wait_queue_head_t *poll; | ||
142 | |||
143 | unsigned long active; | ||
144 | } cb_excl, cb_shared; | ||
133 | }; | 145 | }; |
134 | 146 | ||
135 | /** | 147 | /** |