• Home
  • Raw
  • Download

Lines Matching refs:iview

171 tu_cs_image_ref(struct tu_cs *cs, const struct tu_image_view *iview, uint32_t layer)  in tu_cs_image_ref()  argument
173 tu_cs_emit(cs, iview->PITCH); in tu_cs_image_ref()
174 tu_cs_emit(cs, iview->layer_size >> 6); in tu_cs_image_ref()
175 tu_cs_emit_qw(cs, iview->base_addr + iview->layer_size * layer); in tu_cs_image_ref()
179 tu_cs_image_stencil_ref(struct tu_cs *cs, const struct tu_image_view *iview, uint32_t layer) in tu_cs_image_stencil_ref() argument
181 tu_cs_emit(cs, iview->stencil_PITCH); in tu_cs_image_stencil_ref()
182 tu_cs_emit(cs, iview->stencil_layer_size >> 6); in tu_cs_image_stencil_ref()
183 tu_cs_emit_qw(cs, iview->stencil_base_addr + iview->stencil_layer_size * layer); in tu_cs_image_stencil_ref()
187 tu_cs_image_ref_2d(struct tu_cs *cs, const struct tu_image_view *iview, uint32_t layer, bool src) in tu_cs_image_ref_2d() argument
189 tu_cs_emit_qw(cs, iview->base_addr + iview->layer_size * layer); in tu_cs_image_ref_2d()
191 tu_cs_emit(cs, iview->PITCH << (src ? 9 : 0)); in tu_cs_image_ref_2d()
195 tu_cs_image_flag_ref(struct tu_cs *cs, const struct tu_image_view *iview, uint32_t layer) in tu_cs_image_flag_ref() argument
197 tu_cs_emit_qw(cs, iview->ubwc_addr + iview->ubwc_layer_size * layer); in tu_cs_image_flag_ref()
198 tu_cs_emit(cs, iview->FLAG_BUFFER_PITCH); in tu_cs_image_flag_ref()
202 tu_image_view_init(struct tu_image_view *iview, in tu_image_view_init() argument
216 iview->image = image; in tu_image_view_init()
218 memset(iview->descriptor, 0, sizeof(iview->descriptor)); in tu_image_view_init()
275 iview->descriptor[0] = in tu_image_view_init()
283 iview->descriptor[1] = A6XX_TEX_CONST_1_WIDTH(width) | A6XX_TEX_CONST_1_HEIGHT(height); in tu_image_view_init()
284 iview->descriptor[2] = in tu_image_view_init()
288 iview->descriptor[3] = A6XX_TEX_CONST_3_ARRAY_PITCH(layer_size); in tu_image_view_init()
289 iview->descriptor[4] = base_addr; in tu_image_view_init()
290 iview->descriptor[5] = (base_addr >> 32) | A6XX_TEX_CONST_5_DEPTH(depth); in tu_image_view_init()
293 iview->descriptor[3] |= A6XX_TEX_CONST_3_TILE_ALL; in tu_image_view_init()
301 iview->descriptor[0] |= A6XX_TEX_CONST_0_CHROMA_MIDPOINT_X; in tu_image_view_init()
303 iview->descriptor[0] |= A6XX_TEX_CONST_0_CHROMA_MIDPOINT_Y; in tu_image_view_init()
308 iview->descriptor[3] |= A6XX_TEX_CONST_3_TILE_ALL; in tu_image_view_init()
310 iview->descriptor[3] |= A6XX_TEX_CONST_3_FLAG; in tu_image_view_init()
323 iview->descriptor[4] = base_addr[0]; in tu_image_view_init()
324 iview->descriptor[5] |= base_addr[0] >> 32; in tu_image_view_init()
325 iview->descriptor[6] = in tu_image_view_init()
327 iview->descriptor[7] = base_addr[1]; in tu_image_view_init()
328 iview->descriptor[8] = base_addr[1] >> 32; in tu_image_view_init()
329 iview->descriptor[9] = base_addr[2]; in tu_image_view_init()
330 iview->descriptor[10] = base_addr[2] >> 32; in tu_image_view_init()
340 iview->descriptor[3] |= A6XX_TEX_CONST_3_FLAG; in tu_image_view_init()
341 iview->descriptor[7] = ubwc_addr; in tu_image_view_init()
342 iview->descriptor[8] = ubwc_addr >> 32; in tu_image_view_init()
343iview->descriptor[9] |= A6XX_TEX_CONST_9_FLAG_BUFFER_ARRAY_PITCH(layout->ubwc_layer_size >> 2); in tu_image_view_init()
344 iview->descriptor[10] |= in tu_image_view_init()
351 iview->descriptor[3] |= in tu_image_view_init()
355 iview->SP_PS_2D_SRC_INFO = A6XX_SP_PS_2D_SRC_INFO( in tu_image_view_init()
367 iview->SP_PS_2D_SRC_SIZE = in tu_image_view_init()
371 iview->PITCH = A6XX_RB_DEPTH_BUFFER_PITCH(pitch).value; in tu_image_view_init()
372 iview->FLAG_BUFFER_PITCH = A6XX_RB_DEPTH_FLAG_BUFFER_PITCH( in tu_image_view_init()
375 iview->base_addr = base_addr; in tu_image_view_init()
376 iview->ubwc_addr = ubwc_addr; in tu_image_view_init()
377 iview->layer_size = layer_size; in tu_image_view_init()
378 iview->ubwc_layer_size = layout->ubwc_layer_size; in tu_image_view_init()
392 memset(iview->storage_descriptor, 0, sizeof(iview->storage_descriptor)); in tu_image_view_init()
394 iview->storage_descriptor[0] = in tu_image_view_init()
397 iview->storage_descriptor[1] = in tu_image_view_init()
400 iview->storage_descriptor[2] = in tu_image_view_init()
403 iview->storage_descriptor[3] = A6XX_IBO_3_ARRAY_PITCH(layer_size); in tu_image_view_init()
405 iview->storage_descriptor[4] = base_addr; in tu_image_view_init()
406 iview->storage_descriptor[5] = (base_addr >> 32) | A6XX_IBO_5_DEPTH(storage_depth); in tu_image_view_init()
409 iview->storage_descriptor[3] |= A6XX_IBO_3_FLAG | A6XX_IBO_3_UNK27; in tu_image_view_init()
410 iview->storage_descriptor[7] |= ubwc_addr; in tu_image_view_init()
411 iview->storage_descriptor[8] |= ubwc_addr >> 32; in tu_image_view_init()
412iview->storage_descriptor[9] = A6XX_IBO_9_FLAG_BUFFER_ARRAY_PITCH(layout->ubwc_layer_size >> 2); in tu_image_view_init()
413 iview->storage_descriptor[10] = in tu_image_view_init()
417 iview->extent.width = width; in tu_image_view_init()
418 iview->extent.height = height; in tu_image_view_init()
419 iview->need_y2_align = in tu_image_view_init()
422 iview->ubwc_enabled = ubwc_enabled; in tu_image_view_init()
424 iview->RB_MRT_BUF_INFO = A6XX_RB_MRT_BUF_INFO(0, in tu_image_view_init()
429 iview->SP_FS_MRT_REG = A6XX_SP_FS_MRT_REG(0, in tu_image_view_init()
434 iview->RB_2D_DST_INFO = A6XX_RB_2D_DST_INFO( in tu_image_view_init()
441 iview->RB_BLIT_DST_INFO = A6XX_RB_BLIT_DST_INFO( in tu_image_view_init()
450 iview->stencil_base_addr = image->bo->iova + image->bo_offset + in tu_image_view_init()
452 iview->stencil_layer_size = fdl_layer_stride(layout, range->baseMipLevel); in tu_image_view_init()
453iview->stencil_PITCH = A6XX_RB_STENCIL_BUFFER_PITCH(fdl_pitch(layout, range->baseMipLevel)).value; in tu_image_view_init()
837 TU_FROM_HANDLE(tu_image_view, iview, _iview); in tu_DestroyImageView()
839 if (!iview) in tu_DestroyImageView()
842 vk_object_free(&device->vk, pAllocator, iview); in tu_DestroyImageView()