From: Bryan O'Donoghue <bod@kernel.org>
To: Wangao Wang <wangao.wang@oss.qualcomm.com>,
Vikash Garodia <vikash.garodia@oss.qualcomm.com>,
Dikshita Agarwal <dikshita.agarwal@oss.qualcomm.com>,
Abhinav Kumar <abhinav.kumar@linux.dev>,
Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: quic_qiweil@quicinc.com,
Renjiang Han <renjiang.han@oss.qualcomm.com>,
linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 1/2] media: qcom: iris: improve gop size support for gen1 encoder
Date: Tue, 30 Jun 2026 23:10:51 +0100 [thread overview]
Message-ID: <6963a75c-c6f1-4ed1-a514-75a0218a307c@kernel.org> (raw)
In-Reply-To: <20260624-dynamic_encode-v3-1-f2a2db0ac2af@oss.qualcomm.com>
On 24/06/2026 09:51, Wangao Wang wrote:
> The GOP_SIZE cap was missing an hfi_id, so it would not interact with the
> firmware but could still save the parameter passed by the client.
> INTRA_PERIOD was acting as GOP_SIZE here. The code was redundant, so the
> two caps have been merged.
Hmm, this really feels like a bug fix. Your first sentence describes a
software flaw, which you then remediate.
I'd like to see a better description of that - you appear to be saying
"but it doesn't matter anyway" - which is perhaps true but still to me
feels like you need to actively justify why this _shouldn't_ go back to
stable.
> Signed-off-by: Wangao Wang <wangao.wang@oss.qualcomm.com>
> ---
> drivers/media/platform/qcom/iris/iris_ctrls.c | 2 +-
> drivers/media/platform/qcom/iris/iris_hfi_gen1.c | 16 ++++------------
> drivers/media/platform/qcom/iris/iris_platform_common.h | 1 -
> 3 files changed, 5 insertions(+), 14 deletions(-)
>
> diff --git a/drivers/media/platform/qcom/iris/iris_ctrls.c b/drivers/media/platform/qcom/iris/iris_ctrls.c
> index 10e33b8a73f60759c4f1cb17b5c95897f0e1468f..391e1fc5f6e2ec8e9cf5ba4e0f76b2d1da3e2a35 100644
> --- a/drivers/media/platform/qcom/iris/iris_ctrls.c
> +++ b/drivers/media/platform/qcom/iris/iris_ctrls.c
> @@ -1293,7 +1293,7 @@ int iris_set_use_and_mark_ltr(struct iris_inst *inst, enum platform_inst_fw_cap_
> int iris_set_intra_period(struct iris_inst *inst, enum platform_inst_fw_cap_type cap_id)
> {
> const struct iris_hfi_session_ops *hfi_ops = inst->hfi_session_ops;
> - u32 gop_size = inst->fw_caps[GOP_SIZE].value;
> + u32 gop_size = inst->fw_caps[cap_id].value;
> u32 b_frame = inst->fw_caps[B_FRAME].value;
> u32 hfi_id = inst->fw_caps[cap_id].hfi_id;
> struct hfi_intra_period intra_period;
> diff --git a/drivers/media/platform/qcom/iris/iris_hfi_gen1.c b/drivers/media/platform/qcom/iris/iris_hfi_gen1.c
> index ca1545d28b5310d8c45a905287dcb69f6184d9cc..eff9216bb50143c0d752051a6400605bbaf3803e 100644
> --- a/drivers/media/platform/qcom/iris/iris_hfi_gen1.c
> +++ b/drivers/media/platform/qcom/iris/iris_hfi_gen1.c
> @@ -171,7 +171,9 @@ static const struct platform_inst_fw_cap inst_fw_cap_sm8250_enc[] = {
> .max = (1 << 16) - 1,
> .step_or_mask = 1,
> .value = 30,
> - .set = iris_set_u32
> + .hfi_id = HFI_PROPERTY_CONFIG_VENC_INTRA_PERIOD,
> + .flags = CAP_FLAG_OUTPUT_PORT,
> + .set = iris_set_intra_period,
> },
> {
> .cap_id = ENTROPY_MODE,
> @@ -240,7 +242,7 @@ static const struct platform_inst_fw_cap inst_fw_cap_sm8250_enc[] = {
> .step_or_mask = 1,
> .value = 0,
> .hfi_id = HFI_PROPERTY_PARAM_VENC_INTRA_REFRESH,
> - .flags = CAP_FLAG_OUTPUT_PORT,
> + .flags = CAP_FLAG_OUTPUT_PORT | CAP_FLAG_DYNAMIC_ALLOWED,
> .set = iris_set_ir_period_gen1,
> },
> {
> @@ -281,16 +283,6 @@ static const struct platform_inst_fw_cap inst_fw_cap_sm8250_enc[] = {
> .value = 0,
> .flags = CAP_FLAG_OUTPUT_PORT,
> },
> - {
> - .cap_id = INTRA_PERIOD,
> - .min = 0,
> - .max = 1,
> - .step_or_mask = 1,
> - .value = 0,
> - .hfi_id = HFI_PROPERTY_CONFIG_VENC_INTRA_PERIOD,
> - .flags = CAP_FLAG_OUTPUT_PORT,
> - .set = iris_set_intra_period,
> - },
> {
> .cap_id = LAYER_ENABLE,
> .min = 0,
> diff --git a/drivers/media/platform/qcom/iris/iris_platform_common.h b/drivers/media/platform/qcom/iris/iris_platform_common.h
> index c9256f2323dc4521f9eacaeffb0fc08a180de3ff..ff48333ad089894c3393e8ad45903c2603288eb9 100644
> --- a/drivers/media/platform/qcom/iris/iris_platform_common.h
> +++ b/drivers/media/platform/qcom/iris/iris_platform_common.h
> @@ -165,7 +165,6 @@ enum platform_inst_fw_cap_type {
> USE_LTR,
> MARK_LTR,
> B_FRAME,
> - INTRA_PERIOD,
> LAYER_ENABLE,
> LAYER_TYPE_H264,
> LAYER_TYPE_HEVC,
>
> --
> 2.43.0
>
>
next prev parent reply other threads:[~2026-06-30 22:10 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <Z3W2-J864HyF-sbnVW8bg7mP4rdQ-AGsEM_jIIXZEEzjrC0E2wQSfGS3CXZItedQtyxy_aMWtLQmg-iyFEcHpA==@protonmail.internalid>
2026-06-24 8:51 ` [PATCH v3 0/2] media: qcom: iris: add dynamic encoder properties Wangao Wang
2026-06-24 8:51 ` [PATCH v3 1/2] media: qcom: iris: improve gop size support for gen1 encoder Wangao Wang
2026-06-30 15:06 ` Vishnu Reddy
2026-06-30 22:10 ` Bryan O'Donoghue [this message]
2026-06-24 8:51 ` [PATCH v3 2/2] media: qcom: iris: Add request key frame support for encoder Wangao Wang
2026-06-30 15:10 ` Vishnu Reddy
2026-06-30 22:12 ` Bryan O'Donoghue
2026-06-30 22:07 ` [PATCH v3 0/2] media: qcom: iris: add dynamic encoder properties Bryan O'Donoghue
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=6963a75c-c6f1-4ed1-a514-75a0218a307c@kernel.org \
--to=bod@kernel.org \
--cc=abhinav.kumar@linux.dev \
--cc=dikshita.agarwal@oss.qualcomm.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=quic_qiweil@quicinc.com \
--cc=renjiang.han@oss.qualcomm.com \
--cc=vikash.garodia@oss.qualcomm.com \
--cc=wangao.wang@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