drm/amd/display: change kzalloc to kcalloc in dcn30_validate_bandwidth()We are trying to get rid of all multiplications from allocationfunctions to prevent integer overflows. Here the multiplicati
drm/amd/display: change kzalloc to kcalloc in dcn30_validate_bandwidth()We are trying to get rid of all multiplications from allocationfunctions to prevent integer overflows. Here the multiplication isprobably safe, but using kcalloc() is more appropriate and improvesreadability. This patch has no effect on runtime behavior.Reviewed-by: Rodrigo Siqueira <[email protected]>Reviewed-by: Alex Hung <[email protected]>Signed-off-by: Ethan Carter Edwards <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
show more ...
drm/amd/display: DML2.1 Post-Si Cleanup[Why]There are a few cleanup and refactoring tasks that need to be donewith the DML2.1 wrapper and DC interface to remove dependencies onlegacy structures
drm/amd/display: DML2.1 Post-Si Cleanup[Why]There are a few cleanup and refactoring tasks that need to be donewith the DML2.1 wrapper and DC interface to remove dependencies onlegacy structures and N-1 prototypes.[How]Implemented pipe_ctx->global_sync.Implemented new functions to use pipe_ctx->hubp_regs andpipe_ctx->global_sync:- hubp_setup2- hubp_setup_interdependent2- Several other new functions for DCN 4.01 to support newer structuresRemoved dml21_update_pipe_ctx_dchub_regsRemoved dml21_extract_legacy_watermark_setRemoved dml21_populate_pipe_ctx_dlg_paramRemoved outdated dcn references in DML2.1 wrapper.Reviewed-by: Austin Zheng <[email protected]>Reviewed-by: Dillon Varone <[email protected]>Signed-off-by: Rafal Ostrowski <[email protected]>Signed-off-by: Tom Chung <[email protected]>Tested-by: Daniel Wheeler <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Limit VTotal range to max hw cap minus fp[WHY & HOW]Hardware does not support the VTotal to be between fp2 lines of themaximum possible VTotal, so add a capability flag to track
drm/amd/display: Limit VTotal range to max hw cap minus fp[WHY & HOW]Hardware does not support the VTotal to be between fp2 lines of themaximum possible VTotal, so add a capability flag to track it and applywhere necessary.Cc: Mario Limonciello <[email protected]>Cc: Alex Deucher <[email protected]>Cc: [email protected]Reviewed-by: Jun Lei <[email protected]>Reviewed-by: Anthony Koo <[email protected]>Signed-off-by: Dillon Varone <[email protected]>Signed-off-by: Alex Hung <[email protected]>Tested-by: Daniel Wheeler <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Remove last parts of timing_traceCommit c2c2ce1e9623 ("drm/amd/display: Optimize passive update planes.")removed the last caller of context_timing_trace.Remove it.With that gon
drm/amd/display: Remove last parts of timing_traceCommit c2c2ce1e9623 ("drm/amd/display: Optimize passive update planes.")removed the last caller of context_timing_trace.Remove it.With that gone, no one is now looking at the 'timing_trace' flag, removeit and all the places that set it.Signed-off-by: Dr. David Alan Gilbert <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Add hpd_source index out-of-bounds check for dcn3x link encoder creationThis patch adds a boundary check for the hpd_source index during thelink encoder creation process for dcn3x
drm/amd/display: Add hpd_source index out-of-bounds check for dcn3x link encoder creationThis patch adds a boundary check for the hpd_source index during thelink encoder creation process for dcn3x IP's. The check ensures that theindex is within the valid range of the link_enc_hpd_regs array toprevent out-of-bounds access.Cc: Tom Chung <[email protected]>Cc: Rodrigo Siqueira <[email protected]>Cc: Roman Li <[email protected]>Cc: Alex Hung <[email protected]>Cc: Aurabindo Pillai <[email protected]>Cc: Harry Wentland <[email protected]>Cc: Hamza Mahfooz <[email protected]>Signed-off-by: Srinivasan Shanmugam <[email protected]>Reviewed-by: Roman Li <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Remove unreachable check[WHY]Coverity analysis flagged this code as DEADCODEsince the condition and return in the outer loopare never reached.All operations with the 'dwb_pipe
drm/amd/display: Remove unreachable check[WHY]Coverity analysis flagged this code as DEADCODEsince the condition and return in the outer loopare never reached.All operations with the 'dwb_pipe' variable happenin the inner loop, that already contains the samecheck with the 'MAX_DWB_PIPES'. The latercheck condition cannot occur before the checkcondition in the inner loop, thus the latercondition is unreacable.[HOW]Remove the unreachable condition.Acked-by: Zaeem Mohamed <[email protected]>Signed-off-by: Ivan Lipski <[email protected]>Tested-by: Daniel Wheeler <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Move fpo_in_use to stream_status[Description]Refactor code and move fpo_in_use into stream_status to avoidunexpected changes to previous dc_state (i.e., current_state).Since str
drm/amd/display: Move fpo_in_use to stream_status[Description]Refactor code and move fpo_in_use into stream_status to avoidunexpected changes to previous dc_state (i.e., current_state).Since stream pointers are shared between current and new dc_states,updating parameters of one stream will update the other as wellwhich causes unexpected behaviors (i.e., checking that fpo_in_useisn't set in previous state and set in the new state is invalid).To avoid incorrect updates to current_state, move the fpo_in_use flaginto dc_stream_status since stream_status is owned by dc and are notshared between different dc_states.Reviewed-by: Samson Tam <[email protected]>Acked-by: Zaeem Mohamed <[email protected]>Signed-off-by: Alvin Lee <[email protected]>Tested-by: Daniel Wheeler <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Restrict multi-disp support for in-game FAMS[HOW&WHY]In multi-monitor cases the VBLANK stretch that is required to align bothmonitors may be so large that it may create issues fo
drm/amd/display: Restrict multi-disp support for in-game FAMS[HOW&WHY]In multi-monitor cases the VBLANK stretch that is required to align bothmonitors may be so large that it may create issues for gaming performance.Use debug value to restrict in-game FAMS support for multi-disp use case.Reviewed-by: Harry Vanzylldejong <[email protected]>Acked-by: Wayne Lin <[email protected]>Signed-off-by: Iswara Nagulendran <[email protected]>Tested-by: Daniel Wheeler <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Update comments in DCThis commit adds, updates, and removes some of the comments used in theDC code.Signed-off-by: Rodrigo Siqueira <[email protected]>Acked-by: Aurabind
drm/amd/display: Update comments in DCThis commit adds, updates, and removes some of the comments used in theDC code.Signed-off-by: Rodrigo Siqueira <[email protected]>Acked-by: Aurabindo Pillai <[email protected]>Tested-by: Daniel Wheeler <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Add NULL pointer check for kzalloc[Why & How]Check return pointer of kzalloc before using it.Reviewed-by: Alex Hung <[email protected]>Acked-by: Wayne Lin <[email protected]>S
drm/amd/display: Add NULL pointer check for kzalloc[Why & How]Check return pointer of kzalloc before using it.Reviewed-by: Alex Hung <[email protected]>Acked-by: Wayne Lin <[email protected]>Signed-off-by: Hersen Wu <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Fix compiler warnings on high compiler warning levels[why]Enabling higher compiler warning levels results in many issues that canbe trivially resolved as well as some potentially
drm/amd/display: Fix compiler warnings on high compiler warning levels[why]Enabling higher compiler warning levels results in many issues that canbe trivially resolved as well as some potentially critical issues.[how]Fix all compiler warnings found with various compilers and higherwarning levels. Primarily, potentially uninitialized variables andunreachable code.Reviewed-by: Leo Li <[email protected]>Acked-by: Roman Li <[email protected]>Signed-off-by: Aric Cyr <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Ensure populate uclk in bb construction[Description]- For some SKUs, the optimal DCFCLK for each UCLK is less than the smallest DCFCLK STA target due to low memory bandwidth. Th
drm/amd/display: Ensure populate uclk in bb construction[Description]- For some SKUs, the optimal DCFCLK for each UCLK is less than the smallest DCFCLK STA target due to low memory bandwidth. There is an assumption that the DCFCLK STA targets will always be less than one of the optimal DCFCLK values, but this is not true for SKUs that have low memory bandwidth. In this case we need to populate the optimal UCLK for each DCFCLK STA targets as the max UCLK freq.- Also fix a bug in DML where start_state is not assigned and used correctly.Reviewed-by: Samson Tam <[email protected]>Reviewed-by: Chaitanya Dhere <[email protected]>Acked-by: Alex Hung <[email protected]>Signed-off-by: Alvin Lee <[email protected]>Tested-by: Daniel Wheeler <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Optimize fast validation casesOptimize fast validation cases to only validate the highest voltagelevel. This works because during fast validation we only care if themode can be s
drm/amd/display: Optimize fast validation casesOptimize fast validation cases to only validate the highest voltagelevel. This works because during fast validation we only care if themode can be supported or not (at any vlevel).Tested-by: Daniel Wheeler <[email protected]>Reviewed-by: Aric Cyr <[email protected]>Acked-by: Rodrigo Siqueira <[email protected]>Signed-off-by: Alvin Lee <[email protected]>Signed-off-by: Alex Deucher <[email protected]>
drm/amd/display: Refactor resource into component directory[WHY]Move all resource files to unique folder resource.[HOW]Created resource folder in dc, moved thedcnxx_resource.c and dcnxx_resour
drm/amd/display: Refactor resource into component directory[WHY]Move all resource files to unique folder resource.[HOW]Created resource folder in dc, moved thedcnxx_resource.c and dcnxx_resource.h files intocorresponding new folders inside the resource andmade appropriate changes for compilation in Makefiles.Reviewed-by: Martin Leung <[email protected]>Acked-by: Alex Hung <[email protected]>Signed-off-by: Mounika Adhuri <[email protected]>Tested-by: Daniel Wheeler <[email protected]>Signed-off-by: Alex Deucher <[email protected]>