FREE(cbuf);
return NULL;
}
+
+ cbuf->buf = CALLOC(size, sizeof(uint32_t));
+ if (!cbuf->buf) {
+ FREE(cbuf->res_bo);
+ FREE(cbuf);
+ return NULL;
+ }
+
cbuf->ws = vws;
cbuf->base.buf = cbuf->buf;
return &cbuf->base;
virgl_vtest_release_all_res(virgl_vtest_winsys(cbuf->ws), cbuf);
FREE(cbuf->res_bo);
+ FREE(cbuf->buf);
FREE(cbuf);
}
vtws->base.fence_wait = virgl_fence_wait;
vtws->base.fence_reference = virgl_fence_reference;
vtws->base.supports_fences = 0;
- vtws->base.supports_encoded_transfers = 0;
+ vtws->base.supports_encoded_transfers = (vtws->protocol_version >= 2);
vtws->base.flush_frontbuffer = virgl_vtest_flush_frontbuffer;