Re: [PATCH 2/3] drm/amdgpu: add RAS poison consumption handler

2022-04-19 Thread Lazar, Lijo
On 4/20/2022 11:51 AM, Zhou1, Tao wrote: [AMD Official Use Only] -Original Message- From: Lazar, Lijo Sent: Wednesday, April 20, 2022 12:33 PM To: Zhou1, Tao ; amd-gfx@lists.freedesktop.org; Zhang, Hawking ; Yang, Stanley ; Ziya, Mohammad zafar ; Chai, Thomas Subject: Re: [PATCH

RE: [PATCH 2/3] drm/amdgpu: add RAS poison consumption handler

2022-04-19 Thread Zhou1, Tao
[AMD Official Use Only] > -Original Message- > From: Lazar, Lijo > Sent: Wednesday, April 20, 2022 12:33 PM > To: Zhou1, Tao ; amd-gfx@lists.freedesktop.org; Zhang, > Hawking ; Yang, Stanley > ; Ziya, Mohammad zafar > ; Chai, Thomas > Subject: Re: [PATCH 2/3] drm/amdgpu: add RAS poison

RE: [PATCH 1/3] drm/amdgpu: implement RAS interrupt handler for poison creation

2022-04-19 Thread Zhang, Hawking
Please also keep the naming style consistent by using "amdgpu_ras" prefix Regards, Hawking -Original Message- From: Zhou1, Tao Sent: Wednesday, April 20, 2022 14:17 To: Lazar, Lijo ; amd-gfx@lists.freedesktop.org; Zhang, Hawking ; Yang, Stanley ; Ziya, Mohammad zafar ; Chai, Thomas S

RE: [PATCH 1/3] drm/amdgpu: implement RAS interrupt handler for poison creation

2022-04-19 Thread Zhou1, Tao
[AMD Official Use Only] > -Original Message- > From: Lazar, Lijo > Sent: Wednesday, April 20, 2022 12:10 PM > To: Zhou1, Tao ; amd-gfx@lists.freedesktop.org; Zhang, > Hawking ; Yang, Stanley > ; Ziya, Mohammad zafar > ; Chai, Thomas > Subject: Re: [PATCH 1/3] drm/amdgpu: implement RAS

Re: [PATCH 2/3] drm/amdgpu: add RAS poison consumption handler

2022-04-19 Thread Lazar, Lijo
On 4/20/2022 9:23 AM, Tao Zhou wrote: Add support for general RAS poison consumption handler. Signed-off-by: Tao Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 43 - drivers/gpu/drm/amd/amdgpu/amdgpu_ras.h | 1 + 2 files changed, 43 insertions(+), 1 deletion(

Re: [PATCH 1/3] drm/amdgpu: implement RAS interrupt handler for poison creation

2022-04-19 Thread Lazar, Lijo
On 4/20/2022 9:23 AM, Tao Zhou wrote: Prepare for the implementation of poison consumption handler. Signed-off-by: Tao Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 62 ++--- 1 file changed, 35 insertions(+), 27 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgp

Re: [PATCH 03/15] dma-buf & drm/amdgpu: remove dma_resv workaround

2022-04-19 Thread Zack Rusin
On Thu, 2022-04-07 at 10:59 +0200, Christian König wrote: > Rework the internals of the dma_resv object to allow adding more than > one > write fence and remember for each fence what purpose it had. > > This allows removing the workaround from amdgpu which used a container > for > this instead. >

[PATCH 3/3] drm/amdgpu: add RAS fatal error interrupt handler

2022-04-19 Thread Tao Zhou
The fatal error handler is independent from general ras interrupt handler since there is no related IH ring. Signed-off-by: Tao Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 15 +-- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 20 drivers/gpu/drm/amd/amdgpu/amd

[PATCH 2/3] drm/amdgpu: add RAS poison consumption handler

2022-04-19 Thread Tao Zhou
Add support for general RAS poison consumption handler. Signed-off-by: Tao Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 43 - drivers/gpu/drm/amd/amdgpu/amdgpu_ras.h | 1 + 2 files changed, 43 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/am

[PATCH 1/3] drm/amdgpu: implement RAS interrupt handler for poison creation

2022-04-19 Thread Tao Zhou
Prepare for the implementation of poison consumption handler. Signed-off-by: Tao Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 62 ++--- 1 file changed, 35 insertions(+), 27 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c b/drivers/gpu/drm/amd/amdgpu/

Re: [PATCH] drm/amdgpu: keep mmhub clock gating being enabled during s2idle suspend

2022-04-19 Thread Lazar, Lijo
On 4/20/2022 7:32 AM, Prike Liang wrote: Without MMHUB clock gating being enabled then MMHUB will not disconnect from DF and will result in DF C-state entry can't be accessed during S2idle suspend, and eventually s0ix entry will be blocked. Signed-off-by: Prike Liang --- drivers/gpu/drm/am

[PATCH] Revert "drm/amdkfd: only allow heavy-weight TLB flush on some ASICs for SVM too"

2022-04-19 Thread Lang Yu
This reverts commit a129dbca92edaeb5a515a0e5b63ada71cf9b981a. It causes SVM regressions on Vega10 with XNACK-ON. Just revert it at the moment. ./kfdtest --gtest_filter=KFDSVMRangeTest.MigratePolicyTest Signed-off-by: Lang Yu --- drivers/gpu/drm/amd/amdkfd/kfd_svm.c | 4 +--- 1 file changed, 1

[PATCH] drm/amdgpu: keep mmhub clock gating being enabled during s2idle suspend

2022-04-19 Thread Prike Liang
Without MMHUB clock gating being enabled then MMHUB will not disconnect from DF and will result in DF C-state entry can't be accessed during S2idle suspend, and eventually s0ix entry will be blocked. Signed-off-by: Prike Liang --- drivers/gpu/drm/amd/amdgpu/mmhub_v2_3.c | 9 + 1 file cha

[PATCH 2/2] drm/amdkfd: Update mapping if range attributes changed

2022-04-19 Thread Philip Yang
Change SVM range mapping flags or access attributes don't trigger migration, if range is already mapped on GPUs we should update GPU mapping, and pass flush_tlb flag to amdgpu vm. Signed-off-by: Philip Yang --- drivers/gpu/drm/amd/amdkfd/kfd_svm.c | 41 ++-- 1 file change

[PATCH 1/2] drm/amdkfd: Add SVM range mapped_to_gpu flag

2022-04-19 Thread Philip Yang
To avoid unnecessary unmap SVM range from GPUs if range is not mapped on GPUs when migrating the range. This flag will also be used to flush TLB when updating the existing mapping on GPUs. It is protected by prange->migrate_mutex and mmap read lock in MMU notifier callback. Signed-off-by: Philip

Re: [PATCHv4] drm/amdgpu: disable ASPM on Intel Alder Lake based systems

2022-04-19 Thread Gong, Richard
Hi Paul, On 4/14/2022 2:52 AM, Paul Menzel wrote: [Cc: -kernel test robot ] Dear Alex, dear Richard, Am 13.04.22 um 15:00 schrieb Alex Deucher: On Wed, Apr 13, 2022 at 3:43 AM Paul Menzel wrote: Thank you for sending out v4. Am 12.04.22 um 23:50 schrieb Richard Gong: Active State Power M

Re: [PATCHv4] drm/amdgpu: disable ASPM on Intel Alder Lake based systems

2022-04-19 Thread Gong, Richard
Hi Nathan, On 4/13/2022 10:40 AM, Nathan Chancellor wrote: Hi Richard, On Tue, Apr 12, 2022 at 04:50:00PM -0500, Richard Gong wrote: Active State Power Management (ASPM) feature is enabled since kernel 5.14. There are some AMD GFX cards (such as WX3200 and RX640) that won't work with ASPM-enab

2022 X.Org Foundation Election vote results

2022-04-19 Thread Lyude Paul
The Board of Directors election and the vote on the By-laws concluded at 23:59 UTC on 18 April 2022. There are 80 current Members of the X.Org Foundation, and 52 Members cast votes. This is a 65.0% turn out. In the election of the Directors to the Board of the X.Org Foundation, the results were th

Re: [PATCH 1/2] drm/amdgpu: Execute IP's hw_fini when hw_init failed

2022-04-19 Thread Alex Deucher
On Tue, Apr 19, 2022 at 3:38 PM Alice Wong wrote: > > amdgpu_device_ip_hw_init_phase1 and amdgpu_device_ip_hw_init_phase2 > call IP blocks' respective hw_fini when hw_init failed. I don't think we should call hw_fini() if hw_init() failed. If there are things that are not properly cleaned up in

[PATCH 2/2] drm/amdgpu: Free ucode bo memory during load failure v1

2022-04-19 Thread Wong, Alice
[AMD Official Use Only] Remove firmware.load_type check in amdgpu_ucode_free_bo. If psp failed to load a firmware, it will set formware.load_type to AMDGPU_FW_LOAD_DIRECT for bring up purposes. This caused memory leak as amdpug_ucode_free_bo will skip freeing memory due to the load_type. BUG:S

RE: [PATCH 1/2] drm/amdgpu: Execute IP's hw_fini when hw_init failed

2022-04-19 Thread Wong, Alice
[AMD Official Use Only] amdgpu_device_ip_hw_init_phase1 and amdgpu_device_ip_hw_init_phase2 call IP blocks' respective hw_fini when hw_init failed. BUG:SWDEV-332449 Signed-off-by: Alice Wong --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/d

[PATCH 2/2] drm/amdgpu: Free ucode bo memory during load failure v1

2022-04-19 Thread Alice Wong
Remove firmware.load_type check in amdgpu_ucode_free_bo. If psp failed to load a firmware, it will set formware.load_type to AMDGPU_FW_LOAD_DIRECT for bring up purposes. This caused memory leak as amdpug_ucode_free_bo will skip freeing memory due to the load_type. BUG:SWDEV-332449 Signed-off-by:

[PATCH 1/2] drm/amdgpu: Execute IP's hw_fini when hw_init failed

2022-04-19 Thread Alice Wong
amdgpu_device_ip_hw_init_phase1 and amdgpu_device_ip_hw_init_phase2 call IP blocks' respective hw_fini when hw_init failed. BUG:SWDEV-332449 Signed-off-by: Alice Wong --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/a

[linux-next:master] BUILD REGRESSION 634de1db0e9bbeb90d7b01020e59ec3dab4d38a1

2022-04-19 Thread kernel test robot
tree/branch: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master branch HEAD: 634de1db0e9bbeb90d7b01020e59ec3dab4d38a1 Add linux-next specific files for 20220419 Error/Warning reports: https://lore.kernel.org/linux-mm/202204081656.6x4pfen4-...@intel.com https

Re: [EXTERNAL] [PATCH 2/2] drm/amdkfd: Add PCIe Hotplug Support for AMDKFD

2022-04-19 Thread Felix Kuehling
Am 2022-04-19 um 12:01 schrieb Andrey Grodzovsky: --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.h +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.h @@ -134,6 +134,7 @@ struct amdkfd_process_info { /* MMU-notifier related fields */ atomic_t evicted_bos; +atomic_t invalid; struct delayed_work resto

Re: [PATCH 2/2] drm/amdgpu: remove pointless ttm_eu usage from DM

2022-04-19 Thread Harry Wentland
On 2022-04-19 10:42, Christian König wrote: Am 19.04.22 um 16:37 schrieb Harry Wentland: On 2022-04-19 10:19, Christian König wrote: We just need to reserve the BO here, no need for using ttm_eu. Signed-off-by: Christian König Acked-by: Harry Wentland What about the second patch? Wh

Re: [PATCH] drm/amdgpu/powerplay/vega10: fix minmax.cocci warnings

2022-04-19 Thread Alex Deucher
On Sat, Apr 16, 2022 at 11:41 AM Julia Lawall wrote: > > From: kernel test robot > > Use max to simplify the code. > > Generated by: scripts/coccinelle/misc/minmax.cocci > > CC: Denis Efremov > Reported-by: kernel test robot > Signed-off-by: kernel test robot > Signed-off-by: Julia Lawall Th

Re: [PATCH 1/2] drm/amdgpu: remove pointless ttm_eu usage from vkms

2022-04-19 Thread Alex Deucher
On Tue, Apr 19, 2022 at 10:55 AM Christian König wrote: > > Am 19.04.22 um 16:49 schrieb Alex Deucher: > > On Tue, Apr 19, 2022 at 10:19 AM Christian König > > wrote: > >> We just need to reserve the BO here, no need for using ttm_eu. > > Can you include a more detailed description as to why it's

Re: [PATCH 1/2] Documentation/gpu: Add entries to amdgpu glossary

2022-04-19 Thread Alex Deucher
Applied the series with minor fix to capitalize the U in Compute Unit. Thanks! Alex On Fri, Apr 15, 2022 at 3:52 PM Tales Lelo da Aparecida wrote: > > Add missing acronyms to the amdgppu glossary. > > Closes: https://gitlab.freedesktop.org/drm/amd/-/issues/1939#note_1309737 > Signed-off-by: Tal

Re: [PATCH 1/2] drm/amdgpu: remove pointless ttm_eu usage from vkms

2022-04-19 Thread Christian König
Am 19.04.22 um 16:49 schrieb Alex Deucher: On Tue, Apr 19, 2022 at 10:19 AM Christian König wrote: We just need to reserve the BO here, no need for using ttm_eu. Can you include a more detailed description as to why it's not necessary? Well the logic in ttm_eu is for reserving multiple buffe

Re: [PATCH] drm/radeon/kms: change evergreen_default_state table from global to static

2022-04-19 Thread Alex Deucher
Applied. Thanks! On Sat, Apr 16, 2022 at 2:48 PM Tom Rix wrote: > > evergreen_default_state and evergreen_default_size are only > used in evergreen.c. Single file symbols should be static. > So move their definitions to evergreen_blit_shaders.h > and change their storage-class-specifier to stat

Re: [PATCH] drm/amd/display: add virtual_setup_stream_attribute decl to header

2022-04-19 Thread Alex Deucher
Applied. Thanks! On Mon, Apr 18, 2022 at 3:48 PM Tom Rix wrote: > > Smatch reports this issue > virtual_link_hwss.c:32:6: warning: symbol > 'virtual_setup_stream_attribute' was not declared. > Should it be static? > > virtual_setup_stream_attribute is only used in > virtual_link_hwss.c, but

Re: [PATCH 1/2] drm/amdgpu: remove pointless ttm_eu usage from vkms

2022-04-19 Thread Alex Deucher
On Tue, Apr 19, 2022 at 10:19 AM Christian König wrote: > > We just need to reserve the BO here, no need for using ttm_eu. Can you include a more detailed description as to why it's not necessary? Most of this code was copied from radeon originally. Does radeon need a similar cleanup? Alex >

Re: [PATCH] drm/amdgpu: don't runtime suspend if there are displays attached (v2)

2022-04-19 Thread Alex Deucher
On Tue, Apr 19, 2022 at 10:04 AM Paul Menzel wrote: > > Dear Alex, > > > Thank you for the patch. > > Am 13.04.22 um 22:15 schrieb Alex Deucher: > > We normally runtime suspend when there are displays attached if they > > are in the DPMS off state, however, if something wakes the GPU > > we send a

Re: [PATCH 2/2] drm/amdgpu: remove pointless ttm_eu usage from DM

2022-04-19 Thread Christian König
Am 19.04.22 um 16:37 schrieb Harry Wentland: On 2022-04-19 10:19, Christian König wrote: We just need to reserve the BO here, no need for using ttm_eu. Signed-off-by: Christian König Acked-by: Harry Wentland What about the second patch? Who takes care of amdgpu_vkms.c? You guys or shou

Re: [PATCH] drm/amd/pm: fix double free in si_parse_power_table()

2022-04-19 Thread Alex Deucher
Applied. Thanks! On Tue, Apr 19, 2022 at 8:49 AM Keita Suzuki wrote: > > In function si_parse_power_table(), array adev->pm.dpm.ps and its member > is allocated. If the allocation of each member fails, the array itself > is freed and returned with an error code. However, the array is later > fre

Re: [PATCH 2/2] drm/amdgpu: remove pointless ttm_eu usage from DM

2022-04-19 Thread Harry Wentland
On 2022-04-19 10:19, Christian König wrote: We just need to reserve the BO here, no need for using ttm_eu. Signed-off-by: Christian König Acked-by: Harry Wentland Harry --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 32 ++- 1 file changed, 17 insertions(+), 15 d

Re: [PATCH] drm/amd/display: make hubp1_wait_pipe_read_start() static

2022-04-19 Thread Alex Deucher
Applied with minor change to drop the prototype in dcn10_hubp.h. Thanks! Alex On Fri, Apr 15, 2022 at 2:21 PM Tales Lelo da Aparecida wrote: > > It's a local function, let's make it static. > > Signed-off-by: Tales Lelo da Aparecida > --- > drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hubp.c |

[PATCH 2/2] drm/amdgpu: remove pointless ttm_eu usage from DM

2022-04-19 Thread Christian König
We just need to reserve the BO here, no need for using ttm_eu. Signed-off-by: Christian König --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 32 ++- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/g

[PATCH 1/2] drm/amdgpu: remove pointless ttm_eu usage from vkms

2022-04-19 Thread Christian König
We just need to reserve the BO here, no need for using ttm_eu. Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_vkms.c | 32 +--- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vkms.c b/drivers/gpu/drm/am

Re: [PATCH] drm/amdgpu: don't runtime suspend if there are displays attached (v2)

2022-04-19 Thread Paul Menzel
Dear Alex, Thank you for the patch. Am 13.04.22 um 22:15 schrieb Alex Deucher: We normally runtime suspend when there are displays attached if they are in the DPMS off state, however, if something wakes the GPU we send a hotplug event on resume (in case any displays were connected while the GP

Re: [PATCH] drm/amdgpu: partial revert "remove ctx->lock" v2

2022-04-19 Thread Alex Deucher
On Tue, Apr 19, 2022 at 7:06 AM Christian König wrote: > > This reverts commit 461fa7b0ac565ef25c1da0ced31005dd437883a7. > > We are missing some inter dependencies here so re-introduce the lock > until we have figured out what's missing. Just drop/retake it while > adding dependencies. > > v2: sti

Re: [PATCH] drm/amdgpu: don't runtime suspend if there are displays attached (v2)

2022-04-19 Thread Alex Deucher
Ping? On Wed, Apr 13, 2022 at 4:15 PM Alex Deucher wrote: > > We normally runtime suspend when there are displays attached if they > are in the DPMS off state, however, if something wakes the GPU > we send a hotplug event on resume (in case any displays were connected > while the GPU was in suspe

[PATCH] drm/amd/pm: fix double free in si_parse_power_table()

2022-04-19 Thread Keita Suzuki
In function si_parse_power_table(), array adev->pm.dpm.ps and its member is allocated. If the allocation of each member fails, the array itself is freed and returned with an error code. However, the array is later freed again in si_dpm_fini() function which is called when the function returns an er

RE: [PATCH v2 2/2] drm/amdkfd: CRIU add support for GWS queues

2022-04-19 Thread Yat Sin, David
> -Original Message- > From: Paul Menzel > Sent: Tuesday, April 19, 2022 2:54 AM > To: Yat Sin, David > Cc: Kuehling, Felix ; amd- > g...@lists.freedesktop.org > Subject: Re: [PATCH v2 2/2] drm/amdkfd: CRIU add support for GWS queues > > > Dear David, > > > Thank you for sending out

[PATCH] drm/amdgpu: partial revert "remove ctx->lock" v2

2022-04-19 Thread Christian König
This reverts commit 461fa7b0ac565ef25c1da0ced31005dd437883a7. We are missing some inter dependencies here so re-introduce the lock until we have figured out what's missing. Just drop/retake it while adding dependencies. v2: still drop the lock while adding dependencies Signed-off-by: Christian K

[PATCH] drm/amd/display: add virtual_setup_stream_attribute decl to header

2022-04-19 Thread Tom Rix
Smatch reports this issue virtual_link_hwss.c:32:6: warning: symbol 'virtual_setup_stream_attribute' was not declared. Should it be static? virtual_setup_stream_attribute is only used in virtual_link_hwss.c, but the other functions in the file are declared in the header file and used elsewhere

[PATCH] drm/radeon/kms: change evergreen_default_state table from global to static

2022-04-19 Thread Tom Rix
evergreen_default_state and evergreen_default_size are only used in evergreen.c. Single file symbols should be static. So move their definitions to evergreen_blit_shaders.h and change their storage-class-specifier to static. Remove unneeded evergreen_blit_shader.c evergreen_ps/vs definitions wer