diff options
| author | Nathan Chancellor <[email protected]> | 2022-08-30 20:34:05 +0000 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2022-09-13 18:33:00 +0000 |
| commit | 1df7e569522486e58307929a726ec8f303c5abf4 (patch) | |
| tree | f8b7785364d03f295adbb0cd1a732c58f5316597 /drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | |
| parent | drm/amd/display: 3.2.202 (diff) | |
| download | kernel-1df7e569522486e58307929a726ec8f303c5abf4.tar.gz kernel-1df7e569522486e58307929a726ec8f303c5abf4.zip | |
drm/amd/display: Reduce number of arguments of dml32_CalculateWatermarksMALLUseAndDRAMSpeedChangeSupport()
Most of the arguments are identical between the two call sites and they
can be accessed through the 'struct vba_vars_st' pointer created at the
top of dml32_ModeSupportAndSystemConfigurationFull(). This reduces the
total amount of stack space that
dml32_ModeSupportAndSystemConfigurationFull() uses by 216 bytes with
LLVM 16 (2152 -> 1936), helping clear up the following clang warning:
drivers/gpu/drm/amd/amdgpu/../display/dc/dml/dcn32/display_mode_vba_32.c:1721:6: error: stack frame size (2152) exceeds limit (2048) in 'dml32_ModeSupportAndSystemConfigurationFull' [-Werror,-Wframe-larger-than]
void dml32_ModeSupportAndSystemConfigurationFull(struct display_mode_lib *mode_lib)
^
1 error generated.
Additionally, while modifying the arguments to
dml32_CalculateWatermarksMALLUseAndDRAMSpeedChangeSupport(), use 'v'
consistently, instead of 'v' mixed with 'mode_lib->vba'.
Link: https://github.com/ClangBuiltLinux/linux/issues/1681
Reported-by: "Sudip Mukherjee (Codethink)" <[email protected]>
Tested-by: MaĆra Canal <[email protected]>
Reviewed-by: Rodrigo Siqueira <[email protected]>
Signed-off-by: Nathan Chancellor <[email protected]>
Signed-off-by: Rodrigo Siqueira <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c')
0 files changed, 0 insertions, 0 deletions
