RE: [PATCH] drm/amd/swsmu: Add missing feature map for sienna_cichlid

2020-10-15 Thread Gao, Likun
[AMD Official Use Only - Internal Distribution Only] Reviewed-by: Likun Gao Regards, Likun -Original Message- From: Wang, Kevin(Yang) Sent: Friday, October 16, 2020 11:20 AM To: amd-gfx@lists.freedesktop.org Cc: Feng, Kenneth ; Gao, Likun ; Wang, Kevin(Yang) Subject: [PATCH]

[PATCH 32/40] drm/amd/pm: correct clk/voltage dependence setup

2020-10-15 Thread Evan Quan
Correct Polaris10 clk/voltage dependence setup. Change-Id: I3f73782c8933f50778040c5cf3946134d9378ade Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/smumgr/polaris10_smumgr.c | 2 ++ 1 file changed, 2 insertions(+) diff --git

[PATCH 27/40] drm/amd/pm: correct VRconfig setting

2020-10-15 Thread Evan Quan
Correct Polaris VRconfig setting. Change-Id: I8cf3151c04f130ff25fb12b6e4bf994cba2bd91e Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../amd/pm/powerplay/smumgr/polaris10_smumgr.c| 15 ++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git

[PATCH 35/40] drm/amd/pm: correct vddc_dep_on_dal_pwrl setup

2020-10-15 Thread Evan Quan
Correct Polaris10 setup. Change-Id: Ia97b0995320ea06264b2b382331ff0b54b801665 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../drm/amd/pm/powerplay/hwmgr/smu_helper.c| 18 +++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git

[PATCH 39/40] drm/amd/pm: reconfigure smc on display vbitimeout setting change

2020-10-15 Thread Evan Quan
Reconfigure smc display settings on vbitimeout change. Change-Id: Ia026f6585954ce4e7f6bbd2e270a201f9c3fe25b Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 6 ++ drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.h | 1 + 2 files

[PATCH 38/40] drm/amd/pm: correct the mclk switching setting

2020-10-15 Thread Evan Quan
Correct the mclk switching setting for multiple displays. Change-Id: Ibec856430ef9f0d0a9dee7dc5142c3591f83366b Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 113 +++--- .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.h | 12 ++ 2

[PATCH 33/40] drm/amd/pm: correct pcie spc cap setup

2020-10-15 Thread Evan Quan
Correct Polaris10 pcie spc cap setting. Change-Id: I7f9a65cd615c43a62a38713a07290e3ec5afaef1 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 2 ++ 1 file changed, 2 insertions(+) diff --git

[PATCH 40/40] drm/amd/pm: drop redundant display setting

2020-10-15 Thread Evan Quan
As this is already performed in smu7_set_power_state_tasks(). Change-Id: I2b44e9f872c9b7ce7b38df4b97139c1f293efaf0 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 12 1 file changed, 12 deletions(-) diff --git

[PATCH 31/40] drm/amd/pm: correct the way to get the highest vddc

2020-10-15 Thread Evan Quan
Populate the correct highest vddc setting on Polaris. Change-Id: Iabbfa11ddd44352610d71079bdeccc2540253365 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 30 +-- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git

[PATCH 29/40] drm/amd/pm: correct smc voltage controller setup

2020-10-15 Thread Evan Quan
Correct Polaris10 smc voltage controller setup. Change-Id: I819b0b9648074f1af5af6ea285972ec3b3f693d8 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

[PATCH 36/40] drm/amd/pm: fulfill the Polaris implementation for get_clock_by_type_with_latency()

2020-10-15 Thread Evan Quan
Fulfill Polaris get_clock_by_type_with_latency(). Change-Id: I143959f9fcb218a74aabb2fbf6cd6c7b2f0716f1 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 67 +++ 1 file changed, 67 insertions(+) diff --git

[PATCH 34/40] drm/amd/pm: correct SMC sclk/mclk boot level setup

2020-10-15 Thread Evan Quan
Correct Polaris smc boot level setup. Change-Id: I0bb1cd916f65763ab6e8bb4a401508a3adbf8d2d Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../gpu/drm/amd/pm/powerplay/smumgr/polaris10_smumgr.c| 8 1 file changed, 8 insertions(+) diff --git

[PATCH 37/40] drm/amd/pm: enable Polaris watermark table setting

2020-10-15 Thread Evan Quan
Enable watermark table setting for Polaris. Change-Id: I395b74f2ce5b74e6d1c7659816ee386ba556e14c Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 11 +++- .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 50 +++ 2 files changed,

[PATCH 28/40] drm/amd/pm: correct platformcaps setup

2020-10-15 Thread Evan Quan
Correct Polaris10 platformcaps setup. Change-Id: I59f305fa072585f0df7314bda4cdd0ef083307ff Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/hwmgr.c| 5 +++-- drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 11 +++

[PATCH 30/40] drm/amd/pm: correct sclk/mclk dpm enablement

2020-10-15 Thread Evan Quan
Correct Polaris10 sclk/mclk dpm enablement. Change-Id: I629ed96cbf88230179f26ff77f9cd95e485b9539 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 9 +++-- .../gpu/drm/amd/pm/powerplay/smumgr/polaris10_smumgr.c | 3 ++- 2 files

[PATCH 22/40] drm/amd/pm: correct the checks for sclk/mclk SS support

2020-10-15 Thread Evan Quan
Correct sclk/mclk SS support checks. Change-Id: Ic3842b06aa632d5bfcee09a2119dbbb74d0f008a Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/hwmgr.c | 5 + drivers/gpu/drm/amd/pm/powerplay/hwmgr/ppatomctrl.c | 13 -

[PATCH 15/40] drm/amd/pm: drop redundant efuse mask calculations

2020-10-15 Thread Evan Quan
By moving that in atomfw_read_efuse(). Change-Id: I532e2a5095d6cf533c93ee4382f1434a5265f802 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/ppatomctrl.c| 8 +++- drivers/gpu/drm/amd/pm/powerplay/hwmgr/ppatomctrl.h| 2 +-

[PATCH 16/40] drm/amd/pm: correct the settings for ro range minimum and maximum

2020-10-15 Thread Evan Quan
Make the settings more precise. Change-Id: I0d1aa32fec21824591e58841a5c7f17b35ddb720 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 62 +++ .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.h | 3 + 2 files changed, 65

[PATCH 04/40] drm/amd/pm: correct vddci table setup

2020-10-15 Thread Evan Quan
Make sure the settings are applied only when voltage controlled by gpio. Change-Id: I31edfb731ebfeb35e87d130633d29714f84d76cb Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/smumgr/polaris10_smumgr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)

[PATCH 10/40] drm/amd/pm: drop arb table first byte workaround

2020-10-15 Thread Evan Quan
As this is not needed for polaris. Change-Id: I837f480622fb63c333c04cc68e449447fd7e3fa6 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../pm/powerplay/smumgr/polaris10_smumgr.c| 31 --- 1 file changed, 31 deletions(-) diff --git

[PATCH 13/40] drm/amd/powerplay: separate Polaris fan table setup from Tonga

2020-10-15 Thread Evan Quan
Instead of sharing the fan table setup with Tonga, Polaris has its own fan table setup. Change-Id: Ib6f69b9d1dbea30b480dbe0932ac073c1aa303b2 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../drm/amd/pm/powerplay/hwmgr/pptable_v1_0.h | 30 ++

[PATCH 25/40] drm/amd/pm: correct avfs fuse settings

2020-10-15 Thread Evan Quan
Correct Polaris10 avfs fuse setting. Change-Id: Ia6db6bb1d67cbf5355fcbd07ccd5e3fb6bbd2226 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../pm/powerplay/smumgr/polaris10_smumgr.c| 55 --- 1 file changed, 23 insertions(+), 32 deletions(-) diff --git

[PATCH 14/40] drm/amd/pm: optimize AC timing programming

2020-10-15 Thread Evan Quan
Programming AC Timing Parameters is only dependent on MCLK. No need to nest loop for each SCLK DPM level. Change-Id: Ib6b84f758553b804a75b8ac64541d673fc090efb Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/smumgr/polaris10_smumgr.c | 2 +- 1 file changed,

[PATCH 06/40] drm/amd/pm: correct mclk table setup

2020-10-15 Thread Evan Quan
Correct the settings for "StutterEnable" and "EnabledForActivity". Change-Id: Iad8c825d524497ece4e6234575db01ce1af1abb4 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../pm/powerplay/smumgr/polaris10_smumgr.c| 20 --- 1 file changed, 8 insertions(+), 12 deletions(-)

[PATCH 18/40] drm/amd/pm: setup zero rpm parameters for polaris10

2020-10-15 Thread Evan Quan
Only if the ZeroRPM feature is supported. Change-Id: I68f1960c5c65ff176f4945a4248082f1934d7cac Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/inc/smu7_ppsmc.h | 1 + .../drm/amd/pm/powerplay/hwmgr/smu7_thermal.c | 11 +++

[PATCH 20/40] drm/amd/pm: add mc register table initialization

2020-10-15 Thread Evan Quan
Add mc register table initialization. Change-Id: I38a17c2f2747e5ef736c5dc55a84ee4e34d114b8 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../drm/amd/pm/powerplay/hwmgr/ppatomctrl.c | 37 +++ .../drm/amd/pm/powerplay/hwmgr/ppatomctrl.h | 1 +

[PATCH 26/40] drm/amd/pm: correct vddc phase control setting

2020-10-15 Thread Evan Quan
Correct Polaris10 vddc phase control. Change-Id: I182bc46adb7900cad243eb3906450d86ae41975e Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 31 +++ .../pm/powerplay/smumgr/polaris10_smumgr.c| 7 - 2 files changed, 24

[PATCH 12/40] drm/amd/pm: add PWR_CKS_CNTL setting

2020-10-15 Thread Evan Quan
This is for some special Polaris10 ASICs. Change-Id: I4d949d32de0f66f4b34c8aaac1b95f7c5288b121 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git

[PATCH 00/40] Various Polaris fixes and optimizations

2020-10-15 Thread Evan Quan
The fixes and optimizations include: - Enable zero rpm fan feature - Reduce the idle power for multiple displays setup - Fix screen flicker issue seen on some mutiple displays setup - Enable mclk switch for multiple synced displays - Other alignments with Windows Evan Quan (40): drm/amd/pm:

[PATCH 08/40] drm/amd/pm: correct the BootLinkLevel setup

2020-10-15 Thread Evan Quan
Set the BootLinkLevel as the max level. Change-Id: I5fde6b472c9d802420be5783fd93f589404e66eb Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/smumgr/polaris10_smumgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH 17/40] drm/amd/pm: correct polaris10 clock stretcher data table setting

2020-10-15 Thread Evan Quan
By using the saved copy of ro_range_maximum and ro_range_minimum. Correct the setting for "LdoRefSel". Change-Id: Ic6a842739bfba88c90c23bb712da688c8234a635 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../pm/powerplay/smumgr/polaris10_smumgr.c| 42 +-- 1 file

[PATCH 03/40] drm/amd/pm: populate smc samu table

2020-10-15 Thread Evan Quan
Add missing smc samu table setup. Change-Id: I28c49330121b17fb3a03ec5b76f3b87effe92ecf Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../pm/powerplay/smumgr/polaris10_smumgr.c| 53 +++ 1 file changed, 53 insertions(+) diff --git

[PATCH 19/40] drm/amd/pm: add edc leakage controller setting

2020-10-15 Thread Evan Quan
Enable edc controller table setting. Change-Id: I38a1873b94f95c3ea8cfdca626bea3f30657bc31 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/include/atombios.h| 16 ++ drivers/gpu/drm/amd/pm/inc/smu7_ppsmc.h | 3 +

[PATCH 21/40] drm/amd/pm: correct VR shared rail info

2020-10-15 Thread Evan Quan
Add VR shared rail info. Change-Id: I6ea756c42586c10543489dbdf558ce88c2416e1c Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/include/atombios.h | 4 +++- drivers/gpu/drm/amd/pm/inc/smu74_discrete.h| 3 ++-

[PATCH 02/40] drm/amd/pm: populate smc vddc table

2020-10-15 Thread Evan Quan
Add missing vddc table setup. Change-Id: Ia104bb685040f9779274b2dacda5a4744067d3af Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../pm/powerplay/smumgr/polaris10_smumgr.c| 26 +++ 1 file changed, 26 insertions(+) diff --git

[PATCH 24/40] drm/amd/pm: correct Polaris DIDT configurations

2020-10-15 Thread Evan Quan
Correct Polaris DIDT enablement. Change-Id: I8e0033aef8cb0ab005b59517241338ecdf6f3817 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/inc/smu7_ppsmc.h | 2 ++ .../amd/pm/powerplay/hwmgr/smu7_powertune.c | 34 +-- 2 files changed, 34

[PATCH 05/40] drm/amd/pm: correct sclk table setup

2020-10-15 Thread Evan Quan
Correct Polaris10 sclk table setup. Change-Id: I1685f3608b7113f7e9713c343ca33b8676693707 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- .../pm/powerplay/smumgr/polaris10_smumgr.c| 23 +-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git

[PATCH 07/40] drm/amd/pm: correct the ACPI table setup V2

2020-10-15 Thread Evan Quan
Correct the setting for "ActivityLevel". V2: rich the comment Change-Id: I4a166dbabdb41938705fe24801aeced6d892e985 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/smumgr/polaris10_smumgr.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

[PATCH 11/40] drm/amdgpu: correct CG_ACLK_CNTL setting

2020-10-15 Thread Evan Quan
Correct polaris CG_ACLK_CNTL setting. Change-Id: I7d384ce65d598ae33325c09c571bdc7865c36fdc Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 14 +++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git

[PATCH 23/40] drm/amd/pm: correct Polaris powertune table setup

2020-10-15 Thread Evan Quan
Correct powertune table setup for Polaris. Change-Id: I31fa01c5e5f88233616e51966b4fb5a161e35ff0 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/inc/hwmgr.h| 1 + .../drm/amd/pm/powerplay/hwmgr/pptable_v1_0.h | 36 ++

[PATCH 01/40] drm/amd/pm: correct the checks for polaris kickers

2020-10-15 Thread Evan Quan
By defining new Macros. Change-Id: I4f7233ea27e59b61c29c52798a179abbf224fe12 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 39 + drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 34 -

[PATCH 09/40] drm/amd/pm: add pptable VRHotLevel setting

2020-10-15 Thread Evan Quan
Add missing VRHotLevel setting. Change-Id: I5d70599f49469f920e01d38791fbe6466a4f47b2 Signed-off-by: Evan Quan Acked-by: Alex Deucher --- drivers/gpu/drm/amd/pm/powerplay/smumgr/polaris10_smumgr.c | 3 +++ 1 file changed, 3 insertions(+) diff --git

[PATCH] drm/amd/swsmu: Add missing feature map for sienna_cichlid

2020-10-15 Thread Kevin Wang
it will cause smu sysfs node of "pp_features" show error. Signed-off-by: Kevin Wang --- drivers/gpu/drm/amd/pm/inc/smu_types.h | 1 + drivers/gpu/drm/amd/pm/swsmu/smu11/sienna_cichlid_ppt.c | 3 +++ 2 files changed, 4 insertions(+) diff --git

Re: [PATCH 2/2] drm/amd/display: Avoid MST manager resource leak.

2020-10-15 Thread Alex Deucher
On Wed, Oct 14, 2020 at 1:25 PM Andrey Grodzovsky wrote: > > On connector destruction call drm_dp_mst_topology_mgr_destroy > to release resources allocated in drm_dp_mst_topology_mgr_init. > Do it only if MST manager was initialized before otherwsie a crash > is seen on driver unload/device

RE: [PATCH 1/2] drm:amdgpu: check before setting hw priority

2020-10-15 Thread Liu, Aaron
[AMD Public Use] Series is: Tested-by: Aaron Liu -- Best Regards Aaron Liu -Original Message- From: Das, Nirmoy Sent: Wednesday, October 14, 2020 9:53 PM To: amd-gfx@lists.freedesktop.org Cc: Deucher, Alexander ; Koenig, Christian ; Chen, Guchun ; Liu, Aaron ; Das, Nirmoy Subject:

Re: [PATCH 2/2] drm/amd/display: Avoid MST manager resource leak.

2020-10-15 Thread Grodzovsky, Andrey
Ping for both patches. Andrey From: Andrey Grodzovsky Sent: 14 October 2020 13:24 To: amd-gfx@lists.freedesktop.org Cc: Kazlauskas, Nicholas ; Wentland, Harry ; Pan, Xinhui ; Grodzovsky, Andrey Subject: [PATCH 2/2] drm/amd/display: Avoid MST manager resource

Re: [PATCH] drm/amd/display: Fix incorrect dsc force enable logic

2020-10-15 Thread Harry Wentland
On 2020-10-15 3:40 p.m., Eryk Brol wrote: [Why] Missed removing a '!' which results in incorrect behavior [How] Remove the offending '!' Signed-off-by: Eryk Brol Reviewed-by: Harry Wentland Harry --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c | 2 +- 1 file changed,

[PATCH] drm/amd/display: Fix incorrect dsc force enable logic

2020-10-15 Thread Eryk Brol
[Why] Missed removing a '!' which results in incorrect behavior [How] Remove the offending '!' Signed-off-by: Eryk Brol --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH 2/2] drm/amd/display: Fix DCN302 makefile

2020-10-15 Thread Deucher, Alexander
[AMD Public Use] Series is: Reviewed-by: Alex Deucher From: Bhawanpreet Lakha Sent: Thursday, October 15, 2020 2:20 PM To: Kazlauskas, Nicholas ; Deucher, Alexander Cc: rodrigo.siqofue...@amd.com ; amd-gfx@lists.freedesktop.org ; Lakha, Bhawanpreet Subject:

[PATCH 1/2] drm/amd/display: Use amdgpu_socbb.h instead of redefining structs

2020-10-15 Thread Bhawanpreet Lakha
Signed-off-by: Bhawanpreet Lakha --- .../amd/display/dc/dcn302/dcn302_resource.c | 58 +-- 1 file changed, 1 insertion(+), 57 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/dcn302/dcn302_resource.c b/drivers/gpu/drm/amd/display/dc/dcn302/dcn302_resource.c index

[PATCH 2/2] drm/amd/display: Fix DCN302 makefile

2020-10-15 Thread Bhawanpreet Lakha
Some setups will fail to build. So copy dcn301 makefile setup which is known to work Signed-off-by: Bhawanpreet Lakha --- .../gpu/drm/amd/display/dc/dcn302/Makefile| 29 +++ 1 file changed, 29 insertions(+) diff --git a/drivers/gpu/drm/amd/display/dc/dcn302/Makefile

Re: [PATCH 2/2] drm/amdgpu: nuke amdgpu_vm_bo_split_mapping

2020-10-15 Thread Luben Tuikov
On 2020-10-15 03:04, Christian König wrote: >>> >>> + pfn = offset >> PAGE_SHIFT; >>> + if (nodes) { >>> + while (pfn >= nodes->size) { >>> + pfn -= nodes->size; >>> + ++nodes; >>> + } >>> + } >>> + >> I believe here you can just do:

Re: [PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-15 Thread Thomas Zimmermann
Hi On Thu, 15 Oct 2020 16:08:13 +0200 Christian König wrote: > Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: > > The new functions ttm_bo_{vmap,vunmap}() map and unmap a TTM BO in kernel > > address space. The mapping's address is returned as struct dma_buf_map. > > Each function is a

Re: [PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-15 Thread Thomas Zimmermann
Hi On Thu, 15 Oct 2020 18:49:09 +0200 Daniel Vetter wrote: > On Thu, Oct 15, 2020 at 04:08:13PM +0200, Christian König wrote: > > Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: > > > The new functions ttm_bo_{vmap,vunmap}() map and unmap a TTM BO in > > > kernel address space. The mapping's

Re: [PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-15 Thread Daniel Vetter
On Thu, Oct 15, 2020 at 04:08:13PM +0200, Christian König wrote: > Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: > > The new functions ttm_bo_{vmap,vunmap}() map and unmap a TTM BO in kernel > > address space. The mapping's address is returned as struct dma_buf_map. > > Each function is a

Re: [PATCH 2/2] drm/amdgpu: introduce a new parameter to configure how many KCQ we want(v5)

2020-10-15 Thread Marek Olšák
Monk or perhaps Felix, Do you by any chance know why the CS ioctl returns -EINVAL for all compute submissions if num_kcq <= 4 and what could cause that? If not, is there any way to disable mid-IB preemption for compute? Thanks, Marek On Fri, Jul 31, 2020 at 9:53 AM Felix Kuehling wrote: > Am

Renoir: visual artifacts associated with scrolling

2020-10-15 Thread Dirk Gouders
I am dealing with visual artifacts on my laptop. I'm not sure if screendumps are OK on this list so I will try to describe the two vulnerable applications I identified so far. Both of them can be healed by forcing a full redraws (changing workspace back and forth, minimizing and maximizing

Re: [PATCH v3] drm/amd/amdgpu: set the default value of noretry to 1 for some dGPUs

2020-10-15 Thread Felix Kuehling
Am 2020-10-14 um 11:35 p.m. schrieb Chengming Gui: > noretry = 0 cause some dGPU's kfd page fault tests fail, > so set noretry to 1 for these special ASICs: > vega20/navi10/navi14/ARCTURUS > > v2: merge raven and default case due to the same setting > v3: remove ARCTURUS > > Signed-off-by:

Re: [PATCH v4 06/10] drm/gem: Use struct dma_buf_map in GEM vmap ops and convert GEM backends

2020-10-15 Thread Christian König
Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: This patch replaces the vmap/vunmap's use of raw pointers in GEM object functions with instances of struct dma_buf_map. GEM backends are converted as well. For most of them, this simply changes the returned type. TTM-based drivers now return

Re: [PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-15 Thread Christian König
Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: The new functions ttm_bo_{vmap,vunmap}() map and unmap a TTM BO in kernel address space. The mapping's address is returned as struct dma_buf_map. Each function is a simplified version of TTM's existing kmap code. Both functions respect the memory's

Re: [PATCH v4 04/10] drm/exynos: Remove empty exynos_drm_gem_prime_{vmap,vunmap}()

2020-10-15 Thread Christian König
Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: The functions exynos_drm_gem_prime_{vmap,vunmap}() are empty. Remove them before changing the interface to use struct drm_buf_map. As a side effect of removing drm_gem_prime_vmap(), the error code changes from ENOMEM to EOPNOTSUPP. Signed-off-by:

Re: [PATCH v4 03/10] drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap()

2020-10-15 Thread Christian König
Am 15.10.20 um 14:37 schrieb Thomas Zimmermann: The function etnaviv_gem_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann Acked-by: Christian König --- drivers/gpu/drm/etnaviv/etnaviv_drv.h | 1 -

Re: [PATCH v4 02/10] drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap()

2020-10-15 Thread Christian König
Am 15.10.20 um 14:37 schrieb Thomas Zimmermann: The function drm_gem_cma_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Christian König --- drivers/gpu/drm/drm_gem_cma_helper.c | 17

Re: [PATCH v4 01/10] drm/vram-helper: Remove invariant parameters from internal kmap function

2020-10-15 Thread Christian König
Am 15.10.20 um 14:37 schrieb Thomas Zimmermann: The parameters map and is_iomem are always of the same value. Removed them to prepares the function for conversion to struct dma_buf_map. v4: * don't check for !kmap->virtual; will always be false Signed-off-by: Thomas Zimmermann

Re: [PATCH 2/2] drm/amdgpu/display: enable display ip block for vangogh

2020-10-15 Thread Deucher, Alexander
[AMD Official Use Only - Internal Distribution Only] Series is: Reviewed-by: Alex Deucher From: Huang, Ray Sent: Thursday, October 15, 2020 4:28 AM To: amd-gfx@lists.freedesktop.org Cc: Wentland, Harry ; Li, Roman ; Deucher, Alexander ; Huang, Ray Subject:

RE: [PATCH] drm/amdgpu: remove gfxhub_v1_1_funcs set

2020-10-15 Thread Zhang, Hawking
[AMD Public Use] Reviewed-by: Hawking Zhang Regards, Hawking -Original Message- From: Wang, Kevin(Yang) Sent: Thursday, October 15, 2020 11:25 To: amd-gfx@lists.freedesktop.org Cc: Zhang, Hawking ; Wang, Kevin(Yang) Subject: [PATCH] drm/amdgpu: remove gfxhub_v1_1_funcs set remove

Re: [PATCH] drm/amdgpu: update golden setting for sienna_cichlid

2020-10-15 Thread Deucher, Alexander
[AMD Public Use] Acked-by: Alex Deucher From: amd-gfx on behalf of Likun Gao Sent: Wednesday, October 14, 2020 10:57 PM To: amd-gfx@lists.freedesktop.org Cc: Gao, Likun ; Zhang, Hawking Subject: [PATCH] drm/amdgpu: update golden setting for sienna_cichlid

[PATCH v4 09/10] dma-buf-map: Add memcpy and pointer-increment interfaces

2020-10-15 Thread Thomas Zimmermann
To do framebuffer updates, one needs memcpy from system memory and a pointer-increment function. Add both interfaces with documentation. Signed-off-by: Thomas Zimmermann --- include/linux/dma-buf-map.h | 72 +++-- 1 file changed, 62 insertions(+), 10 deletions(-)

[PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-15 Thread Thomas Zimmermann
The new functions ttm_bo_{vmap,vunmap}() map and unmap a TTM BO in kernel address space. The mapping's address is returned as struct dma_buf_map. Each function is a simplified version of TTM's existing kmap code. Both functions respect the memory's location ani/or writecombine flags. On top TTM's

[PATCH v4 03/10] drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap()

2020-10-15 Thread Thomas Zimmermann
The function etnaviv_gem_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/etnaviv/etnaviv_drv.h | 1 - drivers/gpu/drm/etnaviv/etnaviv_gem.c | 1 -

[PATCH v4 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-10-15 Thread Thomas Zimmermann
At least sparc64 requires I/O-specific access to framebuffers. This patch updates the fbdev console accordingly. For drivers with direct access to the framebuffer memory, the callback functions in struct fb_ops test for the type of memory and call the rsp fb_sys_ of fb_cfb_ functions. For

[PATCH v4 04/10] drm/exynos: Remove empty exynos_drm_gem_prime_{vmap, vunmap}()

2020-10-15 Thread Thomas Zimmermann
The functions exynos_drm_gem_prime_{vmap,vunmap}() are empty. Remove them before changing the interface to use struct drm_buf_map. As a side effect of removing drm_gem_prime_vmap(), the error code changes from ENOMEM to EOPNOTSUPP. Signed-off-by: Thomas Zimmermann ---

[PATCH v4 06/10] drm/gem: Use struct dma_buf_map in GEM vmap ops and convert GEM backends

2020-10-15 Thread Thomas Zimmermann
This patch replaces the vmap/vunmap's use of raw pointers in GEM object functions with instances of struct dma_buf_map. GEM backends are converted as well. For most of them, this simply changes the returned type. TTM-based drivers now return information about the location of the memory, either

[PATCH v4 07/10] drm/gem: Update internal GEM vmap/vunmap interfaces to use struct dma_buf_map

2020-10-15 Thread Thomas Zimmermann
GEM's vmap and vunmap interfaces now wrap memory pointers in struct dma_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter --- drivers/gpu/drm/drm_client.c | 18 +++--- drivers/gpu/drm/drm_gem.c | 26 +-

[PATCH v4 08/10] drm/gem: Store client buffer mappings as struct dma_buf_map

2020-10-15 Thread Thomas Zimmermann
Kernel DRM clients now store their framebuffer address in an instance of struct dma_buf_map. Depending on the buffer's location, the address refers to system or I/O memory. Callers of drm_client_buffer_vmap() receive a copy of the value in the call's supplied arguments. It can be accessed and

[PATCH v4 02/10] drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap()

2020-10-15 Thread Thomas Zimmermann
The function drm_gem_cma_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/drm_gem_cma_helper.c | 17 - drivers/gpu/drm/vc4/vc4_bo.c | 1 - include/drm/drm_gem_cma_helper.h

[PATCH v4 00/10] Support GEM object mappings from I/O memory

2020-10-15 Thread Thomas Zimmermann
DRM's fbdev console uses regular load and store operations to update framebuffer memory. The bochs driver on sparc64 requires the use of I/O-specific load and store operations. We have a workaround, but need a long-term solution to the problem. This patchset changes GEM's vmap/vunmap interfaces

[PATCH v4 01/10] drm/vram-helper: Remove invariant parameters from internal kmap function

2020-10-15 Thread Thomas Zimmermann
The parameters map and is_iomem are always of the same value. Removed them to prepares the function for conversion to struct dma_buf_map. v4: * don't check for !kmap->virtual; will always be false Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter ---

RE: [PATCH] drm/amdgpu: correct the gpu reset handling for job != NULL case

2020-10-15 Thread Jian, Jane
[AMD Official Use Only - Internal Distribution Only] Reviewed-by: Jane Jian -Original Message- From: Quan, Evan Sent: Thursday, October 15, 2020 3:03 PM To: amd-gfx@lists.freedesktop.org Cc: Deucher, Alexander ; Jian, Jane ; Quan, Evan Subject: [PATCH] drm/amdgpu: correct the gpu

[PATCH 1/2] drm/amdgpu/display: fix the NULL pointer reference on dmucb on dcn301

2020-10-15 Thread Huang Rui
DCN301 needs to use dmub create abm instance instead of dce. [ 1138.854204] BUG: kernel NULL pointer dereference, address: [ 1138.854206] #PF: supervisor instruction fetch in kernel mode [ 1138.854207] #PF: error_code(0x0010) - not-present page [ 1138.854208] PGD 0 P4D 0 [

[PATCH 2/2] drm/amdgpu/display: enable display ip block for vangogh

2020-10-15 Thread Huang Rui
This patch is to enable display IP block for vangogh platforms. Signed-off-by: Huang Rui --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 1 + drivers/gpu/drm/amd/amdgpu/nv.c| 4 2 files changed, 5 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

Re: [PATCH 2/2] drm/amdgpu: nuke amdgpu_vm_bo_split_mapping

2020-10-15 Thread Christian König
Am 14.10.20 um 22:48 schrieb Luben Tuikov: On 2020-10-13 13:08, Christian König wrote: Merge the functionality mostly into amdgpu_vm_bo_update_mapping. This way we can even handle small contiguous system pages without to much extra CPU overhead. Large contiguous allocations (1GB) still

[PATCH] drm/amdgpu: correct the gpu reset handling for job != NULL case

2020-10-15 Thread Evan Quan
Current code wrongly treat all cases as job == NULL. Change-Id: I3d686617bbe67bf64e8a6ff8cc5b0de11b80afb6 Signed-off-by: Evan Quan --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

Re: [PATCH] drm/amdgpu: protect eeprom update from GPU reset

2020-10-15 Thread Christian König
Looks like the right approach to me as well. Patch is Reviewed-by: Christian König . Regards, Christian. Am 14.10.20 um 13:44 schrieb Zhang, Hawking: [AMD Public Use] Thanks for the clarifying, Dennis. So this is kind of race condition between normal GPU reset and ras GPU reset. I 'm fine