Re: [PATCH] drm/amd/display: fix array index out of bound error in DCN32 DML

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





On 12/5/22 16:08, Aurabindo Pillai wrote:
[Why&How]
LinkCapacitySupport array is indexed with the number of voltage states and
not the number of max DPPs. Fix the error by changing the array
declaration to use the correct (larger) array size of total number of
voltage states.

Signed-off-by: Aurabindo Pillai <aurabindo.pillai@xxxxxxx>
---
  drivers/gpu/drm/amd/display/dc/dml/display_mode_vba.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/display/dc/dml/display_mode_vba.h b/drivers/gpu/drm/amd/display/dc/dml/display_mode_vba.h
index d46aa4817e70..8a67f4d65d82 100644
--- a/drivers/gpu/drm/amd/display/dc/dml/display_mode_vba.h
+++ b/drivers/gpu/drm/amd/display/dc/dml/display_mode_vba.h
@@ -1162,7 +1162,7 @@ struct vba_vars_st {
  	double UrgBurstFactorLumaPre[DC__NUM_DPP__MAX];
  	double UrgBurstFactorChromaPre[DC__NUM_DPP__MAX];
  	bool NotUrgentLatencyHidingPre[DC__NUM_DPP__MAX];
-	bool LinkCapacitySupport[DC__NUM_DPP__MAX];
+	bool LinkCapacitySupport[DC__VOLTAGE_STATES];
  	bool VREADY_AT_OR_AFTER_VSYNC[DC__NUM_DPP__MAX];
  	unsigned int MIN_DST_Y_NEXT_START[DC__NUM_DPP__MAX];
  	unsigned int VFrontPorch[DC__NUM_DPP__MAX];

Reviewed-by: Rodrigo Siqueira <Rodrigo.Siqueira@xxxxxxx>



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux