Lines Matching refs:bo

143 	drm_intel_bo *bo;  member
148 drm_intel_bo bo; member
267 drm_intel_gem_bo_get_tiling(drm_intel_bo *bo, uint32_t * tiling_mode,
271 drm_intel_gem_bo_set_tiling_internal(drm_intel_bo *bo,
275 static void drm_intel_gem_bo_unreference_locked_timed(drm_intel_bo *bo,
278 static void drm_intel_gem_bo_unreference(drm_intel_bo *bo);
280 static void drm_intel_gem_bo_free(drm_intel_bo *bo);
387 drm_intel_bo *bo = bufmgr_gem->exec_bos[i]; in drm_intel_gem_dump_validation_list() local
388 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_dump_validation_list()
397 drm_intel_bo *target_bo = bo_gem->reloc_target_info[j].bo; in drm_intel_gem_dump_validation_list()
415 drm_intel_gem_bo_reference(drm_intel_bo *bo) in drm_intel_gem_bo_reference() argument
417 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_reference()
431 drm_intel_add_validate_buffer(drm_intel_bo *bo) in drm_intel_add_validate_buffer() argument
433 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_add_validate_buffer()
434 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_add_validate_buffer()
464 bufmgr_gem->exec_bos[index] = bo; in drm_intel_add_validate_buffer()
469 drm_intel_add_validate_buffer2(drm_intel_bo *bo, int need_fence) in drm_intel_add_validate_buffer2() argument
471 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *)bo->bufmgr; in drm_intel_add_validate_buffer2()
472 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *)bo; in drm_intel_add_validate_buffer2()
506 bufmgr_gem->exec_bos[index] = bo; in drm_intel_add_validate_buffer2()
534 size = bo_gem->bo.size; in drm_intel_bo_gem_set_in_aperture_size()
557 drm_intel_setup_reloc_list(drm_intel_bo *bo) in drm_intel_setup_reloc_list() argument
559 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_setup_reloc_list()
560 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_setup_reloc_list()
563 if (bo->size / 4 < max_relocs) in drm_intel_setup_reloc_list()
564 max_relocs = bo->size / 4; in drm_intel_setup_reloc_list()
586 drm_intel_gem_bo_busy(drm_intel_bo *bo) in drm_intel_gem_bo_busy() argument
588 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_busy()
589 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_busy()
625 drm_intel_gem_bo_madvise(drm_intel_bo *bo, int madv) in drm_intel_gem_bo_madvise() argument
628 ((drm_intel_bufmgr_gem *) bo->bufmgr, in drm_intel_gem_bo_madvise()
629 (drm_intel_bo_gem *) bo, in drm_intel_gem_bo_madvise()
648 drm_intel_gem_bo_free(&bo_gem->bo); in drm_intel_gem_bo_cache_purge_bucket()
710 if (!drm_intel_gem_bo_busy(&bo_gem->bo)) { in drm_intel_gem_bo_alloc_internal()
719 drm_intel_gem_bo_free(&bo_gem->bo); in drm_intel_gem_bo_alloc_internal()
725 if (drm_intel_gem_bo_set_tiling_internal(&bo_gem->bo, in drm_intel_gem_bo_alloc_internal()
728 drm_intel_gem_bo_free(&bo_gem->bo); in drm_intel_gem_bo_alloc_internal()
742 bo_gem->bo.size = bo_size; in drm_intel_gem_bo_alloc_internal()
751 bo_gem->bo.handle = bo_gem->gem_handle; in drm_intel_gem_bo_alloc_internal()
756 bo_gem->bo.bufmgr = bufmgr; in drm_intel_gem_bo_alloc_internal()
766 if (drm_intel_gem_bo_set_tiling_internal(&bo_gem->bo, in drm_intel_gem_bo_alloc_internal()
769 drm_intel_gem_bo_free(&bo_gem->bo); in drm_intel_gem_bo_alloc_internal()
789 return &bo_gem->bo; in drm_intel_gem_bo_alloc_internal()
889 bo_gem->bo.size = size; in drm_intel_gem_bo_alloc_userptr()
908 bo_gem->bo.handle = bo_gem->gem_handle; in drm_intel_gem_bo_alloc_userptr()
909 bo_gem->bo.bufmgr = bufmgr; in drm_intel_gem_bo_alloc_userptr()
911 bo_gem->bo.virtual = addr; in drm_intel_gem_bo_alloc_userptr()
936 return &bo_gem->bo; in drm_intel_gem_bo_alloc_userptr()
969 drm_intel_gem_bo_reference(&bo_gem->bo); in drm_intel_bo_gem_create_from_name()
971 return &bo_gem->bo; in drm_intel_bo_gem_create_from_name()
995 drm_intel_gem_bo_reference(&bo_gem->bo); in drm_intel_bo_gem_create_from_name()
997 return &bo_gem->bo; in drm_intel_bo_gem_create_from_name()
1007 bo_gem->bo.size = open_arg.size; in drm_intel_bo_gem_create_from_name()
1008 bo_gem->bo.offset = 0; in drm_intel_bo_gem_create_from_name()
1009 bo_gem->bo.offset64 = 0; in drm_intel_bo_gem_create_from_name()
1010 bo_gem->bo.virtual = NULL; in drm_intel_bo_gem_create_from_name()
1011 bo_gem->bo.bufmgr = bufmgr; in drm_intel_bo_gem_create_from_name()
1016 bo_gem->bo.handle = open_arg.handle; in drm_intel_bo_gem_create_from_name()
1026 drm_intel_gem_bo_unreference(&bo_gem->bo); in drm_intel_bo_gem_create_from_name()
1040 return &bo_gem->bo; in drm_intel_bo_gem_create_from_name()
1044 drm_intel_gem_bo_free(drm_intel_bo *bo) in drm_intel_gem_bo_free() argument
1046 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_free()
1047 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_free()
1054 drm_munmap(bo_gem->mem_virtual, bo_gem->bo.size); in drm_intel_gem_bo_free()
1058 drm_munmap(bo_gem->gtt_virtual, bo_gem->bo.size); in drm_intel_gem_bo_free()
1071 free(bo); in drm_intel_gem_bo_free()
1075 drm_intel_gem_bo_mark_mmaps_incoherent(drm_intel_bo *bo) in drm_intel_gem_bo_mark_mmaps_incoherent() argument
1078 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_mark_mmaps_incoherent()
1081 VALGRIND_MAKE_MEM_NOACCESS(bo_gem->mem_virtual, bo->size); in drm_intel_gem_bo_mark_mmaps_incoherent()
1084 VALGRIND_MAKE_MEM_NOACCESS(bo_gem->gtt_virtual, bo->size); in drm_intel_gem_bo_mark_mmaps_incoherent()
1111 drm_intel_gem_bo_free(&bo_gem->bo); in drm_intel_gem_cleanup_bo_cache()
1143 drm_munmap(bo_gem->mem_virtual, bo_gem->bo.size); in drm_intel_gem_bo_purge_vma_cache()
1148 drm_munmap(bo_gem->gtt_virtual, bo_gem->bo.size); in drm_intel_gem_bo_purge_vma_cache()
1180 drm_intel_gem_bo_unreference_final(drm_intel_bo *bo, time_t time) in drm_intel_gem_bo_unreference_final() argument
1182 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_unreference_final()
1183 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_unreference_final()
1189 if (bo_gem->reloc_target_info[i].bo != bo) { in drm_intel_gem_bo_unreference_final()
1191 reloc_target_info[i].bo, in drm_intel_gem_bo_unreference_final()
1216 drm_intel_gem_bo_mark_mmaps_incoherent(bo); in drm_intel_gem_bo_unreference_final()
1221 bucket = drm_intel_gem_bo_bucket_for_size(bufmgr_gem, bo->size); in drm_intel_gem_bo_unreference_final()
1233 drm_intel_gem_bo_free(bo); in drm_intel_gem_bo_unreference_final()
1237 static void drm_intel_gem_bo_unreference_locked_timed(drm_intel_bo *bo, in drm_intel_gem_bo_unreference_locked_timed() argument
1240 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_unreference_locked_timed()
1244 drm_intel_gem_bo_unreference_final(bo, time); in drm_intel_gem_bo_unreference_locked_timed()
1247 static void drm_intel_gem_bo_unreference(drm_intel_bo *bo) in drm_intel_gem_bo_unreference() argument
1249 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_unreference()
1255 (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_unreference()
1263 drm_intel_gem_bo_unreference_final(bo, time.tv_sec); in drm_intel_gem_bo_unreference()
1271 static int drm_intel_gem_bo_map(drm_intel_bo *bo, int write_enable) in drm_intel_gem_bo_map() argument
1273 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_map()
1274 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_map()
1280 bo->virtual = bo_gem->user_virtual; in drm_intel_gem_bo_map()
1298 mmap_arg.size = bo->size; in drm_intel_gem_bo_map()
1317 bo->virtual = bo_gem->mem_virtual; in drm_intel_gem_bo_map()
1338 drm_intel_gem_bo_mark_mmaps_incoherent(bo); in drm_intel_gem_bo_map()
1339 VG(VALGRIND_MAKE_MEM_DEFINED(bo_gem->mem_virtual, bo->size)); in drm_intel_gem_bo_map()
1346 map_gtt(drm_intel_bo *bo) in map_gtt() argument
1348 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in map_gtt()
1349 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in map_gtt()
1384 bo_gem->gtt_virtual = drm_mmap(0, bo->size, PROT_READ | PROT_WRITE, in map_gtt()
1400 bo->virtual = bo_gem->gtt_virtual; in map_gtt()
1409 drm_intel_gem_bo_map_gtt(drm_intel_bo *bo) in drm_intel_gem_bo_map_gtt() argument
1411 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_map_gtt()
1412 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_map_gtt()
1418 ret = map_gtt(bo); in drm_intel_gem_bo_map_gtt()
1446 drm_intel_gem_bo_mark_mmaps_incoherent(bo); in drm_intel_gem_bo_map_gtt()
1447 VG(VALGRIND_MAKE_MEM_DEFINED(bo_gem->gtt_virtual, bo->size)); in drm_intel_gem_bo_map_gtt()
1468 drm_intel_gem_bo_map_unsynchronized(drm_intel_bo *bo) in drm_intel_gem_bo_map_unsynchronized() argument
1470 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_map_unsynchronized()
1472 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_map_unsynchronized()
1484 return drm_intel_gem_bo_map_gtt(bo); in drm_intel_gem_bo_map_unsynchronized()
1488 ret = map_gtt(bo); in drm_intel_gem_bo_map_unsynchronized()
1490 drm_intel_gem_bo_mark_mmaps_incoherent(bo); in drm_intel_gem_bo_map_unsynchronized()
1491 VG(VALGRIND_MAKE_MEM_DEFINED(bo_gem->gtt_virtual, bo->size)); in drm_intel_gem_bo_map_unsynchronized()
1499 static int drm_intel_gem_bo_unmap(drm_intel_bo *bo) in drm_intel_gem_bo_unmap() argument
1502 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_unmap()
1505 if (bo == NULL) in drm_intel_gem_bo_unmap()
1511 bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_unmap()
1548 drm_intel_gem_bo_mark_mmaps_incoherent(bo); in drm_intel_gem_bo_unmap()
1549 bo->virtual = NULL; in drm_intel_gem_bo_unmap()
1557 drm_intel_gem_bo_unmap_gtt(drm_intel_bo *bo) in drm_intel_gem_bo_unmap_gtt() argument
1559 return drm_intel_gem_bo_unmap(bo); in drm_intel_gem_bo_unmap_gtt()
1563 drm_intel_gem_bo_subdata(drm_intel_bo *bo, unsigned long offset, in drm_intel_gem_bo_subdata() argument
1566 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_subdata()
1567 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_subdata()
1618 drm_intel_gem_bo_get_subdata(drm_intel_bo *bo, unsigned long offset, in drm_intel_gem_bo_get_subdata() argument
1621 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_get_subdata()
1622 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_get_subdata()
1649 drm_intel_gem_bo_wait_rendering(drm_intel_bo *bo) in drm_intel_gem_bo_wait_rendering() argument
1651 drm_intel_gem_bo_start_gtt_access(bo, 1); in drm_intel_gem_bo_wait_rendering()
1679 drm_intel_gem_bo_wait(drm_intel_bo *bo, int64_t timeout_ns) in drm_intel_gem_bo_wait() argument
1681 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_wait()
1682 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_wait()
1690 drm_intel_gem_bo_wait_rendering(bo); in drm_intel_gem_bo_wait()
1693 return drm_intel_gem_bo_busy(bo) ? -ETIME : 0; in drm_intel_gem_bo_wait()
1715 drm_intel_gem_bo_start_gtt_access(drm_intel_bo *bo, int write_enable) in drm_intel_gem_bo_start_gtt_access() argument
1717 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_start_gtt_access()
1718 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_start_gtt_access()
1761 drm_intel_gem_bo_free(&bo_gem->bo); in drm_intel_bufmgr_gem_destroy()
1778 do_bo_emit_reloc(drm_intel_bo *bo, uint32_t offset, in do_bo_emit_reloc() argument
1783 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in do_bo_emit_reloc()
1784 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in do_bo_emit_reloc()
1805 if (bo_gem->relocs == NULL && drm_intel_setup_reloc_list(bo)) in do_bo_emit_reloc()
1812 assert(offset <= bo->size - 4); in do_bo_emit_reloc()
1841 bo_gem->reloc_target_info[bo_gem->reloc_count].bo = target_bo; in do_bo_emit_reloc()
1842 if (target_bo != bo) in do_bo_emit_reloc()
1856 drm_intel_gem_bo_emit_reloc(drm_intel_bo *bo, uint32_t offset, in drm_intel_gem_bo_emit_reloc() argument
1860 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *)bo->bufmgr; in drm_intel_gem_bo_emit_reloc()
1862 return do_bo_emit_reloc(bo, offset, target_bo, target_offset, in drm_intel_gem_bo_emit_reloc()
1868 drm_intel_gem_bo_emit_reloc_fence(drm_intel_bo *bo, uint32_t offset, in drm_intel_gem_bo_emit_reloc_fence() argument
1873 return do_bo_emit_reloc(bo, offset, target_bo, target_offset, in drm_intel_gem_bo_emit_reloc_fence()
1878 drm_intel_gem_bo_get_reloc_count(drm_intel_bo *bo) in drm_intel_gem_bo_get_reloc_count() argument
1880 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_get_reloc_count()
1899 drm_intel_gem_bo_clear_relocs(drm_intel_bo *bo, int start) in drm_intel_gem_bo_clear_relocs() argument
1901 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_clear_relocs()
1902 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_clear_relocs()
1914 drm_intel_bo_gem *target_bo_gem = (drm_intel_bo_gem *) bo_gem->reloc_target_info[i].bo; in drm_intel_gem_bo_clear_relocs()
1915 if (&target_bo_gem->bo != bo) { in drm_intel_gem_bo_clear_relocs()
1917 drm_intel_gem_bo_unreference_locked_timed(&target_bo_gem->bo, in drm_intel_gem_bo_clear_relocs()
1933 drm_intel_gem_bo_process_reloc(drm_intel_bo *bo) in drm_intel_gem_bo_process_reloc() argument
1935 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_process_reloc()
1942 drm_intel_bo *target_bo = bo_gem->reloc_target_info[i].bo; in drm_intel_gem_bo_process_reloc()
1944 if (target_bo == bo) in drm_intel_gem_bo_process_reloc()
1947 drm_intel_gem_bo_mark_mmaps_incoherent(bo); in drm_intel_gem_bo_process_reloc()
1958 drm_intel_gem_bo_process_reloc2(drm_intel_bo *bo) in drm_intel_gem_bo_process_reloc2() argument
1960 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *)bo; in drm_intel_gem_bo_process_reloc2()
1967 drm_intel_bo *target_bo = bo_gem->reloc_target_info[i].bo; in drm_intel_gem_bo_process_reloc2()
1970 if (target_bo == bo) in drm_intel_gem_bo_process_reloc2()
1973 drm_intel_gem_bo_mark_mmaps_incoherent(bo); in drm_intel_gem_bo_process_reloc2()
1993 drm_intel_bo *bo = bufmgr_gem->exec_bos[i]; in drm_intel_update_buffer_offsets() local
1994 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_update_buffer_offsets()
1997 if (bufmgr_gem->exec_objects[i].offset != bo->offset64) { in drm_intel_update_buffer_offsets()
1999 bo_gem->gem_handle, bo_gem->name, bo->offset64, in drm_intel_update_buffer_offsets()
2002 bo->offset64 = bufmgr_gem->exec_objects[i].offset; in drm_intel_update_buffer_offsets()
2003 bo->offset = bufmgr_gem->exec_objects[i].offset; in drm_intel_update_buffer_offsets()
2014 drm_intel_bo *bo = bufmgr_gem->exec_bos[i]; in drm_intel_update_buffer_offsets2() local
2015 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *)bo; in drm_intel_update_buffer_offsets2()
2018 if (bufmgr_gem->exec2_objects[i].offset != bo->offset64) { in drm_intel_update_buffer_offsets2()
2020 bo_gem->gem_handle, bo_gem->name, bo->offset64, in drm_intel_update_buffer_offsets2()
2022 bo->offset64 = bufmgr_gem->exec2_objects[i].offset; in drm_intel_update_buffer_offsets2()
2023 bo->offset = bufmgr_gem->exec2_objects[i].offset; in drm_intel_update_buffer_offsets2()
2041 aub_write_bo_data(drm_intel_bo *bo, uint32_t offset, uint32_t size) in aub_write_bo_data() argument
2043 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in aub_write_bo_data()
2044 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in aub_write_bo_data()
2048 data = malloc(bo->size); in aub_write_bo_data()
2049 drm_intel_bo_get_subdata(bo, offset, size, data); in aub_write_bo_data()
2072 target_gem = (drm_intel_bo_gem *)info->bo; in aub_write_bo_data()
2092 aub_bo_get_address(drm_intel_bo *bo) in aub_bo_get_address() argument
2094 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in aub_bo_get_address()
2095 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in aub_bo_get_address()
2106 bufmgr_gem->aub_offset += bo->size; in aub_bo_get_address()
2112 aub_write_trace_block(drm_intel_bo *bo, uint32_t type, uint32_t subtype, in aub_write_trace_block() argument
2115 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in aub_write_trace_block()
2116 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in aub_write_trace_block()
2128 aub_write_bo_data(bo, offset, size); in aub_write_trace_block()
2137 aub_write_large_trace_block(drm_intel_bo *bo, uint32_t type, uint32_t subtype, in aub_write_large_trace_block() argument
2149 aub_write_trace_block(bo, type, subtype, offset + sub_offset, in aub_write_large_trace_block()
2155 aub_write_bo(drm_intel_bo *bo) in aub_write_bo() argument
2157 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in aub_write_bo()
2161 aub_bo_get_address(bo); in aub_write_bo()
2168 if (ending_offset > bo->size) in aub_write_bo()
2169 ending_offset = bo->size; in aub_write_bo()
2171 aub_write_large_trace_block(bo, annotation->type, in aub_write_bo()
2180 if (offset < bo->size) { in aub_write_bo()
2181 aub_write_large_trace_block(bo, AUB_TRACE_TYPE_NOTYPE, 0, in aub_write_bo()
2182 offset, bo->size - offset); in aub_write_bo()
2235 drm_intel_gem_bo_aub_dump_bmp(drm_intel_bo *bo, in drm_intel_gem_bo_aub_dump_bmp() argument
2240 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_aub_dump_bmp()
2241 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *)bo; in drm_intel_gem_bo_aub_dump_bmp()
2277 aub_exec(drm_intel_bo *bo, int ring_flag, int used) in aub_exec() argument
2279 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in aub_exec()
2280 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in aub_exec()
2294 { AUB_TRACE_TYPE_NOTYPE, 0, bo->size } in aub_exec()
2296 drm_intel_bufmgr_gem_set_aub_annotations(bo, annotations, 2); in aub_exec()
2306 drm_intel_bufmgr_gem_set_aub_annotations(bo, NULL, 0); in aub_exec()
2322 drm_intel_gem_bo_exec(drm_intel_bo *bo, int used, in drm_intel_gem_bo_exec() argument
2325 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_exec()
2326 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_exec()
2335 drm_intel_gem_bo_process_reloc(bo); in drm_intel_gem_bo_exec()
2340 drm_intel_add_validate_buffer(bo); in drm_intel_gem_bo_exec()
2375 drm_intel_bo *bo = bufmgr_gem->exec_bos[i]; in drm_intel_gem_bo_exec() local
2376 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_exec()
2391 do_exec2(drm_intel_bo *bo, int used, drm_intel_context *ctx, in do_exec2() argument
2395 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *)bo->bufmgr; in do_exec2()
2422 drm_intel_gem_bo_process_reloc2(bo); in do_exec2()
2427 drm_intel_add_validate_buffer2(bo, 0); in do_exec2()
2445 aub_exec(bo, flags, used); in do_exec2()
2472 drm_intel_bo *bo = bufmgr_gem->exec_bos[i]; in do_exec2() local
2473 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *)bo; in do_exec2()
2488 drm_intel_gem_bo_exec2(drm_intel_bo *bo, int used, in drm_intel_gem_bo_exec2() argument
2492 return do_exec2(bo, used, NULL, cliprects, num_cliprects, DR4, in drm_intel_gem_bo_exec2()
2497 drm_intel_gem_bo_mrb_exec2(drm_intel_bo *bo, int used, in drm_intel_gem_bo_mrb_exec2() argument
2501 return do_exec2(bo, used, NULL, cliprects, num_cliprects, DR4, in drm_intel_gem_bo_mrb_exec2()
2506 drm_intel_gem_bo_context_exec(drm_intel_bo *bo, drm_intel_context *ctx, in drm_intel_gem_bo_context_exec() argument
2509 return do_exec2(bo, used, ctx, NULL, 0, 0, flags); in drm_intel_gem_bo_context_exec()
2513 drm_intel_gem_bo_pin(drm_intel_bo *bo, uint32_t alignment) in drm_intel_gem_bo_pin() argument
2515 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_pin()
2516 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_pin()
2530 bo->offset64 = pin.offset; in drm_intel_gem_bo_pin()
2531 bo->offset = pin.offset; in drm_intel_gem_bo_pin()
2536 drm_intel_gem_bo_unpin(drm_intel_bo *bo) in drm_intel_gem_bo_unpin() argument
2538 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_unpin()
2539 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_unpin()
2554 drm_intel_gem_bo_set_tiling_internal(drm_intel_bo *bo, in drm_intel_gem_bo_set_tiling_internal() argument
2558 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_set_tiling_internal()
2559 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_set_tiling_internal()
2592 drm_intel_gem_bo_set_tiling(drm_intel_bo *bo, uint32_t * tiling_mode, in drm_intel_gem_bo_set_tiling() argument
2595 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_set_tiling()
2596 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_set_tiling()
2611 ret = drm_intel_gem_bo_set_tiling_internal(bo, *tiling_mode, stride); in drm_intel_gem_bo_set_tiling()
2620 drm_intel_gem_bo_get_tiling(drm_intel_bo *bo, uint32_t * tiling_mode, in drm_intel_gem_bo_get_tiling() argument
2623 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_get_tiling()
2653 drm_intel_gem_bo_reference(&bo_gem->bo); in drm_intel_bo_gem_create_from_prime()
2655 return &bo_gem->bo; in drm_intel_bo_gem_create_from_prime()
2677 bo_gem->bo.size = ret; in drm_intel_bo_gem_create_from_prime()
2679 bo_gem->bo.size = size; in drm_intel_bo_gem_create_from_prime()
2681 bo_gem->bo.handle = handle; in drm_intel_bo_gem_create_from_prime()
2682 bo_gem->bo.bufmgr = bufmgr; in drm_intel_bo_gem_create_from_prime()
2705 drm_intel_gem_bo_unreference(&bo_gem->bo); in drm_intel_bo_gem_create_from_prime()
2713 return &bo_gem->bo; in drm_intel_bo_gem_create_from_prime()
2717 drm_intel_bo_gem_export_to_prime(drm_intel_bo *bo, int *prime_fd) in drm_intel_bo_gem_export_to_prime() argument
2719 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_bo_gem_export_to_prime()
2720 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_bo_gem_export_to_prime()
2737 drm_intel_gem_bo_flink(drm_intel_bo *bo, uint32_t * name) in drm_intel_gem_bo_flink() argument
2739 drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *) bo->bufmgr; in drm_intel_gem_bo_flink()
2740 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_flink()
2805 drm_intel_gem_bo_get_aperture_space(drm_intel_bo *bo) in drm_intel_gem_bo_get_aperture_space() argument
2807 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_get_aperture_space()
2811 if (bo == NULL || bo_gem->included_in_check_aperture) in drm_intel_gem_bo_get_aperture_space()
2814 total += bo->size; in drm_intel_gem_bo_get_aperture_space()
2820 reloc_target_info[i].bo); in drm_intel_gem_bo_get_aperture_space()
2855 drm_intel_gem_bo_clear_aperture_space_flag(drm_intel_bo *bo) in drm_intel_gem_bo_clear_aperture_space_flag() argument
2857 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_clear_aperture_space_flag()
2860 if (bo == NULL || !bo_gem->included_in_check_aperture) in drm_intel_gem_bo_clear_aperture_space_flag()
2867 reloc_target_info[i].bo); in drm_intel_gem_bo_clear_aperture_space_flag()
2976 drm_intel_gem_bo_disable_reuse(drm_intel_bo *bo) in drm_intel_gem_bo_disable_reuse() argument
2978 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_disable_reuse()
2985 drm_intel_gem_bo_is_reusable(drm_intel_bo *bo) in drm_intel_gem_bo_is_reusable() argument
2987 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_gem_bo_is_reusable()
2993 _drm_intel_gem_bo_references(drm_intel_bo *bo, drm_intel_bo *target_bo) in _drm_intel_gem_bo_references() argument
2995 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in _drm_intel_gem_bo_references()
2999 if (bo_gem->reloc_target_info[i].bo == target_bo) in _drm_intel_gem_bo_references()
3001 if (bo == bo_gem->reloc_target_info[i].bo) in _drm_intel_gem_bo_references()
3003 if (_drm_intel_gem_bo_references(bo_gem->reloc_target_info[i].bo, in _drm_intel_gem_bo_references()
3013 drm_intel_gem_bo_references(drm_intel_bo *bo, drm_intel_bo *target_bo) in drm_intel_gem_bo_references() argument
3017 if (bo == NULL || target_bo == NULL) in drm_intel_gem_bo_references()
3020 return _drm_intel_gem_bo_references(bo, target_bo); in drm_intel_gem_bo_references()
3320 drm_intel_bufmgr_gem_set_aub_annotations(drm_intel_bo *bo, in drm_intel_bufmgr_gem_set_aub_annotations() argument
3324 drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; in drm_intel_bufmgr_gem_set_aub_annotations()