Lines Matching refs:shader

44 	struct vmw_shader shader;  member
169 struct vmw_shader *shader = vmw_res_to_shader(res); in vmw_gb_shader_init() local
188 shader->size = size; in vmw_gb_shader_init()
189 shader->type = type; in vmw_gb_shader_init()
190 shader->num_input_sig = num_input_sig; in vmw_gb_shader_init()
191 shader->num_output_sig = num_output_sig; in vmw_gb_shader_init()
204 struct vmw_shader *shader = vmw_res_to_shader(res); in vmw_gb_shader_create() local
234 cmd->body.type = shader->type; in vmw_gb_shader_create()
235 cmd->body.sizeInBytes = shader->size; in vmw_gb_shader_create()
359 struct vmw_dx_shader *shader = vmw_res_to_dx_shader(res); in vmw_dx_shader_commit_notify() local
364 vmw_cotable_add_resource(shader->cotable, in vmw_dx_shader_commit_notify()
365 &shader->cotable_head); in vmw_dx_shader_commit_notify()
366 shader->committed = true; in vmw_dx_shader_commit_notify()
367 res->id = shader->id; in vmw_dx_shader_commit_notify()
371 list_del_init(&shader->cotable_head); in vmw_dx_shader_commit_notify()
372 shader->committed = false; in vmw_dx_shader_commit_notify()
387 struct vmw_dx_shader *shader = vmw_res_to_dx_shader(res); in vmw_dx_shader_unscrub() local
394 if (!list_empty(&shader->cotable_head) || !shader->committed) in vmw_dx_shader_unscrub()
397 cmd = VMW_CMD_CTX_RESERVE(dev_priv, sizeof(*cmd), shader->ctx->id); in vmw_dx_shader_unscrub()
403 cmd->body.cid = shader->ctx->id; in vmw_dx_shader_unscrub()
404 cmd->body.shid = shader->id; in vmw_dx_shader_unscrub()
409 vmw_cotable_add_resource(shader->cotable, &shader->cotable_head); in vmw_dx_shader_unscrub()
425 struct vmw_dx_shader *shader = vmw_res_to_dx_shader(res); in vmw_dx_shader_create() local
428 WARN_ON_ONCE(!shader->committed); in vmw_dx_shader_create()
436 res->id = shader->id; in vmw_dx_shader_create()
473 struct vmw_dx_shader *shader = vmw_res_to_dx_shader(res); in vmw_dx_shader_scrub() local
480 if (list_empty(&shader->cotable_head)) in vmw_dx_shader_scrub()
483 WARN_ON_ONCE(!shader->committed); in vmw_dx_shader_scrub()
490 cmd->body.cid = shader->ctx->id; in vmw_dx_shader_scrub()
496 list_del_init(&shader->cotable_head); in vmw_dx_shader_scrub()
571 struct vmw_dx_shader *shader = vmw_res_to_dx_shader(res); in vmw_dx_shader_res_free() local
573 vmw_resource_unreference(&shader->cotable); in vmw_dx_shader_res_free()
574 kfree(shader); in vmw_dx_shader_res_free()
594 struct vmw_dx_shader *shader; in vmw_dx_shader_add() local
604 vmw_shader_dx_size = ttm_round_pot(sizeof(*shader)); in vmw_dx_shader_add()
618 shader = kmalloc(sizeof(*shader), GFP_KERNEL); in vmw_dx_shader_add()
619 if (!shader) { in vmw_dx_shader_add()
624 res = &shader->res; in vmw_dx_shader_add()
625 shader->ctx = ctx; in vmw_dx_shader_add()
626 shader->cotable = vmw_resource_reference in vmw_dx_shader_add()
628 shader->id = user_key; in vmw_dx_shader_add()
629 shader->committed = false; in vmw_dx_shader_add()
630 INIT_LIST_HEAD(&shader->cotable_head); in vmw_dx_shader_add()
646 res->id = shader->id; in vmw_dx_shader_add()
665 shader.res); in vmw_user_shader_base_to_res()
671 container_of(res, struct vmw_user_shader, shader.res); in vmw_user_shader_free()
681 struct vmw_shader *shader = vmw_res_to_shader(res); in vmw_shader_free() local
684 kfree(shader); in vmw_shader_free()
754 res = &ushader->shader.res; in vmw_user_shader_alloc()
794 struct vmw_shader *shader; in vmw_shader_alloc() local
817 shader = kzalloc(sizeof(*shader), GFP_KERNEL); in vmw_shader_alloc()
818 if (unlikely(!shader)) { in vmw_shader_alloc()
825 res = &shader->res; in vmw_shader_alloc()