Home
last modified time | relevance | path

Searched refs:shmem (Results 1 – 18 of 18) sorted by relevance

/third_party/mesa3d/src/virtio/vulkan/
Dvn_renderer_internal.c42 list_for_each_entry_safe(struct vn_renderer_shmem, shmem, in vn_renderer_shmem_cache_fini()
44 cache->destroy_func(cache->renderer, shmem); in vn_renderer_shmem_cache_fini()
81 list_for_each_entry_safe(struct vn_renderer_shmem, shmem, in vn_renderer_shmem_cache_remove_expired_locked()
83 if (shmem == last_shmem || in vn_renderer_shmem_cache_remove_expired_locked()
84 now - shmem->cache_timestamp < VN_RENDERER_SHMEM_CACHE_EXPIRACY) in vn_renderer_shmem_cache_remove_expired_locked()
87 list_del(&shmem->cache_head); in vn_renderer_shmem_cache_remove_expired_locked()
88 cache->destroy_func(cache->renderer, shmem); in vn_renderer_shmem_cache_remove_expired_locked()
95 struct vn_renderer_shmem *shmem) in vn_renderer_shmem_cache_add() argument
97 assert(!vn_refcount_is_valid(&shmem->refcount)); in vn_renderer_shmem_cache_add()
101 choose_bucket(cache, shmem->mmap_size, &idx); in vn_renderer_shmem_cache_add()
[all …]
Dvn_renderer_util.c62 if (pool->shmem) in vn_renderer_shmem_pool_fini()
63 vn_renderer_shmem_unref(renderer, pool->shmem); in vn_renderer_shmem_pool_fini()
80 struct vn_renderer_shmem *shmem = in vn_renderer_shmem_pool_grow() local
82 if (!shmem) in vn_renderer_shmem_pool_grow()
85 if (pool->shmem) in vn_renderer_shmem_pool_grow()
86 vn_renderer_shmem_unref(renderer, pool->shmem); in vn_renderer_shmem_pool_grow()
88 pool->shmem = shmem; in vn_renderer_shmem_pool_grow()
108 struct vn_renderer_shmem *shmem = in vn_renderer_shmem_pool_alloc() local
109 vn_renderer_shmem_ref(renderer, pool->shmem); in vn_renderer_shmem_pool_alloc()
113 return shmem; in vn_renderer_shmem_pool_alloc()
Dvn_cs.c76 struct vn_renderer_shmem *shmem, in vn_cs_encoder_add_buffer() argument
85 cur_buf->shmem = shmem; in vn_cs_encoder_add_buffer()
117 enc->buffers[i].shmem); in vn_cs_encoder_gc_buffers()
135 vn_renderer_shmem_unref(enc->instance->renderer, enc->buffers[i].shmem); in vn_cs_encoder_gc_buffers()
140 vn_cs_encoder_add_buffer(enc, cur_buf->shmem, used, in vn_cs_encoder_gc_buffers()
169 vn_renderer_shmem_unref(enc->instance->renderer, enc->buffers[i].shmem); in vn_cs_encoder_fini()
262 struct vn_renderer_shmem *shmem; in vn_cs_encoder_reserve_internal() local
265 shmem = vn_renderer_shmem_create(enc->instance->renderer, buf_size); in vn_cs_encoder_reserve_internal()
269 shmem = in vn_cs_encoder_reserve_internal()
272 if (!shmem) in vn_cs_encoder_reserve_internal()
[all …]
Dvn_renderer.h154 struct vn_renderer_shmem *shmem);
285 struct vn_renderer_shmem *shmem = in vn_renderer_shmem_create() local
287 if (shmem) { in vn_renderer_shmem_create()
288 assert(vn_refcount_is_valid(&shmem->refcount)); in vn_renderer_shmem_create()
289 assert(shmem->res_id); in vn_renderer_shmem_create()
290 assert(shmem->mmap_size >= size); in vn_renderer_shmem_create()
291 assert(shmem->mmap_ptr); in vn_renderer_shmem_create()
294 return shmem; in vn_renderer_shmem_create()
299 struct vn_renderer_shmem *shmem) in vn_renderer_shmem_ref() argument
301 vn_refcount_inc(&shmem->refcount); in vn_renderer_shmem_ref()
[all …]
Dvn_instance.c128 instance->ring.shmem = in vn_instance_init_ring()
130 if (!instance->ring.shmem) { in vn_instance_init_ring()
140 instance->ring.shmem->mmap_ptr); in vn_instance_init_ring()
146 .resourceId = instance->ring.shmem->res_id, in vn_instance_init_ring()
380 .resourceId = buf->shmem->res_id, in vn_instance_submission_get_cs()
428 vn_renderer_shmem_ref(ring->renderer, cs->buffers[i].shmem); in vn_instance_submission_get_ring_submit()
563 const struct vn_renderer_shmem *saved_pool_shmem = pool->shmem; in vn_instance_get_reply_shmem_locked()
566 struct vn_renderer_shmem *shmem = in vn_instance_get_reply_shmem_locked() local
568 if (!shmem) in vn_instance_get_reply_shmem_locked()
571 assert(shmem == pool->shmem); in vn_instance_get_reply_shmem_locked()
[all …]
Dvn_instance.h49 struct vn_renderer_shmem *shmem; member
172 struct vn_renderer_shmem *shmem; in vn_instance_cs_shmem_alloc() local
175 shmem = vn_renderer_shmem_pool_alloc( in vn_instance_cs_shmem_alloc()
179 return shmem; in vn_instance_cs_shmem_alloc()
Dvn_renderer_internal.h12 struct vn_renderer *renderer, struct vn_renderer_shmem *shmem);
48 struct vn_renderer_shmem *shmem);
Dvn_renderer_vtest.c786 struct vtest_shmem *shmem = (struct vtest_shmem *)_shmem; in vtest_shmem_destroy_now() local
788 munmap(shmem->base.mmap_ptr, shmem->base.mmap_size); in vtest_shmem_destroy_now()
791 vtest_vcmd_resource_unref(vtest, shmem->base.res_id); in vtest_shmem_destroy_now()
797 struct vn_renderer_shmem *shmem) in vtest_shmem_destroy() argument
801 if (vn_renderer_shmem_cache_add(&vtest->shmem_cache, shmem)) in vtest_shmem_destroy()
804 vtest_shmem_destroy_now(&vtest->base, shmem); in vtest_shmem_destroy()
837 struct vtest_shmem *shmem = in vtest_shmem_create() local
839 *shmem = (struct vtest_shmem){ in vtest_shmem_create()
848 return &shmem->base; in vtest_shmem_create()
Dvn_renderer_virtgpu.c1304 struct virtgpu_shmem *shmem = (struct virtgpu_shmem *)_shmem; in virtgpu_shmem_destroy_now() local
1306 munmap(shmem->base.mmap_ptr, shmem->base.mmap_size); in virtgpu_shmem_destroy_now()
1307 virtgpu_ioctl_gem_close(gpu, shmem->gem_handle); in virtgpu_shmem_destroy_now()
1312 struct vn_renderer_shmem *shmem) in virtgpu_shmem_destroy() argument
1316 if (vn_renderer_shmem_cache_add(&gpu->shmem_cache, shmem)) in virtgpu_shmem_destroy()
1319 virtgpu_shmem_destroy_now(&gpu->base, shmem); in virtgpu_shmem_destroy()
1347 struct virtgpu_shmem *shmem = in virtgpu_shmem_create() local
1349 *shmem = (struct virtgpu_shmem){ in virtgpu_shmem_create()
1359 return &shmem->base; in virtgpu_shmem_create()
Dvn_renderer_util.h15 struct vn_renderer_shmem *shmem; member
Dvn_cs.h50 struct vn_renderer_shmem *shmem; member
/third_party/ltp/testcases/kernel/containers/sysvipc/
Dshm_comm.c62 char *shmem; in chld1_shm() local
70 if ((shmem = shmat(id, NULL, 0)) == (char *) -1) { in chld1_shm()
76 *shmem = 'A'; in chld1_shm()
81 if (*shmem != 'A') in chld1_shm()
87 shmdt(shmem); in chld1_shm()
95 char *shmem; in chld2_shm() local
103 if ((shmem = shmat(id, NULL, 0)) == (char *) -1) { in chld2_shm()
112 *shmem = 'B'; in chld2_shm()
116 shmdt(shmem); in chld2_shm()
/third_party/mesa3d/src/freedreno/drm/virtio/
Dvirtio_pipe.c211 if (unlikely(!virtio_dev->shmem)) { in init_shmem()
214 virtio_dev->shmem = fd_bo_map(virtio_dev->shmem_bo); in init_shmem()
217 uint32_t offset = virtio_dev->shmem->rsp_mem_offset; in init_shmem()
219 virtio_dev->rsp_mem = &((uint8_t *)virtio_dev->shmem)[offset]; in init_shmem()
Dmsm_proto.h47 #define msm_shmem_has_field(shmem, field) ({ \ argument
48 struct msm_shmem *_shmem = (shmem); \
Dvirtio_priv.h50 struct msm_shmem *shmem; member
Dvirtio_device.c378 while (fd_fence_before(virtio_dev->shmem->seqno, req->seqno)) in virtio_host_sync()
/third_party/mesa3d/docs/relnotes/
D21.3.0.rst803 - venus: support reply shmem without ring
814 - venus: convert bo and shmem to use vn_refcount
D22.1.0.rst3483 - venus: no roundtrip needed for shmem backed by BLOB_MEM_HOST3D