Re: [PATCH] drm/amdgpu: disable page queue on Vega10 SR-IOV VF

2018-11-06 Thread Christian König
Am 07.11.18 um 06:15 schrieb Trigger Huang: Currently, SDMA page queue is not used under SR-IOV VF, and this queue will cause ring test failure in amdgpu module reload case. So just disable it. Signed-off-by: Trigger Huang --- drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c | 4 +++- 1 file changed,

Re: [PATCH] drm/amdgpu: disable page queue on Vega10 SR-IOV VF

2018-11-06 Thread Koenig, Christian
Am 07.11.18 um 08:41 schrieb Zhang, Jerry(Junwei): > On 11/7/18 3:29 PM, Koenig, Christian wrote: >> Hi guys, >> >> this is necessary for recoverable page fault handling. >> >> When the normal SDMA queue is blocked because of a page fault the SDMA >> firmware will switch to the paging queue so that

Re: [PATCH] drm/amdgpu: disable page queue on Vega10 SR-IOV VF

2018-11-06 Thread Zhang, Jerry(Junwei)
On 11/7/18 3:29 PM, Koenig, Christian wrote: Hi guys, this is necessary for recoverable page fault handling. When the normal SDMA queue is blocked because of a page fault the SDMA firmware will switch to the paging queue so that we are able to handle the fault. Thanks for your info. IIRC, pag

Re: [PATCH] drm/amdgpu: disable page queue on Vega10 SR-IOV VF

2018-11-06 Thread Koenig, Christian
Hi guys, this is necessary for recoverable page fault handling. When the normal SDMA queue is blocked because of a page fault the SDMA firmware will switch to the paging queue so that we are able to handle the fault. In general it should work on all Vega (but not Raven) components and we are

RE: [PATCH] drm/amdgpu: disable page queue on Vega10 SR-IOV VF

2018-11-06 Thread Liu, Monk
Hi team Why we need this page_queue in amdgpu ? can anyone share something of its introduction to the kmd ? According to my understanding , gpu-scheduler already have couple levels of priority for contexts/entities , thus the job page_queue supposed to do (should be mapping/unmapping/moving) i

Re: [PATCH] drm/amdgpu: disable page queue on Vega10 SR-IOV VF

2018-11-06 Thread Zhang, Jerry(Junwei)
On 11/7/18 1:15 PM, Trigger Huang wrote: Currently, SDMA page queue is not used under SR-IOV VF, and this queue will cause ring test failure in amdgpu module reload case. So just disable it. Signed-off-by: Trigger Huang Looks we ran into several issues about it on vega. kfd also disabled vega

[PATCH] drm/amdgpu: disable page queue on Vega10 SR-IOV VF

2018-11-06 Thread Trigger Huang
Currently, SDMA page queue is not used under SR-IOV VF, and this queue will cause ring test failure in amdgpu module reload case. So just disable it. Signed-off-by: Trigger Huang --- drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dri

RE: [PATCH] drm/amdgpu: fix frame size of amdgpu_xgmi_add_devices excceed 1024 bytes

2018-11-06 Thread Zhang, Hawking
Fixed and pushed. Thanks. Regards, Hawking From: Yuan, Xiaojie Sent: 2018年11月7日 11:51 To: Zhang, Hawking ; amd-gfx@lists.freedesktop.org Subject: Re: [PATCH] drm/amdgpu: fix frame size of amdgpu_xgmi_add_devices excceed 1024 bytes Would be better to add a is-null check for 'tmp_topology' after

Re: [PATCH] drm/amdgpu: fix frame size of amdgpu_xgmi_add_devices excceed 1024 bytes

2018-11-06 Thread Yuan, Xiaojie
Would be better to add a is-null check for 'tmp_topology' after kzalloc(). With that fixed, patch is Reviewed-by: Xiaojie Yuan Regards, Xiaojie From: amd-gfx on behalf of Hawking Zhang Sent: Wednesday, November 7, 2018 11:29 AM To: amd-gfx@lists.freedeskto

[PATCH] drm/amdgpu: fix frame size of amdgpu_xgmi_add_devices excceed 1024 bytes

2018-11-06 Thread Hawking Zhang
Instead of stack-allocated psp_xgmi_topology_info in function amdgpu_xgmi_add_device, dynamically allocated this structure to avoid the frame size of this function excceed 1024 bytes. Signed-off-by: Hawking Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c | 11 ++- 1 file changed, 6 in

RE: [PATCH 1/3] drm/amd/powerplay: set a default fclk/gfxclk ratio

2018-11-06 Thread Xu, Feifei
Seriel is reviewed-by: Feifei Xu -Original Message- From: amd-gfx On Behalf Of Evan Quan Sent: Wednesday, November 7, 2018 9:38 AM To: amd-gfx@lists.freedesktop.org Cc: Quan, Evan Subject: [PATCH 1/3] drm/amd/powerplay: set a default fclk/gfxclk ratio Otherwise big gap between these tw

[PATCH 1/3] drm/amd/powerplay: set a default fclk/gfxclk ratio

2018-11-06 Thread Evan Quan
Otherwise big gap between these two clocks may causes some hangs. Change-Id: Ifa3fafe2ee619d6231d5ecab61d3c68faa34abb6 Signed-off-by: Evan Quan --- .../gpu/drm/amd/powerplay/hwmgr/vega20_hwmgr.c | 16 .../gpu/drm/amd/powerplay/hwmgr/vega20_hwmgr.h | 1 + drivers/gpu/drm/amd

[PATCH 2/3] drm/amd/powerplay: always use fast UCLK switching when UCLK DPM enabled

2018-11-06 Thread Evan Quan
With UCLK DPM enabled, slow switching is not supported any more. Change-Id: I6242e782441272487aebd161836868785a6f7ee8 Signed-off-by: Evan Quan --- .../drm/amd/powerplay/hwmgr/vega20_hwmgr.c| 37 +-- 1 file changed, 17 insertions(+), 20 deletions(-) diff --git a/drivers/gpu/d

[PATCH 3/3] drm/amdgpu: set Vega20 LBPW as disabled at default

2018-11-06 Thread Evan Quan
For Vega20, LBPW feature is disabled at default. Change-Id: I184520cbb03ab8cba9321cd94d1deb0ce38b7e17 Signed-off-by: Evan Quan --- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c b/drivers/gpu/drm/am

Re: [PATCH] drm/ttm: Fix bo_global and mem_global kfree error

2018-11-06 Thread Zhang, Jerry(Junwei)
On 11/6/18 7:59 PM, Christian König wrote: Am 06.11.18 um 12:54 schrieb Trigger Huang: ttm_bo_glob and ttm_mem_glob are defined as structure instance, while not allocated by kzalloc, so kfree should not be invoked to release them anymore. Otherwise, it will cause the following kernel BUG when un

Re: [PATCH 6/9] drm/amdgpu: KFD Restore process: Optimize waiting

2018-11-06 Thread Alex Deucher
On Mon, Nov 5, 2018 at 8:41 PM Kuehling, Felix wrote: > > From: Harish Kasiviswanathan > > Instead of waiting for each KFD BO after validation just wait for the > last BO moving fence. > > Signed-off-by: Harish Kasiviswanathan > Reviewed-by: Felix Kuehling > Signed-off-by: Felix Kuehling Acke

Re: [PATCH 5/9] drm/amdgpu: Remove explicit wait after VM validate

2018-11-06 Thread Alex Deucher
On Mon, Nov 5, 2018 at 8:41 PM Kuehling, Felix wrote: > > From: Harish Kasiviswanathan > > PD or PT might have to be moved during validation and this move has to be > completed before updating it. If page table updates are done using SDMA > then this serializing is done by SDMA command submission

Re: [PATCH 4/9] drm/amdkfd: Workaround PASID missing in gfx9 interrupt payload under non HWS

2018-11-06 Thread Alex Deucher
On Mon, Nov 5, 2018 at 8:41 PM Kuehling, Felix wrote: > > From: Yong Zhao > > This is a known gfx9 HW issue, and this change can perfectly workaround > the issue. > > Signed-off-by: Yong Zhao > Reviewed-by: Felix Kuehling > Signed-off-by: Felix Kuehling Acked-by: Alex Deucher > --- > drive

Re: [PATCH 3/9] drm/amdkfd: Adjust the debug message in KFD ISR

2018-11-06 Thread Alex Deucher
On Mon, Nov 5, 2018 at 8:40 PM Kuehling, Felix wrote: > > From: Yong Zhao > > This makes debug message get printed even when there is early return. > > Signed-off-by: Yong Zhao > Reviewed-by: Felix Kuehling > Signed-off-by: Felix Kuehling Reviewed-by: Alex Deucher > --- > drivers/gpu/drm/a

Re: [PATCH 2/9] drm/amdkfd: Added Vega12 and Polaris12 for KFD.

2018-11-06 Thread Alex Deucher
On Mon, Nov 5, 2018 at 8:41 PM Kuehling, Felix wrote: > > From: Gang Ba > > Add Vega12 and Polaris12 device info and device IDs to KFD. > > Signed-off-by: Gang Ba > Reviewed-by: Felix Kuehling > Signed-off-by: Felix Kuehling Reviewed-by: Alex Deucher > --- > drivers/gpu/drm/amd/amdgpu/amdg

Re: [PATCH 1/9] drm/amdkfd: Replace mqd with mqd_mgr as the variable name for mqd_manager

2018-11-06 Thread Alex Deucher
On Mon, Nov 5, 2018 at 8:40 PM Kuehling, Felix wrote: > > From: Yong Zhao > > This will make reading code much easier. This fixes a few spots missed in a > previous commit with the same title. > > Signed-off-by: Yong Zhao > Reviewed-by: Felix Kuehling > Signed-off-by: Felix Kuehling Reviewed-

Re: [PATCH 5/5] drm/amdgpu/display/dce11: only enable FBC when selected

2018-11-06 Thread Wentland, Harry
On 2018-11-06 3:29 p.m., Alex Deucher wrote: > Causes a black screen on a Stoney laptop. > > bug: https://bugs.freedesktop.org/show_bug.cgi?id=108577 > Signed-off-by: Alex Deucher Thanks. Series is Reviewed-by: Harry Wentland Harry > --- > drivers/gpu/drm/amd/display/dc/dce110/dce110_resour

[PATCH 1/5] drm/amdgpu/display: check if fbc is available in set_static_screen_control (v2)

2018-11-06 Thread Alex Deucher
The value is dependent on whether fbc is available. v2: only check if num_pipes is valid Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/dce110/dc

[PATCH 5/5] drm/amdgpu/display/dce11: only enable FBC when selected

2018-11-06 Thread Alex Deucher
Causes a black screen on a Stoney laptop. bug: https://bugs.freedesktop.org/show_bug.cgi?id=108577 Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/dce110/d

[PATCH 3/5] drm/amdgpu/display/dc: add FBC to dc_config

2018-11-06 Thread Alex Deucher
Add FBC to the list of features that can be enabled from the DM. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/dc/dc.h | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h index 02db008fb78f..d16a20c84792 100

[PATCH 2/5] drm/amdgpu: add DC feature mask module parameter

2018-11-06 Thread Alex Deucher
Similar to ppfeaturemask. Allows you to selectively enable/disable DC features. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 11 +++ drivers/gpu/drm/amd/include/amd_shared.h | 4 3 files changed, 16 ins

[PATCH 4/5] drm/amdgpu/display/dm: handle FBC dc feature parameter

2018-11-06 Thread Alex Deucher
Set the dc_config properly when the option is enabled. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c i

[PATCH v6 4/5] drm/amdgpu: Correct get_crtc_scanoutpos behavior when vpos >= vtotal

2018-11-06 Thread Nicholas Kazlauskas
When variable refresh rate is active the hardware counter can return a position >= vtotal. This results in a vpos being returned from amdgpu_display_get_crtc_scanoutpos that's a positive value. The positive value indicates to the caller that the display is currently in scanout when the display is a

[PATCH v6 5/5] drm/amdgpu: Set FreeSync state using drm VRR properties

2018-11-06 Thread Nicholas Kazlauskas
Support for AMDGPU specific FreeSync properties and ioctls are dropped from amdgpu_dm in favor of supporting drm variable refresh rate properties. The notify_freesync and set_freesync_property functions are dropped from amdgpu_display_funcs. The drm vrr_capable property is now attached to any DP/

[PATCH v6 0/5] A DRM API for adaptive sync and variable refresh rate support

2018-11-06 Thread Nicholas Kazlauskas
These patches are part of a proposed new interface for supporting variable refresh rate via DRM properties. === Changes from v5 === drm changes: * Updated documentation to define userspace expectations when variable refresh rate is enabled amd changes: * Added patch to fix vblank timestamp c

[PATCH v6 3/5] drm: Document variable refresh properties

2018-11-06 Thread Nicholas Kazlauskas
These include the drm_connector 'vrr_capable' and the drm_crtc 'vrr_enabled' properties. Signed-off-by: Nicholas Kazlauskas Cc: Harry Wentland Cc: Manasi Navare Cc: Pekka Paalanen Cc: Ville Syrjälä Cc: Michel Dänzer --- Documentation/gpu/drm-kms.rst | 7 drivers/gpu/drm/drm_connecto

[PATCH v6 1/5] drm: Add vrr_capable property to the drm connector

2018-11-06 Thread Nicholas Kazlauskas
Modern display hardware is capable of supporting variable refresh rates. This patch introduces the "vrr_capable" property on the connector to allow userspace to query support for variable refresh rates. Atomic drivers should attach this property to connectors that are capable of driving variable r

[PATCH v6 2/5] drm: Add vrr_enabled property to drm CRTC

2018-11-06 Thread Nicholas Kazlauskas
This patch introduces the 'vrr_enabled' CRTC property to allow dynamic control over variable refresh rate support for a CRTC. This property should be treated like a content hint to the driver - if the hardware or driver is not capable of driving variable refresh timings then this is not considered

Re: [PATCH] drm/amdgpu/vega20: add CLK base offset

2018-11-06 Thread Wentland, Harry
On 2018-11-06 11:24 a.m., Alex Deucher wrote: > In case we need to access CLK registers. > > Signed-off-by: Alex Deucher Acked-by: Harry Wentland Harry > --- > drivers/gpu/drm/amd/amdgpu/vega20_reg_init.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/gpu/drm/amd/amdgpu/ve

Re: [PATCH] drm/amd: Don't fail on backlight = 0

2018-11-06 Thread Wentland, Harry
On 2018-11-06 11:14 a.m., David Francis wrote: > Amgpu's backlight update status function was > returning 1 (an error value) when the backlight > property was 0. This breaks users that assume > 0 is a valid backlight value (which is a > correct assumption) > > If the user passes in a backlight va

[PATCH] drm/amdgpu/vega20: add CLK base offset

2018-11-06 Thread Alex Deucher
In case we need to access CLK registers. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/vega20_reg_init.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/vega20_reg_init.c b/drivers/gpu/drm/amd/amdgpu/vega20_reg_init.c index 2d4473557b0d..d13fc4fcb517

Re: [PATCH] drm/amd: Don't fail on backlight = 0

2018-11-06 Thread Deucher, Alexander
Acked-by: Alex Deucher From: amd-gfx on behalf of David Francis Sent: Tuesday, November 6, 2018 11:14:46 AM To: amd-gfx@lists.freedesktop.org Cc: Francis, David; samant...@posteo.net; Wentland, Harry; Guttula, Suresh Subject: [PATCH] drm/amd: Don't fail on back

[PATCH] drm/amd: Don't fail on backlight = 0

2018-11-06 Thread David Francis
Amgpu's backlight update status function was returning 1 (an error value) when the backlight property was 0. This breaks users that assume 0 is a valid backlight value (which is a correct assumption) If the user passes in a backlight value of 0, tell them everything is fine, then write a value of

Re: [PATCH] drm/ttm: Fix bo_global and mem_global kfree error

2018-11-06 Thread Christian König
Am 06.11.18 um 12:54 schrieb Trigger Huang: ttm_bo_glob and ttm_mem_glob are defined as structure instance, while not allocated by kzalloc, so kfree should not be invoked to release them anymore. Otherwise, it will cause the following kernel BUG when unloading amdgpu module [ 48.419294] kernel

[PATCH] drm/ttm: Fix bo_global and mem_global kfree error

2018-11-06 Thread Trigger Huang
ttm_bo_glob and ttm_mem_glob are defined as structure instance, while not allocated by kzalloc, so kfree should not be invoked to release them anymore. Otherwise, it will cause the following kernel BUG when unloading amdgpu module [ 48.419294] kernel BUG at /build/linux-5s7Xkn/linux-4.15.0/mm/sl

Re: [PATCH libdrm 5/5] [libdrm] add syncobj timeline tests

2018-11-06 Thread Daniel Vetter
On Mon, Nov 05, 2018 at 10:07:24AM +, Zhou, David(ChunMing) wrote: > > > > -Original Message- > > From: Daniel Vetter On Behalf Of Daniel Vetter > > Sent: Monday, November 05, 2018 5:39 PM > > To: Zhou, David(ChunMing) > > Cc: dri-de...@lists.freedesktop.org; amd-gfx@lists.freedeskt