From: sashiko-bot@kernel.org
To: "AngeloGioacchino Del Regno" <angelogioacchino.delregno@collabora.com>
Cc: conor+dt@kernel.org, dri-devel@lists.freedesktop.org,
devicetree@vger.kernel.org, robh@kernel.org
Subject: Re: [PATCH v8 10/13] drm/mediatek: mtk_dsi: Add support for MT8196
Date: Tue, 15 Sep 2026 08:57:05 +0000 [thread overview]
Message-ID: <20260915085706.4C0451F00893@smtp.kernel.org> (raw)
In-Reply-To: <20260915084148.11385-11-angelogioacchino.delregno@collabora.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] drm/mediatek: Incomplete initialization of DSI QoS parameters (missing PREURGENT)
--
commit 2eeb791791ca07e53d5c59d273b7795e846f2238
Author: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
drm/mediatek: mtk_dsi: Add support for MT8196
Add support for the new DSI IP found in the Kompanio Ultra MT8196
SoC and its Dimensity and Genio variants.
Differently from the older DSI IPs, the one from MT8196 requires
the initialization of all of the QoS parameters and can make use
of a DSI SRAM reserved buffer (present also on older SoCs but not
mandatory on those).
> diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c b/drivers/gpu/drm/mediatek/mtk_dsi.c
> index 16bf08bee38e3..6f176515e2587 100644
> --- a/drivers/gpu/drm/mediatek/mtk_dsi.c
> +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c
[ ... ]
> @@ -373,6 +373,59 @@ static const u16 mtk_dsi_regs_mt8186[DSI_ADV_REG_MAX] = {
> [DSI_CMDQ] = 0xd00,
> };
>
> +static const u16 mtk_dsi_regs_main_v2[DSI_MAIN_REG_MAX] = {
[ ... ]
> +static const u16 mtk_dsi_regs_qos_v2[DSI_QOS_REG_MAX] = {
> + [DSI_QOS_BUF_CON0] = 0x300,
> + [DSI_QOS_BUF_CON1] = 0x304,
> + [DSI_QOS_TX_BUF_RW_TIMES] = 0x310,
> + [DSI_QOS_SODI_HIGH] = 0x314,
> + [DSI_QOS_SODI_LOW] = 0x318,
> + [DSI_QOS_PREULTRA_HIGH] = 0x324,
> + [DSI_QOS_PREULTRA_LOW] = 0x328,
> + [DSI_QOS_ULTRA_HIGH] = 0x32c,
> + [DSI_QOS_ULTRA_LOW] = 0x330,
> + [DSI_QOS_URGENT_HIGH] = 0x334,
> + [DSI_QOS_URGENT_LOW] = 0x338,
> + [DSI_QOS_PREURGENT_HIGH] = 0x33c
> +};
[Severity: Medium]
Is the DSI_QOS_PREURGENT_LOW mapping missing from this array?
The array maps DSI_QOS_PREURGENT_HIGH but completely omits a mapping or enum
definition for DSI_QOS_PREURGENT_LOW.
Additionally, the commit message explicitly states that the MT8196 IP requires
the initialization of all of the QoS parameters, but it appears PREURGENT
is skipped entirely.
When the DSI driver probes on SoCs using the new HW buffers and calls
mtk_dsi_config_hw_buffers(), it programs all other QoS thresholds (SODI,
PREULTRA, ULTRA, URGENT) but omits PREURGENT:
drivers/gpu/drm/mediatek/mtk_dsi.c:mtk_dsi_config_hw_buffers() {
...
/* Write all QoS parameters: Screen On Deep Idle, (pre)Ultra, Urgent, RW times */
mtk_dsi_mask(dsi, reg_qos[DSI_QOS_SODI_HIGH], BUF_THRESHOLD_PARAM, sodi_hi);
mtk_dsi_mask(dsi, reg_qos[DSI_QOS_SODI_LOW], BUF_THRESHOLD_PARAM, sodi_lo);
mtk_dsi_mask(dsi, reg_qos[DSI_QOS_PREULTRA_HIGH], BUF_THRESHOLD_PARAM, preultra_hi);
mtk_dsi_mask(dsi, reg_qos[DSI_QOS_PREULTRA_LOW], BUF_THRESHOLD_PARAM, preultra_lo);
mtk_dsi_mask(dsi, reg_qos[DSI_QOS_ULTRA_HIGH], BUF_THRESHOLD_PARAM, ultra_hi);
mtk_dsi_mask(dsi, reg_qos[DSI_QOS_ULTRA_LOW], BUF_THRESHOLD_PARAM, ultra_lo);
mtk_dsi_mask(dsi, reg_qos[DSI_QOS_URGENT_HIGH], BUF_THRESHOLD_PARAM, urgent_hi);
mtk_dsi_mask(dsi, reg_qos[DSI_QOS_URGENT_LOW], BUF_THRESHOLD_PARAM, urgent_lo);
writel(rw_times, dsi->regs + reg_qos[DSI_QOS_TX_BUF_RW_TIMES]);
...
}
Could omitting this parameter lead to suboptimal DSI FIFO scheduling, display
artifacts, or underflows, since the hardware configuration is left incomplete?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260915084148.11385-1-angelogioacchino.delregno@collabora.com?part=10
next prev parent reply other threads:[~2026-09-15 8:57 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-15 8:41 [PATCH v8 00/13] drm/mediatek: Add DSC, WDMA, MT8189/96 DSI support AngeloGioacchino Del Regno
2026-09-15 8:41 ` [PATCH v8 01/13] dt-bindings: display: mediatek: dsc: Add MT8196 compatible AngeloGioacchino Del Regno
2026-09-15 8:41 ` [PATCH v8 02/13] drm/mediatek: Implement Display Stream Compression support AngeloGioacchino Del Regno
2026-09-15 8:58 ` sashiko-bot
2026-09-15 13:37 ` Nikolai Burov
2026-09-15 13:55 ` Nikolai Burov
2026-09-15 15:05 ` AngeloGioacchino Del Regno
2026-09-15 18:51 ` Nikolai Burov
2026-09-16 10:57 ` AngeloGioacchino Del Regno
2026-09-19 10:07 ` Nikolai Burov
2026-09-15 8:41 ` [PATCH v8 03/13] dt-bindings: display: mediatek: dsi: Document MT8189 and MT8196 AngeloGioacchino Del Regno
2026-09-15 8:41 ` [PATCH v8 04/13] drm/mediatek: mtk_dsi: Cleanup encoder if reset fails during bind AngeloGioacchino Del Regno
2026-09-15 8:41 ` [PATCH v8 05/13] drm/mediatek: mtk_dsi: Enable interrupt at component bind time AngeloGioacchino Del Regno
2026-09-15 8:41 ` [PATCH v8 06/13] drm/mediatek: mtk_dsi: Transfer register offsets to per-SoC const AngeloGioacchino Del Regno
2026-09-15 8:41 ` [PATCH v8 07/13] drm/mediatek: mtk_dsi: Move max link rate parameter to platform data AngeloGioacchino Del Regno
2026-09-15 8:41 ` [PATCH v8 08/13] drm/mediatek: mtk_dsi: Add support for MT8189 AngeloGioacchino Del Regno
2026-09-15 8:41 ` [PATCH v8 09/13] drm/mediatek: mtk_dsi: Add support for SRAM QoS setting AngeloGioacchino Del Regno
2026-09-15 8:54 ` sashiko-bot
2026-09-15 8:41 ` [PATCH v8 10/13] drm/mediatek: mtk_dsi: Add support for MT8196 AngeloGioacchino Del Regno
2026-09-15 8:57 ` sashiko-bot [this message]
2026-09-15 8:41 ` [PATCH v8 11/13] drm/mediatek: mtk_dsi: Enable PM Runtime on probe AngeloGioacchino Del Regno
2026-09-15 9:10 ` sashiko-bot
2026-09-15 8:41 ` [PATCH v8 12/13] dt-bindings: display: mediatek: wdma: Add compatibles for more SoCs AngeloGioacchino Del Regno
2026-09-15 8:57 ` sashiko-bot
2026-09-15 8:41 ` [PATCH v8 13/13] drm/mediatek: Add Write DMA (WDMA) Engine for Writeback support AngeloGioacchino Del Regno
2026-09-15 8:59 ` sashiko-bot
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=20260915085706.4C0451F00893@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=angelogioacchino.delregno@collabora.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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;
as well as URLs for NNTP newsgroup(s).