.. | .. |
---|
27 | 27 | #ifndef _VMWGFX_BINDING_H_ |
---|
28 | 28 | #define _VMWGFX_BINDING_H_ |
---|
29 | 29 | |
---|
30 | | -#include "device_include/svga3d_reg.h" |
---|
31 | 30 | #include <linux/list.h> |
---|
32 | 31 | |
---|
| 32 | +#include "device_include/svga3d_reg.h" |
---|
| 33 | + |
---|
33 | 34 | #define VMW_MAX_VIEW_BINDINGS 128 |
---|
| 35 | + |
---|
| 36 | +#define VMW_MAX_UAV_BIND_TYPE 2 |
---|
34 | 37 | |
---|
35 | 38 | struct vmw_private; |
---|
36 | 39 | struct vmw_ctx_binding_state; |
---|
.. | .. |
---|
47 | 50 | vmw_ctx_binding_dx_rt, |
---|
48 | 51 | vmw_ctx_binding_sr, |
---|
49 | 52 | vmw_ctx_binding_ds, |
---|
50 | | - vmw_ctx_binding_so, |
---|
| 53 | + vmw_ctx_binding_so_target, |
---|
51 | 54 | vmw_ctx_binding_vb, |
---|
52 | 55 | vmw_ctx_binding_ib, |
---|
| 56 | + vmw_ctx_binding_uav, |
---|
| 57 | + vmw_ctx_binding_cs_uav, |
---|
| 58 | + vmw_ctx_binding_so, |
---|
53 | 59 | vmw_ctx_binding_max |
---|
54 | 60 | }; |
---|
55 | 61 | |
---|
.. | .. |
---|
127 | 133 | }; |
---|
128 | 134 | |
---|
129 | 135 | /** |
---|
130 | | - * struct vmw_ctx_bindinfo_so - StreamOutput binding metadata |
---|
| 136 | + * struct vmw_ctx_bindinfo_so_target - StreamOutput binding metadata |
---|
131 | 137 | * |
---|
132 | 138 | * @bi: struct vmw_ctx_bindinfo we derive from. |
---|
133 | 139 | * @offset: Device data used to reconstruct binding command. |
---|
134 | 140 | * @size: Device data used to reconstruct binding command. |
---|
135 | 141 | * @slot: Device data used to reconstruct binding command. |
---|
136 | 142 | */ |
---|
137 | | -struct vmw_ctx_bindinfo_so { |
---|
| 143 | +struct vmw_ctx_bindinfo_so_target { |
---|
138 | 144 | struct vmw_ctx_bindinfo bi; |
---|
139 | 145 | uint32 offset; |
---|
140 | 146 | uint32 size; |
---|
.. | .. |
---|
188 | 194 | unsigned long dirty; |
---|
189 | 195 | }; |
---|
190 | 196 | |
---|
| 197 | +/** |
---|
| 198 | + * struct vmw_ctx_bindinfo_uav - UAV context binding state. |
---|
| 199 | + * @views: UAV view bindings. |
---|
| 200 | + * @splice_index: The device splice index set by user-space. |
---|
| 201 | + */ |
---|
| 202 | +struct vmw_ctx_bindinfo_uav { |
---|
| 203 | + struct vmw_ctx_bindinfo_view views[SVGA3D_MAX_UAVIEWS]; |
---|
| 204 | + uint32 index; |
---|
| 205 | +}; |
---|
| 206 | + |
---|
| 207 | +/** |
---|
| 208 | + * struct vmw_ctx_bindinfo_so - Stream output binding metadata. |
---|
| 209 | + * @bi: struct vmw_ctx_bindinfo we derive from. |
---|
| 210 | + * @slot: Device data used to reconstruct binding command. |
---|
| 211 | + */ |
---|
| 212 | +struct vmw_ctx_bindinfo_so { |
---|
| 213 | + struct vmw_ctx_bindinfo bi; |
---|
| 214 | + uint32 slot; |
---|
| 215 | +}; |
---|
| 216 | + |
---|
191 | 217 | extern void vmw_binding_add(struct vmw_ctx_binding_state *cbs, |
---|
192 | 218 | const struct vmw_ctx_bindinfo *ci, |
---|
193 | 219 | u32 shader_slot, u32 slot); |
---|
| 220 | +extern void vmw_binding_add_uav_index(struct vmw_ctx_binding_state *cbs, |
---|
| 221 | + uint32 slot, uint32 splice_index); |
---|
194 | 222 | extern void |
---|
195 | 223 | vmw_binding_state_commit(struct vmw_ctx_binding_state *to, |
---|
196 | 224 | struct vmw_ctx_binding_state *from); |
---|
.. | .. |
---|
205 | 233 | extern struct list_head * |
---|
206 | 234 | vmw_binding_state_list(struct vmw_ctx_binding_state *cbs); |
---|
207 | 235 | extern void vmw_binding_state_reset(struct vmw_ctx_binding_state *cbs); |
---|
| 236 | +extern u32 vmw_binding_dirtying(enum vmw_ctx_binding_type binding_type); |
---|
| 237 | + |
---|
208 | 238 | |
---|
209 | 239 | #endif |
---|