• Home
  • Raw
  • Download

Lines Matching refs:sctx

35 static unsigned encode_tile_info(struct si_context *sctx, struct si_texture *tex, unsigned level,  in encode_tile_info()  argument
38 struct radeon_info *info = &sctx->screen->info; in encode_tile_info()
55 static bool si_sdma_v4_copy_texture(struct si_context *sctx, struct pipe_resource *dst, in si_sdma_v4_copy_texture() argument
85 if (!si_prepare_for_dma_blit(sctx, sdst, dst_level, dstx, dsty, dstz, ssrc, src_level, src_box)) in si_sdma_v4_copy_texture()
97 struct radeon_cmdbuf *cs = sctx->sdma_cs; in si_sdma_v4_copy_texture()
105 si_need_dma_space(sctx, 13, &sdst->buffer, &ssrc->buffer); in si_sdma_v4_copy_texture()
116 sctx->ws->cs_is_secure(cs) ? (1u << 2) : 0) | in si_sdma_v4_copy_texture()
156 struct radeon_cmdbuf *cs = sctx->sdma_cs; in si_sdma_v4_copy_texture()
173 si_need_dma_space(sctx, 14, &sdst->buffer, &ssrc->buffer); in si_sdma_v4_copy_texture()
177 sctx->ws->cs_is_secure(cs) ? (1u << 2) : 0) | in si_sdma_v4_copy_texture()
201 static bool cik_sdma_copy_texture(struct si_context *sctx, struct pipe_resource *dst, in cik_sdma_copy_texture() argument
206 struct radeon_info *info = &sctx->screen->info; in cik_sdma_copy_texture()
248 if (!si_prepare_for_dma_blit(sctx, sdst, dst_level, dstx, dsty, dstz, ssrc, src_level, src_box)) in cik_sdma_copy_texture()
268 (sctx->chip_class != GFX7 || in cik_sdma_copy_texture()
271 ((sctx->family != CHIP_BONAIRE && sctx->family != CHIP_KAVERI) || in cik_sdma_copy_texture()
273 struct radeon_cmdbuf *cs = sctx->sdma_cs; in cik_sdma_copy_texture()
275 si_need_dma_space(sctx, 13, &sdst->buffer, &ssrc->buffer); in cik_sdma_copy_texture()
290 if (sctx->chip_class == GFX7) { in cik_sdma_copy_texture()
340 if ((sctx->family == CHIP_BONAIRE || sctx->family == CHIP_KAVERI) && in cik_sdma_copy_texture()
344 if (sctx->chip_class == GFX7 && in cik_sdma_copy_texture()
348 if ((sctx->family == CHIP_BONAIRE || sctx->family == CHIP_KAVERI || in cik_sdma_copy_texture()
349 sctx->family == CHIP_KABINI) && in cik_sdma_copy_texture()
410 struct radeon_cmdbuf *cs = sctx->sdma_cs; in cik_sdma_copy_texture()
413 si_need_dma_space(sctx, 14, &sdst->buffer, &ssrc->buffer); in cik_sdma_copy_texture()
423 radeon_emit(cs, encode_tile_info(sctx, tiled, tiled_level, true)); in cik_sdma_copy_texture()
429 if (sctx->chip_class == GFX7) { in cik_sdma_copy_texture()
448 (sctx->chip_class >= GFX8 && src_micro_mode == V_009910_ADDR_SURF_DISPLAY_MICRO_TILING && in cik_sdma_copy_texture()
478 (sctx->chip_class != GFX7 || in cik_sdma_copy_texture()
482 ((sctx->family != CHIP_BONAIRE && sctx->family != CHIP_KAVERI && in cik_sdma_copy_texture()
483 sctx->family != CHIP_KABINI) || in cik_sdma_copy_texture()
486 struct radeon_cmdbuf *cs = sctx->sdma_cs; in cik_sdma_copy_texture()
488 si_need_dma_space(sctx, 15, &sdst->buffer, &ssrc->buffer); in cik_sdma_copy_texture()
497 radeon_emit(cs, encode_tile_info(sctx, ssrc, src_level, true)); in cik_sdma_copy_texture()
503 radeon_emit(cs, encode_tile_info(sctx, sdst, dst_level, false)); in cik_sdma_copy_texture()
504 if (sctx->chip_class == GFX7) { in cik_sdma_copy_texture()
522 struct si_context *sctx = (struct si_context *)ctx; in cik_sdma_copy() local
526 if (!sctx->sdma_cs || src->flags & PIPE_RESOURCE_FLAG_SPARSE || in cik_sdma_copy()
536 if (sctx->screen->debug_flags & DBG(FORCE_SDMA) || in cik_sdma_copy()
537 (!sctx->screen->info.has_dedicated_vram && in cik_sdma_copy()
538 !(sctx->screen->debug_flags & DBG(NO_SDMA_COPY_IMAGE)))) { in cik_sdma_copy()
539 if ((sctx->chip_class == GFX7 || sctx->chip_class == GFX8) && in cik_sdma_copy()
540 cik_sdma_copy_texture(sctx, dst, dst_level, dstx, dsty, dstz, src, src_level, src_box)) in cik_sdma_copy()
542 else if (sctx->chip_class == GFX9 && si_sdma_v4_copy_texture(sctx, dst, dst_level, dstx, dsty, in cik_sdma_copy()
551 void cik_init_sdma_functions(struct si_context *sctx) in cik_init_sdma_functions() argument
553 sctx->dma_copy = cik_sdma_copy; in cik_init_sdma_functions()