From: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
To: Bjorn Andersson <andersson@kernel.org>,
Konrad Dybcio <konradybcio@kernel.org>,
Rob Clark <robin.clark@oss.qualcomm.com>,
Dmitry Baryshkov <lumag@kernel.org>,
Abhinav Kumar <abhinav.kumar@linux.dev>,
Jessica Zhang <jesszhan0024@gmail.com>,
Sean Paul <sean@poorly.run>,
Marijn Suijten <marijn.suijten@somainline.org>,
David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
Akhil P Oommen <akhilpo@oss.qualcomm.com>,
Vikash Garodia <vikash.garodia@oss.qualcomm.com>,
Dikshita Agarwal <dikshita.agarwal@oss.qualcomm.com>,
Bryan O'Donoghue <bod@kernel.org>,
Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>,
linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org,
linux-media@vger.kernel.org
Subject: [PATCH 04/11] media: iris: don't specify min_acc_length in the source code
Date: Sat, 10 Jan 2026 21:37:56 +0200 [thread overview]
Message-ID: <20260110-iris-ubwc-v1-4-dd70494dcd7b@oss.qualcomm.com> (raw)
In-Reply-To: <20260110-iris-ubwc-v1-0-dd70494dcd7b@oss.qualcomm.com>
The min_acc length can be calculated from the platform UBWC
configuration. Use the freshly introduced helper and calculate min_acc
length based on the platform UBWC configuration instead of specifying it
directly in the source.
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
---
drivers/media/platform/qcom/iris/iris_hfi_gen2_packet.c | 5 ++++-
drivers/media/platform/qcom/iris/iris_platform_common.h | 1 -
drivers/media/platform/qcom/iris/iris_platform_gen2.c | 1 -
3 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/media/platform/qcom/iris/iris_hfi_gen2_packet.c b/drivers/media/platform/qcom/iris/iris_hfi_gen2_packet.c
index d77fa29f44fc..878e61aa77c3 100644
--- a/drivers/media/platform/qcom/iris/iris_hfi_gen2_packet.c
+++ b/drivers/media/platform/qcom/iris/iris_hfi_gen2_packet.c
@@ -3,6 +3,8 @@
* Copyright (c) 2022-2024 Qualcomm Innovation Center, Inc. All rights reserved.
*/
+#include <linux/soc/qcom/ubwc.h>
+
#include "iris_hfi_common.h"
#include "iris_hfi_gen2.h"
#include "iris_hfi_gen2_packet.h"
@@ -120,6 +122,7 @@ static void iris_hfi_gen2_create_packet(struct iris_hfi_header *hdr, u32 pkt_typ
void iris_hfi_gen2_packet_sys_init(struct iris_core *core, struct iris_hfi_header *hdr)
{
+ const struct qcom_ubwc_cfg_data *ubwc = core->ubwc_cfg;
u32 payload = 0;
iris_hfi_gen2_create_header(hdr, 0, core->header_id++);
@@ -146,7 +149,7 @@ void iris_hfi_gen2_packet_sys_init(struct iris_core *core, struct iris_hfi_heade
&payload,
sizeof(u32));
- payload = core->iris_platform_data->ubwc_config->mal_length;
+ payload = qcom_ubwc_min_acc_length_64b(ubwc) ? 64 : 32;
iris_hfi_gen2_create_packet(hdr,
HFI_PROP_UBWC_MAL_LENGTH,
HFI_HOST_FLAGS_NONE,
diff --git a/drivers/media/platform/qcom/iris/iris_platform_common.h b/drivers/media/platform/qcom/iris/iris_platform_common.h
index 8d8cdb56a3c7..3c5f3f68b722 100644
--- a/drivers/media/platform/qcom/iris/iris_platform_common.h
+++ b/drivers/media/platform/qcom/iris/iris_platform_common.h
@@ -73,7 +73,6 @@ struct tz_cp_config {
struct ubwc_config_data {
u32 max_channels;
- u32 mal_length;
u32 highest_bank_bit;
u32 bank_swzl_level;
u32 bank_swz2_level;
diff --git a/drivers/media/platform/qcom/iris/iris_platform_gen2.c b/drivers/media/platform/qcom/iris/iris_platform_gen2.c
index c1989240c248..c70cfc2fc553 100644
--- a/drivers/media/platform/qcom/iris/iris_platform_gen2.c
+++ b/drivers/media/platform/qcom/iris/iris_platform_gen2.c
@@ -633,7 +633,6 @@ static const struct platform_clk_data sm8550_clk_table[] = {
static struct ubwc_config_data ubwc_config_sm8550 = {
.max_channels = 8,
- .mal_length = 32,
.highest_bank_bit = 16,
.bank_swzl_level = 0,
.bank_swz2_level = 1,
--
2.47.3
next prev parent reply other threads:[~2026-01-10 19:38 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-10 19:37 [PATCH 00/11] media: iris: migrate to using global UBWC config Dmitry Baryshkov
2026-01-10 19:37 ` [PATCH 01/11] soc: qcom: ubwc: add missing include Dmitry Baryshkov
2026-01-11 20:58 ` Bryan O'Donoghue
2026-01-10 19:37 ` [PATCH 02/11] soc: qcom: ubwc: add helper to get min_acc length Dmitry Baryshkov
2026-01-11 21:03 ` Bryan O'Donoghue
2026-01-11 21:05 ` Bryan O'Donoghue
2026-01-11 22:39 ` Dmitry Baryshkov
2026-01-12 11:08 ` Konrad Dybcio
2026-01-13 0:24 ` Dmitry Baryshkov
2026-01-13 15:26 ` Konrad Dybcio
2026-01-13 16:48 ` Dmitry Baryshkov
2026-01-14 22:22 ` Bjorn Andersson
2026-01-10 19:37 ` [PATCH 03/11] media: iris: retrieve UBWC platform configuration Dmitry Baryshkov
2026-01-11 21:01 ` Bryan O'Donoghue
2026-01-10 19:37 ` Dmitry Baryshkov [this message]
2026-01-11 21:06 ` [PATCH 04/11] media: iris: don't specify min_acc_length in the source code Bryan O'Donoghue
2026-01-11 22:43 ` Dmitry Baryshkov
2026-01-10 19:37 ` [PATCH 05/11] media: iris: don't specify highest_bank_bit " Dmitry Baryshkov
2026-01-11 21:07 ` Bryan O'Donoghue
2026-01-12 11:02 ` Konrad Dybcio
2026-01-10 19:37 ` [PATCH 06/11] media: iris: don't specify ubwc_swizzle " Dmitry Baryshkov
2026-01-11 21:08 ` Bryan O'Donoghue
2026-01-12 11:03 ` Konrad Dybcio
2026-01-10 19:37 ` [PATCH 07/11] media: iris: don't specify bank_spreading " Dmitry Baryshkov
2026-01-11 21:09 ` Bryan O'Donoghue
2026-01-12 11:03 ` Konrad Dybcio
2026-01-10 19:38 ` [PATCH 08/11] media: iris: don't specify max_channels " Dmitry Baryshkov
2026-01-11 21:09 ` Bryan O'Donoghue
2026-01-12 11:05 ` Konrad Dybcio
2026-01-10 19:38 ` [PATCH 09/11] media: iris: drop remnants of UBWC configuration Dmitry Baryshkov
2026-01-11 21:10 ` Bryan O'Donoghue
2026-01-12 11:06 ` Konrad Dybcio
2026-01-10 19:38 ` [PATCH 10/11] drm/msm/mdss: use new helper to set min_acc length Dmitry Baryshkov
2026-01-12 11:08 ` Konrad Dybcio
2026-01-10 19:38 ` [PATCH 11/11] drm/msm/a6xx: " Dmitry Baryshkov
2026-01-12 11:07 ` Konrad Dybcio
2026-01-15 3:00 ` (subset) [PATCH 00/11] media: iris: migrate to using global UBWC config Bjorn Andersson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260110-iris-ubwc-v1-4-dd70494dcd7b@oss.qualcomm.com \
--to=dmitry.baryshkov@oss.qualcomm.com \
--cc=abhinav.kumar@linux.dev \
--cc=airlied@gmail.com \
--cc=akhilpo@oss.qualcomm.com \
--cc=andersson@kernel.org \
--cc=bod@kernel.org \
--cc=dikshita.agarwal@oss.qualcomm.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=freedreno@lists.freedesktop.org \
--cc=jesszhan0024@gmail.com \
--cc=konrad.dybcio@oss.qualcomm.com \
--cc=konradybcio@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=lumag@kernel.org \
--cc=marijn.suijten@somainline.org \
--cc=mchehab@kernel.org \
--cc=robin.clark@oss.qualcomm.com \
--cc=sean@poorly.run \
--cc=simona@ffwll.ch \
--cc=vikash.garodia@oss.qualcomm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®