Lines Matching full:vc4
43 struct vc4_context *vc4 = vc4_context(pctx); in vc4_flush() local
45 hash_table_foreach(vc4->jobs, entry) { in vc4_flush()
47 vc4_job_submit(vc4, job); in vc4_flush()
55 struct vc4_context *vc4 = vc4_context(pctx); in vc4_pipe_flush() local
65 drmSyncobjExportSyncFile(vc4->fd, vc4->job_syncobj, in vc4_pipe_flush()
69 struct vc4_fence *f = vc4_fence_create(vc4->screen, in vc4_pipe_flush()
70 vc4->last_emit_seqno, in vc4_pipe_flush()
91 struct vc4_context *vc4 = vc4_context(pctx); in vc4_set_debug_callback() local
94 vc4->debug = *cb; in vc4_set_debug_callback()
96 memset(&vc4->debug, 0, sizeof(vc4->debug)); in vc4_set_debug_callback()
102 struct vc4_context *vc4 = vc4_context(pctx); in vc4_invalidate_resource() local
107 struct hash_entry *entry = _mesa_hash_table_search(vc4->write_jobs, in vc4_invalidate_resource()
120 struct vc4_context *vc4 = vc4_context(pctx); in vc4_context_destroy() local
124 if (vc4->blitter) in vc4_context_destroy()
125 util_blitter_destroy(vc4->blitter); in vc4_context_destroy()
127 if (vc4->primconvert) in vc4_context_destroy()
128 util_primconvert_destroy(vc4->primconvert); in vc4_context_destroy()
130 if (vc4->uploader) in vc4_context_destroy()
131 u_upload_destroy(vc4->uploader); in vc4_context_destroy()
133 slab_destroy_child(&vc4->transfer_pool); in vc4_context_destroy()
135 pipe_surface_reference(&vc4->framebuffer.cbufs[0], NULL); in vc4_context_destroy()
136 pipe_surface_reference(&vc4->framebuffer.zsbuf, NULL); in vc4_context_destroy()
138 if (vc4->yuv_linear_blit_vs) in vc4_context_destroy()
139 pctx->delete_vs_state(pctx, vc4->yuv_linear_blit_vs); in vc4_context_destroy()
140 if (vc4->yuv_linear_blit_fs_8bit) in vc4_context_destroy()
141 pctx->delete_fs_state(pctx, vc4->yuv_linear_blit_fs_8bit); in vc4_context_destroy()
142 if (vc4->yuv_linear_blit_fs_16bit) in vc4_context_destroy()
143 pctx->delete_fs_state(pctx, vc4->yuv_linear_blit_fs_16bit); in vc4_context_destroy()
147 if (vc4->screen->has_syncobj) { in vc4_context_destroy()
148 drmSyncobjDestroy(vc4->fd, vc4->job_syncobj); in vc4_context_destroy()
149 drmSyncobjDestroy(vc4->fd, vc4->in_syncobj); in vc4_context_destroy()
151 if (vc4->in_fence_fd >= 0) in vc4_context_destroy()
152 close(vc4->in_fence_fd); in vc4_context_destroy()
154 ralloc_free(vc4); in vc4_context_destroy()
161 struct vc4_context *vc4; in vc4_context_create() local
168 vc4 = rzalloc(NULL, struct vc4_context); in vc4_context_create()
169 if (!vc4) in vc4_context_create()
171 struct pipe_context *pctx = &vc4->base; in vc4_context_create()
173 vc4->screen = screen; in vc4_context_create()
189 vc4->fd = screen->fd; in vc4_context_create()
191 err = vc4_job_init(vc4); in vc4_context_create()
195 err = vc4_fence_context_init(vc4); in vc4_context_create()
199 slab_create_child(&vc4->transfer_pool, &screen->transfer_pool); in vc4_context_create()
201 vc4->uploader = u_upload_create_default(&vc4->base); in vc4_context_create()
202 vc4->base.stream_uploader = vc4->uploader; in vc4_context_create()
203 vc4->base.const_uploader = vc4->uploader; in vc4_context_create()
205 vc4->blitter = util_blitter_create(pctx); in vc4_context_create()
206 if (!vc4->blitter) in vc4_context_create()
209 vc4->primconvert = util_primconvert_create(pctx, in vc4_context_create()
211 if (!vc4->primconvert) in vc4_context_create()
216 vc4->sample_mask = (1 << VC4_MAX_SAMPLES) - 1; in vc4_context_create()
218 return &vc4->base; in vc4_context_create()