From e9fe18727e1ba01544fff78c2d584d44b392086e Mon Sep 17 00:00:00 2001 From: Icenowy Zheng Date: Wed, 7 Aug 2024 13:50:01 +0800 Subject: [PATCH] pvr: emit tpu_tag_cdm_ctrl in compute stream when present An extra control register word, tpu_tag_cdm_ctrl, will be present when TPU_DM_GLOBAL_REGISTERS feature is present. Emit it when it's needed. The document of this register is available, however I don't think any of the bits are needed to be set for our current feature set, so just emit 0 now. Signed-off-by: Icenowy Zheng Reviewed-by: Frank Binns Part-of: --- src/imagination/csbgen/rogue_cr.xml | 8 ++++++++ src/imagination/vulkan/pvr_job_compute.c | 6 ++++++ 2 files changed, 14 insertions(+) diff --git a/src/imagination/csbgen/rogue_cr.xml b/src/imagination/csbgen/rogue_cr.xml index 8ce85bc3009..823026654a0 100644 --- a/src/imagination/csbgen/rogue_cr.xml +++ b/src/imagination/csbgen/rogue_cr.xml @@ -663,6 +663,14 @@ SOFTWARE. + + + + + + + + diff --git a/src/imagination/vulkan/pvr_job_compute.c b/src/imagination/vulkan/pvr_job_compute.c index ebd4d9cf626..a773a498e70 100644 --- a/src/imagination/vulkan/pvr_job_compute.c +++ b/src/imagination/vulkan/pvr_job_compute.c @@ -119,6 +119,12 @@ pvr_submit_info_stream_init(struct pvr_compute_ctx *ctx, stream_ptr += pvr_cmd_length(CR_COMPUTE_CLUSTER); } + if (PVR_HAS_FEATURE(dev_info, tpu_dm_global_registers)) { + pvr_csb_pack (stream_ptr, CR_TPU_TAG_CDM_CTRL, value) { + } + stream_ptr += pvr_cmd_length(CR_TPU_TAG_CDM_CTRL); + } + if (PVR_HAS_FEATURE(dev_info, gpu_multicore_support)) { pvr_finishme( "Emit execute_count when feature gpu_multicore_support is present");