/third_party/mesa3d/src/gallium/winsys/svga/drm/ |
D | vmw_screen_dri.c | 55 struct winsys_handle *whandle, 60 struct winsys_handle *whandle, 66 struct winsys_handle *whandle); 143 struct winsys_handle *whandle, in vmw_drm_gb_surface_from_handle() argument 157 if (whandle->offset != 0) { in vmw_drm_gb_surface_from_handle() 159 whandle->offset); in vmw_drm_gb_surface_from_handle() 163 ret = vmw_ioctl_gb_surface_ref(vws, whandle, &flags, format, in vmw_drm_gb_surface_from_handle() 169 whandle->handle, ret, strerror(-ret)); in vmw_drm_gb_surface_from_handle() 176 whandle->handle, mip_levels); in vmw_drm_gb_surface_from_handle() 209 vmw_ioctl_surface_destroy(vws, whandle->handle); in vmw_drm_gb_surface_from_handle() [all …]
|
/third_party/mesa3d/src/gallium/winsys/i915/drm/ |
D | i915_drm_buffer.c | 92 struct winsys_handle *whandle, in i915_drm_buffer_from_handle() argument 101 if ((whandle->type != WINSYS_HANDLE_TYPE_SHARED) && (whandle->type != WINSYS_HANDLE_TYPE_FD)) in i915_drm_buffer_from_handle() 104 if (whandle->offset != 0) in i915_drm_buffer_from_handle() 113 if (whandle->type == WINSYS_HANDLE_TYPE_SHARED) in i915_drm_buffer_from_handle() 114 …o = drm_intel_bo_gem_create_from_name(idws->gem_manager, "gallium3d_from_handle", whandle->handle); in i915_drm_buffer_from_handle() 115 else if (whandle->type == WINSYS_HANDLE_TYPE_FD) { in i915_drm_buffer_from_handle() 116 int fd = (int) whandle->handle; in i915_drm_buffer_from_handle() 117 … buf->bo = drm_intel_bo_gem_create_from_prime(idws->gem_manager, fd, height * whandle->stride); in i915_drm_buffer_from_handle() 121 buf->flink = whandle->handle; in i915_drm_buffer_from_handle() 128 *stride = whandle->stride; in i915_drm_buffer_from_handle() [all …]
|
/third_party/mesa3d/src/gallium/drivers/nouveau/ |
D | nouveau_screen.c | 98 struct winsys_handle *whandle, in nouveau_screen_bo_from_handle() argument 105 if (whandle->offset != 0) { in nouveau_screen_bo_from_handle() 107 __FUNCTION__, whandle->offset); in nouveau_screen_bo_from_handle() 111 if (whandle->type != WINSYS_HANDLE_TYPE_SHARED && in nouveau_screen_bo_from_handle() 112 whandle->type != WINSYS_HANDLE_TYPE_FD) { in nouveau_screen_bo_from_handle() 114 __FUNCTION__, whandle->type); in nouveau_screen_bo_from_handle() 118 if (whandle->type == WINSYS_HANDLE_TYPE_SHARED) in nouveau_screen_bo_from_handle() 119 ret = nouveau_bo_name_ref(dev, whandle->handle, &bo); in nouveau_screen_bo_from_handle() 121 ret = nouveau_bo_prime_handle_ref(dev, whandle->handle, &bo); in nouveau_screen_bo_from_handle() 125 __FUNCTION__, whandle->handle, ret); in nouveau_screen_bo_from_handle() [all …]
|
/third_party/mesa3d/src/gallium/winsys/sw/kms-dri/ |
D | kms_dri_sw_winsys.c | 389 struct winsys_handle *whandle, in kms_sw_displaytarget_from_handle() argument 397 assert(whandle->type == WINSYS_HANDLE_TYPE_KMS || in kms_sw_displaytarget_from_handle() 398 whandle->type == WINSYS_HANDLE_TYPE_FD); in kms_sw_displaytarget_from_handle() 400 switch(whandle->type) { in kms_sw_displaytarget_from_handle() 402 kms_sw_pl = kms_sw_displaytarget_add_from_prime(kms_sw, whandle->handle, in kms_sw_displaytarget_from_handle() 406 whandle->stride, in kms_sw_displaytarget_from_handle() 407 whandle->offset); in kms_sw_displaytarget_from_handle() 412 kms_sw_dt = kms_sw_displaytarget_find_and_ref(kms_sw, whandle->handle); in kms_sw_displaytarget_from_handle() 416 if (whandle->offset == plane->offset) { in kms_sw_displaytarget_from_handle() 435 struct winsys_handle *whandle) in kms_sw_displaytarget_get_handle() argument [all …]
|
/third_party/mesa3d/src/mesa/state_tracker/ |
D | st_vdpau.c | 115 struct winsys_handle whandle; in st_vdpau_resource_from_description() local 131 memset(&whandle, 0, sizeof(whandle)); in st_vdpau_resource_from_description() 132 whandle.type = WINSYS_HANDLE_TYPE_FD; in st_vdpau_resource_from_description() 133 whandle.handle = desc->handle; in st_vdpau_resource_from_description() 134 whandle.modifier = DRM_FORMAT_MOD_INVALID; in st_vdpau_resource_from_description() 135 whandle.offset = desc->offset; in st_vdpau_resource_from_description() 136 whandle.stride = desc->stride; in st_vdpau_resource_from_description() 138 res = st->screen->resource_from_handle(st->screen, &templ, &whandle, in st_vdpau_resource_from_description() 217 struct winsys_handle whandle = { .type = WINSYS_HANDLE_TYPE_FD }; in st_vdpau_map_surface() local 222 res->screen->resource_get_handle(res->screen, NULL, res, &whandle, in st_vdpau_map_surface() [all …]
|
D | st_cb_memoryobjects.c | 76 struct winsys_handle whandle = { in st_import_memoryobj_fd() local 85 &whandle, in st_import_memoryobj_fd()
|
/third_party/mesa3d/src/gallium/frontends/dri/ |
D | dri2.c | 299 struct winsys_handle whandle; in dri2_allocate_buffer() local 363 memset(&whandle, 0, sizeof(whandle)); in dri2_allocate_buffer() 365 whandle.type = WINSYS_HANDLE_TYPE_SHARED; in dri2_allocate_buffer() 367 whandle.type = WINSYS_HANDLE_TYPE_KMS; in dri2_allocate_buffer() 370 buffer->resource, &whandle, in dri2_allocate_buffer() 374 buffer->base.name = whandle.handle; in dri2_allocate_buffer() 376 buffer->base.pitch = whandle.stride; in dri2_allocate_buffer() 411 struct winsys_handle whandle; in dri2_allocate_textures() local 531 memset(&whandle, 0, sizeof(whandle)); in dri2_allocate_textures() 565 whandle.handle = buf->name; in dri2_allocate_textures() [all …]
|
/third_party/mesa3d/src/gallium/frontends/xa/ |
D | xa_tracker.c | 339 struct winsys_handle *whandle) in surface_create() argument 374 if (whandle) in surface_create() 375 srf->tex = xa->screen->resource_from_handle(xa->screen, template, whandle, in surface_create() 430 struct winsys_handle whandle; in xa_surface_from_handle2() local 431 memset(&whandle, 0, sizeof(whandle)); in xa_surface_from_handle2() 432 whandle.type = handle_type(type); in xa_surface_from_handle2() 433 whandle.handle = handle; in xa_surface_from_handle2() 434 whandle.stride = stride; in xa_surface_from_handle2() 435 return surface_create(xa, width, height, depth, stype, xa_format, flags, &whandle); in xa_surface_from_handle2() 555 struct winsys_handle whandle; in xa_surface_handle() local [all …]
|
/third_party/mesa3d/src/gallium/drivers/vc4/ |
D | vc4_resource.c | 299 struct winsys_handle *whandle, in vc4_resource_get_handle() argument 305 whandle->stride = rsc->slices[0].stride; in vc4_resource_get_handle() 306 whandle->offset = 0; in vc4_resource_get_handle() 307 whandle->modifier = vc4_resource_modifier(rsc); in vc4_resource_get_handle() 315 switch (whandle->type) { in vc4_resource_get_handle() 325 return vc4_bo_flink(rsc->bo, &whandle->handle); in vc4_resource_get_handle() 328 return renderonly_get_handle(rsc->scanout, whandle); in vc4_resource_get_handle() 330 whandle->handle = rsc->bo->handle; in vc4_resource_get_handle() 335 whandle->handle = vc4_bo_get_dmabuf(rsc->bo); in vc4_resource_get_handle() 336 return whandle->handle != -1; in vc4_resource_get_handle() [all …]
|
/third_party/mesa3d/src/gallium/drivers/v3d/ |
D | v3d_resource.c | 418 struct winsys_handle *whandle, in v3d_resource_get_handle() argument 425 whandle->stride = rsc->slices[0].stride; in v3d_resource_get_handle() 426 whandle->offset = 0; in v3d_resource_get_handle() 427 whandle->modifier = v3d_resource_modifier(rsc); in v3d_resource_get_handle() 435 switch (whandle->type) { in v3d_resource_get_handle() 437 return v3d_bo_flink(bo, &whandle->handle); in v3d_resource_get_handle() 440 if (renderonly_get_handle(rsc->scanout, whandle)) { in v3d_resource_get_handle() 441 whandle->stride = rsc->slices[0].stride; in v3d_resource_get_handle() 446 whandle->handle = bo->handle; in v3d_resource_get_handle() 449 whandle->handle = v3d_bo_get_dmabuf(bo); in v3d_resource_get_handle() [all …]
|
/third_party/mesa3d/src/gallium/drivers/freedreno/ |
D | freedreno_screen.c | 809 struct winsys_handle *whandle) in fd_screen_bo_get_handle() argument 813 whandle->stride = stride; in fd_screen_bo_get_handle() 815 if (whandle->type == WINSYS_HANDLE_TYPE_SHARED) { in fd_screen_bo_get_handle() 816 return fd_bo_get_name(bo, &whandle->handle) == 0; in fd_screen_bo_get_handle() 817 } else if (whandle->type == WINSYS_HANDLE_TYPE_KMS) { in fd_screen_bo_get_handle() 819 return renderonly_get_handle(scanout, whandle); in fd_screen_bo_get_handle() 821 whandle->handle = fd_bo_handle(bo); in fd_screen_bo_get_handle() 824 } else if (whandle->type == WINSYS_HANDLE_TYPE_FD) { in fd_screen_bo_get_handle() 825 whandle->handle = fd_bo_dmabuf(bo); in fd_screen_bo_get_handle() 885 struct winsys_handle *whandle) in fd_screen_bo_from_handle() argument [all …]
|
/third_party/mesa3d/src/gallium/frontends/va/ |
D | surface.c | 579 struct winsys_handle whandle; in surface_from_external_memory() local 610 memset(&whandle, 0, sizeof(struct winsys_handle)); in surface_from_external_memory() 611 whandle.type = WINSYS_HANDLE_TYPE_FD; in surface_from_external_memory() 612 whandle.handle = memory_attribute->buffers[index]; in surface_from_external_memory() 613 whandle.modifier = DRM_FORMAT_MOD_INVALID; in surface_from_external_memory() 614 whandle.format = templat->buffer_format; in surface_from_external_memory() 636 whandle.stride = memory_attribute->pitches[i]; in surface_from_external_memory() 637 whandle.offset = memory_attribute->offsets[i]; in surface_from_external_memory() 638 resources[i] = pscreen->resource_from_handle(pscreen, &res_templ, &whandle, in surface_from_external_memory() 667 struct winsys_handle whandle; in surface_from_prime_2() local [all …]
|
D | buffer.c | 306 struct winsys_handle whandle; in vlVaAcquireBufferHandle() local 311 memset(&whandle, 0, sizeof(whandle)); in vlVaAcquireBufferHandle() 312 whandle.type = WINSYS_HANDLE_TYPE_FD; in vlVaAcquireBufferHandle() 316 &whandle, PIPE_HANDLE_USAGE_FRAMEBUFFER_WRITE)) { in vlVaAcquireBufferHandle() 323 buf_info->handle = (intptr_t)whandle.handle; in vlVaAcquireBufferHandle()
|
/third_party/mesa3d/src/gallium/drivers/zink/ |
D | zink_resource.c | 439 …screen *screen, const struct pipe_resource *templ, struct winsys_handle *whandle, bool *optimal_ti… in resource_object_create() argument 453 if (whandle) { in resource_object_create() 454 if (whandle->type == WINSYS_HANDLE_TYPE_FD) { in resource_object_create() 487 bool winsys_modifier = shared && whandle && whandle->modifier != DRM_FORMAT_MOD_INVALID; in resource_object_create() 488 const uint64_t *ici_modifiers = winsys_modifier ? &whandle->modifier : modifiers; in resource_object_create() 507 assert(mod == whandle->modifier); in resource_object_create() 519 .offset = whandle->offset, in resource_object_create() 521 .rowPitch = whandle->stride, in resource_object_create() 660 if (whandle) { in resource_object_create() 663 imfi.fd = os_dupfd_cloexec(whandle->handle); in resource_object_create() [all …]
|
/third_party/mesa3d/src/gallium/drivers/crocus/ |
D | crocus_resource.c | 810 struct winsys_handle *whandle, in crocus_resource_from_handle() argument 822 switch (whandle->type) { in crocus_resource_from_handle() 824 res->bo = crocus_bo_import_dmabuf(bufmgr, whandle->handle, in crocus_resource_from_handle() 825 whandle->modifier); in crocus_resource_from_handle() 829 whandle->handle); in crocus_resource_from_handle() 837 res->offset = whandle->offset; in crocus_resource_from_handle() 838 res->external_format = whandle->format; in crocus_resource_from_handle() 840 if (whandle->plane < util_format_get_num_planes(whandle->format)) { in crocus_resource_from_handle() 842 whandle->modifier != DRM_FORMAT_MOD_INVALID ? in crocus_resource_from_handle() 843 whandle->modifier : tiling_to_modifier(res->bo->tiling_mode); in crocus_resource_from_handle() [all …]
|
/third_party/mesa3d/src/gallium/winsys/virgl/drm/ |
D | virgl_drm_winsys.c | 464 struct winsys_handle *whandle, in virgl_drm_winsys_resource_create_handle() argument 475 uint32_t handle = whandle->handle; in virgl_drm_winsys_resource_create_handle() 477 if (whandle->plane >= VIRGL_MAX_PLANE_COUNT) { in virgl_drm_winsys_resource_create_handle() 481 if (whandle->offset != 0 && whandle->type == WINSYS_HANDLE_TYPE_SHARED) { in virgl_drm_winsys_resource_create_handle() 483 whandle->offset); in virgl_drm_winsys_resource_create_handle() 485 } else if (whandle->type == WINSYS_HANDLE_TYPE_FD) { in virgl_drm_winsys_resource_create_handle() 486 *plane = whandle->plane; in virgl_drm_winsys_resource_create_handle() 487 *stride = whandle->stride; in virgl_drm_winsys_resource_create_handle() 488 *plane_offset = whandle->offset; in virgl_drm_winsys_resource_create_handle() 489 *modifier = whandle->modifier; in virgl_drm_winsys_resource_create_handle() [all …]
|
/third_party/mesa3d/src/gallium/auxiliary/vl/ |
D | vl_winsys_dri3.c | 228 struct winsys_handle whandle; in dri3_alloc_back_buffer() local 276 memset(&whandle, 0, sizeof(whandle)); in dri3_alloc_back_buffer() 277 whandle.type= WINSYS_HANDLE_TYPE_FD; in dri3_alloc_back_buffer() 279 pixmap_buffer_texture, &whandle, 0); in dri3_alloc_back_buffer() 280 buffer_fd = whandle.handle; in dri3_alloc_back_buffer() 281 buffer->pitch = whandle.stride; in dri3_alloc_back_buffer() 467 struct winsys_handle whandle; in dri3_get_front_buffer() local 496 memset(&whandle, 0, sizeof(whandle)); in dri3_get_front_buffer() 497 whandle.type = WINSYS_HANDLE_TYPE_FD; in dri3_get_front_buffer() 498 whandle.handle = (unsigned)fds[0]; in dri3_get_front_buffer() [all …]
|
/third_party/mesa3d/src/gallium/drivers/iris/ |
D | iris_resource.c | 307 struct winsys_handle *whandle, in iris_memobj_create_from_handle() argument 317 switch (whandle->type) { in iris_memobj_create_from_handle() 320 whandle->handle); in iris_memobj_create_from_handle() 323 bo = iris_bo_import_dmabuf(screen->bufmgr, whandle->handle); in iris_memobj_create_from_handle() 336 memobj->format = whandle->format; in iris_memobj_create_from_handle() 337 memobj->stride = whandle->stride; in iris_memobj_create_from_handle() 1222 struct winsys_handle *whandle, in iris_resource_from_handle() argument 1233 switch (whandle->type) { in iris_resource_from_handle() 1235 res->bo = iris_bo_import_dmabuf(bufmgr, whandle->handle); in iris_resource_from_handle() 1239 whandle->handle); in iris_resource_from_handle() [all …]
|
/third_party/mesa3d/src/gallium/frontends/vdpau/ |
D | surface.c | 491 struct winsys_handle whandle; in vlVdpVideoSurfaceDMABuf() local 528 memset(&whandle, 0, sizeof(struct winsys_handle)); in vlVdpVideoSurfaceDMABuf() 529 whandle.type = WINSYS_HANDLE_TYPE_FD; in vlVdpVideoSurfaceDMABuf() 530 whandle.layer = surf->u.tex.first_layer; in vlVdpVideoSurfaceDMABuf() 534 surf->texture, &whandle, in vlVdpVideoSurfaceDMABuf() 542 result->handle = whandle.handle; in vlVdpVideoSurfaceDMABuf() 545 result->offset = whandle.offset; in vlVdpVideoSurfaceDMABuf() 546 result->stride = whandle.stride; in vlVdpVideoSurfaceDMABuf()
|
/third_party/mesa3d/src/gallium/drivers/llvmpipe/ |
D | lp_texture.c | 564 struct winsys_handle *whandle, in llvmpipe_resource_from_handle() argument 594 whandle, in llvmpipe_resource_from_handle() 621 struct winsys_handle *whandle, in llvmpipe_resource_get_handle() argument 631 return winsys->displaytarget_get_handle(winsys, lpr->dt, whandle); in llvmpipe_resource_get_handle() 1064 struct winsys_handle whandle; in llvmpipe_resource_get_param() local 1090 memset(&whandle, 0, sizeof(whandle)); in llvmpipe_resource_get_param() 1092 whandle.type = WINSYS_HANDLE_TYPE_SHARED; in llvmpipe_resource_get_param() 1094 whandle.type = WINSYS_HANDLE_TYPE_KMS; in llvmpipe_resource_get_param() 1096 whandle.type = WINSYS_HANDLE_TYPE_FD; in llvmpipe_resource_get_param() 1098 if (!llvmpipe_resource_get_handle(screen, context, resource, &whandle, handle_usage)) in llvmpipe_resource_get_param() [all …]
|
/third_party/mesa3d/src/gallium/drivers/radeonsi/ |
D | si_texture.c | 566 struct winsys_handle whandle; in si_resource_get_param() local 601 memset(&whandle, 0, sizeof(whandle)); in si_resource_get_param() 604 whandle.type = WINSYS_HANDLE_TYPE_SHARED; in si_resource_get_param() 606 whandle.type = WINSYS_HANDLE_TYPE_KMS; in si_resource_get_param() 608 whandle.type = WINSYS_HANDLE_TYPE_FD; in si_resource_get_param() 610 if (!screen->resource_get_handle(screen, context, resource, &whandle, handle_usage)) in si_resource_get_param() 613 *value = whandle.handle; in si_resource_get_param() 638 struct pipe_resource *resource, struct winsys_handle *whandle, in si_texture_get_handle() argument 654 unsigned plane = whandle->plane; in si_texture_get_handle() 672 whandle->offset = ac_surface_get_plane_offset(sscreen->info.chip_class, in si_texture_get_handle() [all …]
|
/third_party/mesa3d/src/gallium/include/frontend/ |
D | sw_winsys.h | 100 struct winsys_handle *whandle, 109 struct winsys_handle *whandle );
|
/third_party/mesa3d/src/gallium/drivers/i915/ |
D | i915_resource.c | 24 struct winsys_handle *whandle, unsigned usage) in i915_resource_from_handle() argument 29 return i915_texture_from_handle(screen, template, whandle); in i915_resource_from_handle()
|
/third_party/mesa3d/src/gallium/drivers/r300/ |
D | r300_texture.h | 67 struct winsys_handle *whandle, 73 struct winsys_handle *whandle,
|
/third_party/mesa3d/src/gallium/winsys/sw/wrapper/ |
D | wrapper_sw_winsys.c | 182 struct winsys_handle *whandle, in wsw_dt_from_handle() argument 188 tex = wsw->screen->resource_from_handle(wsw->screen, templ, whandle, in wsw_dt_from_handle() 199 struct winsys_handle *whandle) in wsw_dt_get_handle() argument 205 return wsw->screen->resource_get_handle(wsw->screen, NULL, tex, whandle, in wsw_dt_get_handle()
|