[PATCH 2/2] drm/amdgpu: handle IH ring1 overflow

2021-11-12 Thread Philip Yang
IH ring1 is used to process GPU retry fault, overflow is enabled to drain retry fault because we want receive other interrupts while handling retry fault to recover range. There is no overflow flag set when wptr pass rptr, so amdgpu_ih_process check rptr equals to the wptr and exit, this can not

[PATCH 1/2] drm/amdgpu: IH process reset count when restart

2021-11-12 Thread Philip Yang
Otherwise when IH process restart, count is zero, the loop will not exit to wake_up_all after processing AMDGPU_IH_MAX_NUM_IVS interrupts. Signed-off-by: Philip Yang --- drivers/gpu/drm/amd/amdgpu/amdgpu_ih.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

Re: [PATCH] drm/amd/display: fix cond_no_effect.cocci warnings

2021-11-12 Thread Alex Deucher
Applied. Thanks! Alex On Fri, Nov 12, 2021 at 1:17 AM wrote: > > From: Ye Guojin > > This was found by coccicheck: > ./drivers/gpu/drm/amd/display/dc/core/dc_resource.c, 2516, 7-9, WARNING > possible condition with no effect (if == else) > > hdmi_info.bits.YQ0_YQ1 is always

Re: [PATCH] drm/amd/display: Clean up some inconsistent indenting

2021-11-12 Thread Alex Deucher
Applied. Thanks! Alex On Thu, Nov 11, 2021 at 5:09 AM Christian König wrote: > > > > Am 11.11.21 um 11:03 schrieb Jiapeng Chong: > > Eliminate the follow smatch warning: > > > > drivers/gpu/drm/amd/amdgpu/../display/dmub/src/dmub_srv.c:622 > > dmub_srv_cmd_execute() warn: inconsistent

Re: [PATCH] drm/amdgpu: fix set scaling mode Full/Full aspect/Center not works on vga and dvi connectors

2021-11-12 Thread Alex Deucher
Applied. Thanks! On Wed, Nov 10, 2021 at 10:54 PM hongao wrote: > > amdgpu_connector_vga_get_modes missed function amdgpu_get_native_mode > which assign amdgpu_encoder->native_mode with *preferred_mode result in > amdgpu_encoder->native_mode.clock always be 0. That will cause >

Re: [PATCH] drm/amdgpu: always reset the asic in suspend (v2)

2021-11-12 Thread Luben Tuikov
Acked-by: Luben Tuikov On 2021-11-12 11:25, Alex Deucher wrote: > If the platform suspend happens to fail and the power rail > is not turned off, the GPU will be in an unknown state on > resume, so reset the asic so that it will be in a known > good state on resume even if the platform

Re: [PATCH v10 08/10] dyndbg: add print-to-tracefs, selftest with it - RFC

2021-11-12 Thread Steven Rostedt
On Fri, 12 Nov 2021 10:08:41 -0500 Jason Baron wrote: > > A key difference between that patchset and this patch (besides that > > small fact that I used +x instead of +T) was that my patchset allowed > > the dyndbg trace to be emitted to the main buffer and did not force them > > to be in an

Re: [PATCH v10 08/10] dyndbg: add print-to-tracefs, selftest with it - RFC

2021-11-12 Thread Steven Rostedt
On Fri, 12 Nov 2021 12:32:23 -0500 Jason Baron wrote: > Ok, it looks like Vincent's patch defines a dyndbg event and then uses > 'trace_dyndbg()' to output to the 'main' log. So all dynamic output to > the 'main' ftrace buffer goes through that event if I understand it > correctly. Here's a

Re: [PATCH v10 08/10] dyndbg: add print-to-tracefs, selftest with it - RFC

2021-11-12 Thread Jason Baron
On 11/12/21 6:49 AM, Vincent Whitchurch wrote: > On Thu, Nov 11, 2021 at 03:02:04PM -0700, Jim Cromie wrote: >> Sean Paul proposed, in: >> https://urldefense.com/v3/__https://patchwork.freedesktop.org/series/78133/__;!!GjvTz_vk!HcKnMRByYkIdyF1apqQjlN5aBIomzJR1an3YWXM6KXs0EftVMQdrewRA8Dki4A$ >>

Re: [PATCH v10 08/10] dyndbg: add print-to-tracefs, selftest with it - RFC

2021-11-12 Thread Jason Baron
On 11/12/21 12:07 PM, Steven Rostedt wrote: > On Fri, 12 Nov 2021 10:08:41 -0500 > Jason Baron wrote: > >>> A key difference between that patchset and this patch (besides that >>> small fact that I used +x instead of +T) was that my patchset allowed >>> the dyndbg trace to be emitted to the

Re: [PATCH] drm/amd/pm: Add sysfs interface for retrieving gpu metrics(V2)

2021-11-12 Thread Alex Deucher
On Fri, Nov 12, 2021 at 12:46 PM Surbhi Kakarya wrote: > > A new interface for UMD to retrieve gpu metrics data. This patch is > based on an existing patch If7f3523915505c0ece0a56dfd476d2b8473440d4. > It's not clear what you are trying to do here. > Signed-off-by: Surbhi Kakarya > Change-Id:

Re: [PATCH 2/2] drm/amdgpu: Pin MMIO/DOORBELL BO's in GTT domain

2021-11-12 Thread Felix Kuehling
On 2021-11-11 4:13 p.m., Ramesh Errabolu wrote: MMIO/DOORBELL BOs encode control data and should be pinned in GTT domain before enabling PCIe connected peer devices in accessing it Signed-off-by: Ramesh Errabolu The series is Reviewed-by: Felix Kuehling ---

[PATCH] drm/amdgpu: always reset the asic in suspend (v2)

2021-11-12 Thread Alex Deucher
If the platform suspend happens to fail and the power rail is not turned off, the GPU will be in an unknown state on resume, so reset the asic so that it will be in a known good state on resume even if the platform suspend failed. v2: handle s0ix Signed-off-by: Alex Deucher ---

Re: [PATCH] drm/amdgpu: always reset the asic in suspend

2021-11-12 Thread Alex Deucher
Actually, ignore this for now. This will likely cause problems with S0ix. Alex On Fri, Nov 12, 2021 at 11:18 AM Alex Deucher wrote: > > If the platform suspend happens to fail and the power rail > is not turned off, the GPU will be in an unknown state on > resume, so reset the asic so that it

[PATCH] drm/amdgpu: always reset the asic in suspend

2021-11-12 Thread Alex Deucher
If the platform suspend happens to fail and the power rail is not turned off, the GPU will be in an unknown state on resume, so reset the asic so that it will be in a known good state on resume even if the platform suspend failed. Signed-off-by: Alex Deucher ---

Re: Questions about KMS flip

2021-11-12 Thread Michel Dänzer
On 2021-11-12 16:03, Christian König wrote: > Am 12.11.21 um 15:30 schrieb Michel Dänzer: >> On 2021-11-12 15:29, Michel Dänzer wrote: >>> On 2021-11-12 13:47, Christian König wrote: Anyway this unfortunately turned out to be work for Harray and Nicholas. In detail it's about this bug

Re: [PATCH] drm/amd/display: Reduce dmesg error to a debug print

2021-11-12 Thread Kazlauskas, Nicholas
On 2021-11-12 10:56 a.m., Leo (Hanghong) Ma wrote: [Why & How] Dmesg errors are found on dcn3.1 during reset test, but it's not a really failure. So reduce it to a debug print. Signed-off-by: Leo (Hanghong) Ma This is expected to occur on displays that aren't connected/don't support LTTPR

[PATCH] drm/amd/display: Reduce dmesg error to a debug print

2021-11-12 Thread Leo (Hanghong) Ma
[Why & How] Dmesg errors are found on dcn3.1 during reset test, but it's not a really failure. So reduce it to a debug print. Signed-off-by: Leo (Hanghong) Ma --- drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH v1] drm/amd/pm: add GFXCLK/SCLK clocks level print support for APUs

2021-11-12 Thread Alex Deucher
On Thu, Nov 11, 2021 at 4:35 AM Perry Yuan wrote: > > add support that allow the userspace tool like RGP to get the GFX clock > value at runtime, the fix follow the old way to show the min/current/max > clocks level for compatible consideration. > > === Test === > $ cat

Re: Questions about KMS flip

2021-11-12 Thread Christian König
Am 12.11.21 um 15:30 schrieb Michel Dänzer: On 2021-11-12 15:29, Michel Dänzer wrote: On 2021-11-12 13:47, Christian König wrote: Anyway this unfortunately turned out to be work for Harray and Nicholas. In detail it's about this bug report here:

Re: Questions about KMS flip

2021-11-12 Thread Michel Dänzer
On 2021-11-12 15:29, Michel Dänzer wrote: > On 2021-11-12 13:47, Christian König wrote: >> >> Anyway this unfortunately turned out to be work for Harray and Nicholas. In >> detail it's about this bug report here: >> https://bugzilla.kernel.org/show_bug.cgi?id=214621 >> >> Lang was able to

Re: Questions about KMS flip

2021-11-12 Thread Michel Dänzer
On 2021-11-12 13:47, Christian König wrote: > > Anyway this unfortunately turned out to be work for Harray and Nicholas. In > detail it's about this bug report here: > https://bugzilla.kernel.org/show_bug.cgi?id=214621 > > Lang was able to reproduce the issue and narrow it down to the pin in

Re: [PATCH v10 08/10] dyndbg: add print-to-tracefs, selftest with it - RFC

2021-11-12 Thread Vincent Whitchurch
On Thu, Nov 11, 2021 at 03:02:04PM -0700, Jim Cromie wrote: > Sean Paul proposed, in: > https://patchwork.freedesktop.org/series/78133/ > drm/trace: Mirror DRM debug logs to tracefs > > His patchset's objective is to be able to independently steer some of > the drm.debug stream to an alternate

Re: Questions about KMS flip

2021-11-12 Thread Christian König
Hi guys, Am 10.11.21 um 14:26 schrieb Daniel Vetter: [SNIP] stack depot, not stuff it into a string. stack depot is a lot more efficient and capturing backtraces, since it de-dupes and hashes and all you need is a pointer iirc. linux/stackdepot.h for interface, I think we recently gained a few

[PATCH] drm/amd/display: clean up some inconsistent indenting

2021-11-12 Thread Jiapeng Chong
Eliminate the follow smatch warning: drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm_debugfs.c:2245 dp_dsc_slice_bpg_offset_read() warn: inconsistent indenting. drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm_debugfs.c:2044 dp_dsc_pic_width_read() warn: inconsistent

[PATCH] drm/amd/display: fix cond_no_effect.cocci warnings

2021-11-12 Thread cgel . zte
From: Ye Guojin This was found by coccicheck: ./drivers/gpu/drm/amd/display/dc/core/dc_resource.c, 2516, 7-9, WARNING possible condition with no effect (if == else) hdmi_info.bits.YQ0_YQ1 is always YYC_QUANTIZATION_LIMITED_RANGE. Reported-by: Zeal Robot Signed-off-by: Ye Guojin ---

[PATCH] drm/amd/display: Clean up some inconsistent indenting

2021-11-12 Thread Jiapeng Chong
Eliminate the follow smatch warning: drivers/gpu/drm/amd/amdgpu/../display/dmub/src/dmub_srv.c:622 dmub_srv_cmd_execute() warn: inconsistent indenting. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c | 2 +- 1 file changed, 1

Re: [PATCH] drm/amd/pm: avoid duplicate powergate/ungate setting

2021-11-12 Thread Lazar, Lijo
On 11/11/2021 1:27 PM, Evan Quan wrote: Just bail out if the target IP block is already in the desired powergate/ungate state. This can avoid some duplicate settings which sometimes may cause unexpected issues. Link: https://lore.kernel.org/all/yv81vidwqlwva...@zn.tnic/ Change-Id:

Re: [PATCH 1/1] SWDEV-306029 - add new sysfs interface for retrieving gpu metrics(V2)

2021-11-12 Thread Lazar, Lijo
On 11/12/2021 12:35 AM, Surbhi Kakarya wrote: A new interface for UMD to retrieve gpu metrics data. Change-Id: Ieb8d56740147cf60a869a7fa0ef43d05cfbf802f Signed-off-by: Surbhi Kakarya This is not the right way, looks like you need to port this to your tree -