* [PATCH] drm/amd/display: clarify average bandwidth comment in dcn4_calcs
@ 2026-04-26 19:18 Adriano Vero
0 siblings, 0 replies; only message in thread
From: Adriano Vero @ 2026-04-26 19:18 UTC (permalink / raw)
To: austin.zheng, jun.lei, harry.wentland, sunpeng.li
Cc: siqueira, alexander.deucher, christian.koenig, airlied, simona,
amd-gfx, dri-devel, linux-kernel, Adriano Vero
Replace a stale FIXME_DCN4 comment in calculate_avg_bandwidth_required()
that questioned whether cursor_bw and tdlut bandwidth should be included
in the average bandwidth calculation.
cursor_bw is already correctly included in all four accumulation
sites below the comment. tdlut bandwidth is intentionally absent
because tdlut data is fetched only during prefetch and blanking
intervals, not during active display, and therefore does not
contribute to active average bandwidth.
Also clarify the phantom pipe handling: phantom pipes are excluded
from sys_active average BW but included in svp_prefetch average BW,
which matches the existing code structure.
Signed-off-by: Adriano Vero <adri.vero.dev@gmail.com>
---
.../dml2_0/dml21/src/dml2_core/dml2_core_dcn4_calcs.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/display/dc/dml2_0/dml21/src/dml2_core/dml2_core_dcn4_calcs.c b/drivers/gpu/drm/amd/display/dc/dml2_0/dml21/src/dml2_core/dml2_core_dcn4_calcs.c
index ca5ac3c0d..34a2a8326 100644
--- a/drivers/gpu/drm/amd/display/dc/dml2_0/dml21/src/dml2_core/dml2_core_dcn4_calcs.c
+++ b/drivers/gpu/drm/amd/display/dc/dml2_0/dml21/src/dml2_core/dml2_core_dcn4_calcs.c
@@ -2845,8 +2845,14 @@ static void calculate_avg_bandwidth_required(
dram_overhead_factor_p0 = dcc_dram_bw_nom_overhead_factor_p0[k] * mall_prefetch_dram_overhead_factor[k];
dram_overhead_factor_p1 = dcc_dram_bw_nom_overhead_factor_p1[k] * mall_prefetch_dram_overhead_factor[k];
- // FIXME_DCN4, was missing cursor_bw in here, but do I actually need that and tdlut bw for average bandwidth calculation?
- // active avg bw not include phantom, but svp_prefetch avg bw should include phantom pipes
+ /*
+ * cursor_bw is included in the average bandwidth calculation below.
+ * tdlut bandwidth is intentionally excluded: tdlut data is fetched
+ * only during prefetch/blanking intervals and does not contribute
+ * to active average bandwidth.
+ * Phantom pipe contributions are excluded from sys_active but
+ * included in svp_prefetch average bandwidth.
+ */
if (!dml_is_phantom_pipe(&display_cfg->plane_descriptors[k])) {
avg_bandwidth_required[dml2_core_internal_soc_state_sys_active][dml2_core_internal_bw_sdp] += sdp_overhead_factor * (ReadBandwidthLuma[k] + ReadBandwidthChroma[k]) + cursor_bw[k];
avg_bandwidth_required[dml2_core_internal_soc_state_sys_active][dml2_core_internal_bw_dram] += dram_overhead_factor_p0 * ReadBandwidthLuma[k] + dram_overhead_factor_p1 * ReadBandwidthChroma[k] + cursor_bw[k];
--
2.53.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-04-26 19:19 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-26 19:18 [PATCH] drm/amd/display: clarify average bandwidth comment in dcn4_calcs Adriano Vero
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox