RE: [PATCH] drm/amdgpu: Remove duplicate check for *is_queue_unmap in sdma_v7_0_ring_set_wptr

2024-05-16 Thread Kamal, Asad
[AMD Official Use Only - AMD Internal Distribution Only] Reviewed-by: Asad Kamal Thanks & Regards Asad -Original Message- From: amd-gfx On Behalf Of Gao, Likun Sent: Friday, May 17, 2024 9:32 AM To: SHANMUGAM, SRINIVASAN ; Koenig, Christian ; Deucher, Alexander Cc:

RE: [PATCH v5 10/10] Documentation/amdgpu: Add PM policy documentation

2024-05-16 Thread Kamal, Asad
[AMD Official Use Only - AMD Internal Distribution Only] Series is Reviewed-by: Asad Kamal mailto:asad.ka...@amd.com>> Thanks & Regards Asad From: Deucher, Alexander Sent: Friday, May 17, 2024 12:57 AM To: Lazar, Lijo ; amd-gfx@lists.freedesktop.org Cc: Zhang, Hawking ; Kamal, Asad ; Ma,

RE: [PATCH] drm/amdgpu: Remove duplicate check for *is_queue_unmap in sdma_v7_0_ring_set_wptr

2024-05-16 Thread Gao, Likun
[AMD Official Use Only - AMD Internal Distribution Only] This patch was Reviewed-by: Likun Gao . Regards, Likun -Original Message- From: SHANMUGAM, SRINIVASAN Sent: Friday, May 17, 2024 11:33 AM To: Koenig, Christian ; Deucher, Alexander Cc: amd-gfx@lists.freedesktop.org; SHANMUGAM,

[PATCH 3/3] drm/amdgpu: fix ACA no query result after gpu reset

2024-05-16 Thread Yang Wang
fix ACA no query result after gpu reset. Signed-off-by: Yang Wang --- drivers/gpu/drm/amd/amdgpu/amdgpu_aca.c | 7 --- drivers/gpu/drm/amd/amdgpu/amdgpu_aca.h | 1 - drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 9 - 3 files changed, 4 insertions(+), 13 deletions(-) diff --git

[PATCH 2/3] drm/amdgpu: change bank cache lock type to spinlock

2024-05-16 Thread Yang Wang
modify the lock type to 'spinlock' to avoid schedule issue in interrupt context. Signed-off-by: Yang Wang --- drivers/gpu/drm/amd/amdgpu/amdgpu_mca.c | 11 +-- drivers/gpu/drm/amd/amdgpu/amdgpu_mca.h | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git

[PATCH 1/3] drm/amdgpu: change aca bank error lock type to spinlock

2024-05-16 Thread Yang Wang
modify the lock type to 'spinlock' to avoid schedule issue in interrupt context. Signed-off-by: Yang Wang --- drivers/gpu/drm/amd/amdgpu/amdgpu_aca.c | 19 +-- drivers/gpu/drm/amd/amdgpu/amdgpu_aca.h | 3 ++- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git

[PATCH] drm/amdgpu: Remove duplicate check for *is_queue_unmap in sdma_v7_0_ring_set_wptr

2024-05-16 Thread Srinivasan Shanmugam
This commit removes a duplicate check for *is_queue_unmap in the sdma_v7_0_ring_set_wptr function. The check at line 171 was considered dead code because at this point in the code, we already know that *is_queue_unmap is false due to the check at line 161. By removing this unnecessary check,

Re: [PATCH] drm/amdgpu: Remove GC HW IP 9.3.0 from noretry=1

2024-05-16 Thread Alex Deucher
Applied. Thanks! Alex On Thu, May 16, 2024 at 3:46 PM Tim Van Patten wrote: > > From: Tim Van Patten > > The following commit updated gmc->noretry from 0 to 1 for GC HW IP > 9.3.0: > > commit 5f3854f1f4e2 ("drm/amdgpu: add more cases to noretry=1") > > This causes the device to hang when

[PATCH] drm/amdgpu: Remove duplicate amdgpu_umsch_mm.h header

2024-05-16 Thread Jiapeng Chong
./drivers/gpu/drm/amd/amdgpu/amdgpu.h: amdgpu_umsch_mm.h is included more than once. Reported-by: Abaci Robot Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=9063 Signed-off-by: Jiapeng Chong --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 - 1 file changed, 1 deletion(-) diff --git

Re: [PATCH 1/3] drm/amdgpu: Add amdgpu_bo_is_vm_bo helper

2024-05-16 Thread Tvrtko Ursulin
Hi Christian, On 08/05/2024 09:26, Tvrtko Ursulin wrote: On 08/05/2024 06:42, Christian König wrote: Am 06.05.24 um 18:26 schrieb Tvrtko Ursulin: On 03/05/2024 10:14, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Help code readability by replacing a bunch of: bo->tbo.base.resv ==

[PATCH] drm/amdgpu: Remove GC HW IP 9.3.0 from noretry=1

2024-05-16 Thread Tim Van Patten
From: Tim Van Patten The following commit updated gmc->noretry from 0 to 1 for GC HW IP 9.3.0: commit 5f3854f1f4e2 ("drm/amdgpu: add more cases to noretry=1") This causes the device to hang when a page fault occurs, until the device is rebooted. Instead, revert back to gmc->noretry=0 so

Re: [PATCH 23/24] drm/amd/display: Fix POWERPC_64 compilation

2024-05-16 Thread Aurabindo Pillai
Reviewed-by: Aurabindo Pillai On 5/16/24 3:26 PM, roman...@amd.com wrote: From: Roman Li [Why] Compilation errors while compiling without CONFIG_DRM_AMD_DC_FP: "undefined reference to `dc_bandwidth_in_kbps_from_timing'" [How] Fix Makefile to move dsc files out of DC_FP guard. Fixes:

[PATCH 23/24] drm/amd/display: Fix POWERPC_64 compilation

2024-05-16 Thread Roman.Li
From: Roman Li [Why] Compilation errors while compiling without CONFIG_DRM_AMD_DC_FP: "undefined reference to `dc_bandwidth_in_kbps_from_timing'" [How] Fix Makefile to move dsc files out of DC_FP guard. Fixes: 50253f5d9ff4 ("drm/amd/display: Add misc DC changes for DCN401") Signed-off-by:

[PATCH 24/24] drm/amd/display: 3.2.286

2024-05-16 Thread Roman.Li
From: Aric Cyr This version pairs with DMUB FW Release 0.0.218.0 for dcn314/315/316, dcn35/351, dcn401 and brings along the following: - Fix powerpc compilation - Fix TBT+TypeC Daisy-chain lightup - Fix ODM combine setup - Fix OTC underflow on dcn35 - Fix DVI config for dcn401 - Add ips status

[PATCH 19/24] drm/amd/display: Fix ODM + underscan case with cursor

2024-05-16 Thread Roman.Li
From: Alvin Lee [Description] There is a corner case where we're in an ODM config that has recout.x != 0. In these scenarios we have to take into account the extra offset in the ODM adjustment for cursor. Reviewed-by: Aric Cyr Acked-by: Roman Li Signed-off-by: Alvin Lee ---

[PATCH 14/24] drm/amd/display: Clear shared dmub firmware state on init

2024-05-16 Thread Roman.Li
From: Roman Li [Why] Reset the shared dmub firmware region on dmub hw init to start with known state. [How] Memset the shared region to 0 in dmub_hw_init(). Suggested-by: Nicholas Kazlauskas Reviewed-by: Nicholas Kazlauskas Signed-off-by: Roman Li ---

[PATCH 18/24] drm/amd/display: fix a typo which causes an incorrect ODM combine setup

2024-05-16 Thread Roman.Li
From: Wenjing Liu [why] A recent change for ODM combine refactor contains a typo which causes ODM combine mode programmed incorrectly. Reviewed-by: George Shen Acked-by: Roman Li Signed-off-by: Wenjing Liu --- drivers/gpu/drm/amd/display/dc/hwss/dcn20/dcn20_hwseq.c | 2 +- 1 file changed, 1

[PATCH 03/24] drm/amd/display: Add missing enable and disable symclk_se functions for dcn401

2024-05-16 Thread Roman.Li
From: Wenjing Liu The functions are missing. These two functions are required to support MST. Reviewed-by: Rodrigo Siqueira Signed-off-by: Wenjing Liu --- .../amd/display/dc/dccg/dcn401/dcn401_dccg.c | 159 ++ .../amd/display/dc/dccg/dcn401/dcn401_dccg.h | 12 ++

[PATCH 17/24] drm/amd/display: Remove redundant idle optimization check

2024-05-16 Thread Roman.Li
From: Roman Li [Why] Disable idle optimization for each atomic commit is unnecessary, and can lead to a potential race condition. [How] Remove idle optimization check from amdgpu_dm_atomic_commit_tail() Fixes: 196107eb1e15 ("drm/amd/display: Add IPS checks before dcn register access") Cc:

[PATCH 22/24] drm/amd/display: Not fallback if link BW is smaller than req BW

2024-05-16 Thread Roman.Li
From: Cruise [Why] When the link BW is smaller than the request BW, the DP LT just kept running and fallback to lower link config. DP LT just aborted if is_hpd_pending bit is high. But is_hpd_pending bit indicates a new HPD event received. It doesn't mean the HPD is low. [How] Abort the DP LT

[PATCH 21/24] drm/amd/display: Correct display clocks update block sequence

2024-05-16 Thread Roman.Li
From: Dillon Varone [WHY] At the time of block sequence construction, the exact reference DPP/DISP clock is not yet known, so the clock should be passed by reference to the DTO programming function. Reviewed-by: Alvin Lee Acked-by: Roman Li Signed-off-by: Dillon Varone ---

[PATCH 15/24] drm/amd/display: Add ips status info to debugfs

2024-05-16 Thread Roman.Li
From: Roman Li [Why] For debugging and testing purposes. [How] If IPS is supported create ips_status debugfs entry. Usage: cat /sys/kernel/debug/dri/0/amdgpu_dm_ips_status Reviewed-by: Jerry Zuo Acked-by: Roman Li Signed-off-by: Roman Li --- .../amd/display/amdgpu_dm/amdgpu_dm_debugfs.c |

[PATCH 13/24] drm/amd/display: Add 3DLUT DMA load trigger

2024-05-16 Thread Roman.Li
From: Ilya Bakoulin [Why/How] Need to be able to trigger a DMA load to update 3DLUT contents in MPC. Adding a HWSS function to serve as the trigger. Reviewed-by: Krunoslav Kovac Acked-by: Roman Li Signed-off-by: Ilya Bakoulin --- drivers/gpu/drm/amd/display/dc/core/dc.c| 8

[PATCH 20/24] drm/amd/display: Disable DCN401 idle optimizations

2024-05-16 Thread Roman.Li
From: Dillon Varone [WHY] Disable to improve stability for now. Reviewed-by: Alvin Lee Acked-by: Roman Li Signed-off-by: Dillon Varone --- drivers/gpu/drm/amd/display/dc/resource/dcn401/dcn401_resource.c | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCH 16/24] drm/amd/display: Fix pipe addition logic in calc_blocks_to_ungate DCN35

2024-05-16 Thread Roman.Li
From: Nicholas Susanto [Why] Missing check for when there is new pipe configuration but both cur_pipe and new_pipe are both populated causing update_state of DSC for that instance not being updated correctly. This causes some display mode changes to cause underflow since DSCCLK is still gated

[PATCH 09/24] drm/amd/display: Modify HPO pixel clock programming to support DPM

2024-05-16 Thread Roman.Li
From: Dillon Varone Need to select DTBCLK and DPREFCLK as DTBCLK_p source according to hardware guidance. Reviewed-by: Rodrigo Siqueira Signed-off-by: Dillon Varone --- drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff

[PATCH 11/24] drm/amd/display: Add NULL check within get_target_mpc_factor

2024-05-16 Thread Roman.Li
From: Hersen Wu [Why] Coverity reports NULL_RETURN warning. [How] Add pointer NULL check. Reviewed-by: Rodrigo Siqueira Signed-off-by: Hersen Wu --- .../gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c | 9 + 1 file changed, 9 insertions(+) diff --git

[PATCH 12/24] drm/amd/display: Deallocate DML 2.1 Memory Allocation

2024-05-16 Thread Roman.Li
From: Chris Park [Why] DML 2.1 allocates two types of memory in its ctx structure but does not destroy them, causing memory leak whenever DML 2.1 instance is created and destroyed. [How] Deallocate two instances of allocated memory whenever DML 2.1 is destroyed. Reviewed-by: Rodrigo Siqueira

[PATCH 10/24] drm/amd/display: Add missing DML2 var helpers

2024-05-16 Thread Roman.Li
From: Rodrigo Siqueira Signed-off-by: Rodrigo Siqueira --- drivers/gpu/drm/amd/display/dc/dml2/display_mode_core.c | 2 ++ drivers/gpu/drm/amd/display/dc/dml2/display_mode_core.h | 2 ++ 2 files changed, 4 insertions(+) diff --git a/drivers/gpu/drm/amd/display/dc/dml2/display_mode_core.c

[PATCH 05/24] drm/amd/display: Use the correct TMDS function to avoid DVI issues

2024-05-16 Thread Roman.Li
From: Chris Park [Why] DVI is TMDS signal like HDMI but without audio. Current signal check does not correctly reflect DVI clock programming. [How] Define a new signal check for TMDS that includes DVI to HDMI TMDS programming. Reviewed-by: Rodrigo Siqueira Signed-off-by: Chris Park ---

[PATCH 07/24] drm/amd/display: enable EASF support for DCN40

2024-05-16 Thread Roman.Li
From: Samson Tam [Why] Enable adaptive scaler support for DCN401 [How] - Enable build flag for SPL - Set prefer_easf flag to true - Apply light linear scaling policy based on transfer function and pixel format. Choose between linear or non-linear scaling - Set matrix_mode based on pixel

[PATCH 08/24] drm/amd/display: Refactor HUBBUB into component folder for DCN401

2024-05-16 Thread Roman.Li
From: "Revalla, Harikrishna" [why] Cleaning up the code refactor requires hubbub to be in its own component. [how] Move all DCN401 files under newly created hubbub folder and fixing the makefiles. Reviewed-by: Rodrigo Siqueira Signed-off-by: Harikrishna Revalla ---

[PATCH 06/24] drm/amd/display: Adjust incorrect indentations and spaces

2024-05-16 Thread Roman.Li
From: Alex Hung This fixes indentations and adjust spaces for better readability and code styles. Reviewed-by: Rodrigo Siqueira Signed-off-by: Alex Hung --- drivers/gpu/drm/amd/display/dc/clk_mgr/Makefile | 1 - .../amd/display/dc/clk_mgr/dcn401/dcn401_clk_mgr.c | 1 -

[PATCH 02/24] drm/amd/display: Remove duplicate configuration

2024-05-16 Thread Roman.Li
From: Rodrigo Siqueira The function that commits planes calls the same set of functions twice, and in the case of the FAMs utilization, it is not desired to call the dmub, hwss_build and hwss_execute. This commit just removes the unnecessary calls to those functions. Acked-by: Roman Li

[PATCH 04/24] drm/amd/display: Fix incorrect DCN401 comparison

2024-05-16 Thread Roman.Li
From: Alex Hung The comparisons intend to be DCN401 inclusive, and fix it by adding equal signs. Reviewed-by: Rodrigo Siqueira Signed-off-by: Alex Hung --- drivers/gpu/drm/amd/display/dc/core/dc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[PATCH 01/24] drm/amd/display: Move DSC functions from dc.c to dc_dsc.c

2024-05-16 Thread Roman.Li
From: George Shen Move dsc functions from dc.c to dc_dsc.c. Co-Developed-by: George Shen Signed-off-by: Wenjing Liu Reviewed-by: Rodrigo Siqueira --- drivers/gpu/drm/amd/display/dc/core/dc.c| 99 - drivers/gpu/drm/amd/display/dc/dsc/dc_dsc.c | 96

[PATCH 00/24] DC Patches May 16, 2024

2024-05-16 Thread Roman.Li
From: Roman Li This DC patchset brings improvements in multiple areas. In summary, we have: - Fix powerpc compilation - Fix TBT+TypeC Daisy-chain lightup - Fix underflow on dcn35 - Fix DVI for dcn401 - Add 3DLUT DMA load trigger - Modify clock programming to support DPM

Re: [PATCH v5 10/10] Documentation/amdgpu: Add PM policy documentation

2024-05-16 Thread Deucher, Alexander
[AMD Official Use Only - AMD Internal Distribution Only] I didn't have time to go through every patch in detail, but overall it looks good to me. The series is: Acked-by: Alex Deucher From: Lazar, Lijo Sent: Thursday, May 16, 2024 8:43 AM To:

Re: [RFC v2 0/2] Discussion around eviction improvements

2024-05-16 Thread Alex Deucher
On Thu, May 16, 2024 at 8:18 AM Tvrtko Ursulin wrote: > > From: Tvrtko Ursulin > > Reduced re-spin of my previous series after Christian corrected a few > misconceptions that I had. So lets see if what remains makes sense or is still > misguided. > > To summarise, the series address the

Re: [PATCH] drm/amdgpu/vcn: update vcn5 enc/dec capabilities

2024-05-16 Thread Alex Deucher
On Wed, May 15, 2024 at 3:57 PM Ruijing Dong wrote: > > Update the capabilities for supporting 8k encoding/decoding. > > Signed-off-by: Ruijing Dong Acked-by: Alex Deucher > --- > drivers/gpu/drm/amd/amdgpu/soc24.c | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff

[PATCH] drm/amd/pm: support mode1 reset on smu v14.0.3

2024-05-16 Thread Alex Deucher
From: Kenneth Feng Align with new port same as smu 13.x. Signed-off-by: Kenneth Feng Reviewed-by: Jack Gui Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/pm/swsmu/smu14/smu_v14_0_2_ppt.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git

[PATCH] drm/amdgpu: Adjust logic in amdgpu_device_partner_bandwidth()

2024-05-16 Thread Alex Deucher
Use current speed/width on devices which don't support dynamic PCIe switching. Closes: https://gitlab.freedesktop.org/drm/amd/-/issues/3289 Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 19 --- 1 file changed, 12 insertions(+), 7 deletions(-) diff

Re: [PATCH] drm/amdgpu: fix Kconfig for ISP v2

2024-05-16 Thread Limonciello, Mario
On 5/14/2024 4:28 PM, Alex Deucher wrote: Add new config option and set proper dependencies for ISP. v2: add missed guards, drop separate Kconfig Signed-off-by: Alex Deucher I have one optional remark regarding headers, but otherwise it looks fine by me. Feel free to ignore it or

Re: [PATCH] drm/amdgpu: Remove duplicate amdgpu_umsch_mm.h header

2024-05-16 Thread Alex Deucher
Applied. Thanks! On Thu, May 16, 2024 at 4:47 AM Jiapeng Chong wrote: > > ./drivers/gpu/drm/amd/amdgpu/amdgpu.h: amdgpu_umsch_mm.h is included more > than once. > > Reported-by: Abaci Robot > Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=9063 > Signed-off-by: Jiapeng Chong > --- >

Re: [PATCH] drm/amdgpu/vcn: update vcn5 enc/dec capabilities

2024-05-16 Thread David Wu
Reviewed-by: David (Ming Qiang) Wu On 2024-05-15 15:19, Ruijing Dong wrote: Update the capabilities for supporting 8k encoding/decoding. Signed-off-by: Ruijing Dong --- drivers/gpu/drm/amd/amdgpu/soc24.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git

Re: [PATCH] drm/radeon: initialize atom DIG backlight for iMac12, 1 and iMac12, 2 with Radeon 6750M

2024-05-16 Thread Alex Deucher
Applied. Thanks! Alex On Wed, May 15, 2024 at 5:47 PM Kendall Smith wrote: > > If a Radeon 6750M GPU from an iMac12,1 is installed into an iMac 12,2, there > is no backlight device initialized during boot. Everything else is > functional, but the display brightness cannot be controlled.

[PATCH] drm/amdgpu: silence UBSAN warning

2024-05-16 Thread Alex Deucher
Convert a variable sized array from [1] to []. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/include/atomfirmware.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/include/atomfirmware.h b/drivers/gpu/drm/amd/include/atomfirmware.h index

[PATCH v5 07/10] drm/amd/pm: Add xgmi plpd to arcturus pm_policy

2024-05-16 Thread Lijo Lazar
On arcturus, allow changing xgmi plpd policy through 'pm_policy/xgmi_plpd' sysfs interface. Signed-off-by: Lijo Lazar Reviewed-by: Hawking Zhang Reviewed-by: Asad Kamal --- drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 7 ++-- .../gpu/drm/amd/pm/swsmu/smu11/arcturus_ppt.c | 42

[PATCH v5 09/10] drm/amd/pm: Remove unused interface to set plpd

2024-05-16 Thread Lijo Lazar
Remove unused callback to set PLPD policy and its implementation from arcturus, aldebaran and SMUv13.0.6 SOCs. Signed-off-by: Lijo Lazar Reviewed-by: Hawking Zhang Reviewed-by: Asad Kamal --- drivers/gpu/drm/amd/pm/swsmu/inc/amdgpu_smu.h | 6 --- .../gpu/drm/amd/pm/swsmu/smu11/arcturus_ppt.c

[PATCH v5 08/10] drm/amd/pm: Remove legacy interface for xgmi plpd

2024-05-16 Thread Lijo Lazar
Replace the legacy interface with amdgpu_dpm_set_pm_policy to set XGMI PLPD mode. Also, xgmi_plpd_policy sysfs node is not used by any client. Remove that as well. Signed-off-by: Lijo Lazar Reviewed-by: Hawking Zhang Reviewed-by: Asad Kamal --- v2: No change v3: Rebase to remove

[PATCH v5 10/10] Documentation/amdgpu: Add PM policy documentation

2024-05-16 Thread Lijo Lazar
Add documentation about the newly added pm_policy node in sysfs. Signed-off-by: Lijo Lazar --- v5: Update documentation to reflect pm_policy nodes and sub nodes for each policy type Documentation/gpu/amdgpu/thermal.rst | 6 drivers/gpu/drm/amd/pm/amdgpu_pm.c | 53

[PATCH v5 06/10] drm/amd/pm: Add xgmi plpd to aldebaran pm_policy

2024-05-16 Thread Lijo Lazar
On aldebaran, allow changing xgmi plpd policy through 'pm_policy/xgmi_plpd' sysfs interface. Signed-off-by: Lijo Lazar Reviewed-by: Hawking Zhang Reviewed-by: Asad Kamal --- .../drm/amd/pm/swsmu/smu13/aldebaran_ppt.c| 36 +++ 1 file changed, 36 insertions(+) diff --git

[PATCH v5 03/10] drm/amd/pm: Add support to select pstate policy

2024-05-16 Thread Lijo Lazar
Add support to select pstate policy in SOCs with SMUv13.0.6 Signed-off-by: Lijo Lazar eviewed-by: Hawking Zhang Reviewed-by: Asad Kamal --- v2,v3: No change v4: Use macro for policy type name .../gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c| 2 + .../drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c

[PATCH v5 05/10] drm/amd/pm: Add xgmi plpd to SMU v13.0.6 pm_policy

2024-05-16 Thread Lijo Lazar
On SOCs with SMU v13.0.6, allow changing xgmi plpd policy through 'pm_policy/xgmi_plpd' sysfs interface. Signed-off-by: Lijo Lazar Reviewed-by: Hawking Zhang Reviewed-by: Asad Kamal --- v2, v3: No change v4: Use macro for XGMI policy type name drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c |

[PATCH v5 04/10] drm/amd/pm: Add xgmi plpd policy to pm_policy

2024-05-16 Thread Lijo Lazar
Add support to set XGMI PLPD policy levels through 'pm_policy/xgmi_plpd' sysfs node. Signed-off-by: Lijo Lazar --- v2, v3: No change v4: Use a macro for XGMI PLPD policy type v5: Use a separate sysfs node for xgmi_plpd policy drivers/gpu/drm/amd/include/kgd_pp_interface.h | 1 +

[PATCH v5 02/10] drm/amd/pm: Update PMFW messages for SMUv13.0.6

2024-05-16 Thread Lijo Lazar
Add PMF message to select a Pstate policy in SOCs with SMU v13.0.6. Signed-off-by: Lijo Lazar Reviewed-by: Hawking Zhang Reviewed-by: Asad Kamal --- drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/smu_v13_0_6_ppsmc.h | 3 ++- drivers/gpu/drm/amd/pm/swsmu/inc/smu_types.h | 3 ++- 2

[PATCH v5 00/10] Add PM policy interfaces

2024-05-16 Thread Lijo Lazar
This series adds APIs to get the supported PM policies and also set them. A PM policy type is a predefined policy type supported by an SOC and each policy may define two or more levels to choose from. A user can select the appropriate level through amdgpu_dpm_set_pm_policy() or through sysfs node

[PATCH v5 01/10] drm/amd/pm: Add support for DPM policies

2024-05-16 Thread Lijo Lazar
Add support to set/get information about different DPM policies. The support is only available on SOCs which use swsmu architecture. A DPM policy type may be defined with different levels. For example, a policy may be defined to select Pstate preference and then later a pstate preference may be

[RFC 1/2] drm/amdgpu: Re-validate evicted buffers

2024-05-16 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Currently the driver appears to be thinking that it will be attempting to re-validate the evicted buffers on the next submission if they are not in their preferred placement. That however appears not to be true for the very common case of buffers with allowed placements of

[RFC 2/2] drm/amdgpu: Actually respect buffer migration budget

2024-05-16 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Current code appears to live in a misconception that playing with buffer allowed and preferred placements can always control the decision on whether backing store migration will be attempted or not. That is however not the case when userspace sets buffer placements of

[RFC v2 0/2] Discussion around eviction improvements

2024-05-16 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Reduced re-spin of my previous series after Christian corrected a few misconceptions that I had. So lets see if what remains makes sense or is still misguided. To summarise, the series address the following two issues: * Migration rate limiting does not work, at least not

[PATCH] drm/amd/pm: add return check for cast_const_phw_vega10_power_state

2024-05-16 Thread Bob Zhou
To avoid null pointer dereference, add return check and handle null pointer. Signed-off-by: Bob Zhou --- .../drm/amd/pm/powerplay/hwmgr/vega10_hwmgr.c | 28 +-- 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega10_hwmgr.c

Re: [PATCH] drm/amdgpu/display: Update kdoc for 'optc35_set_odm_combine'

2024-05-16 Thread Chung, ChiaHsuan (Tom)
Reviewed-by: Tom Chung On 5/15/2024 11:23 PM, Srinivasan Shanmugam wrote: The parameters segment_width and last_segment_width are used to control the configuration of the Output Plane Processor (OPP), specifically the width of each segment that the display is divided into and the width of the

RE: [PATCH 2/2] drm/amd/pm: enable thermal alert on smu 14.0.2/3

2024-05-16 Thread Gao, Likun
[AMD Official Use Only - AMD Internal Distribution Only] The series was Reviewed-by: Likun Gao . Regards, Likun -Original Message- From: Kenneth Feng Sent: Thursday, May 16, 2024 9:11 AM To: amd-gfx@lists.freedesktop.org Cc: Gao, Likun ; Feng, Kenneth Subject: [PATCH 2/2] drm/amd/pm: