[PATCH 07/10] drm/amdgpu: expose peak profiling mode shader/memory clocks

2022-12-08 Thread Evan Quan
Expose those informations to UMD who need them as for standard profiling mode. Signed-off-by: Evan Quan Change-Id: I7f60c17cb53846a73f43f0f847a32317f84b2861 --- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 18 ++ include/uapi/drm/amdgpu_drm.h | 4 2 files changed, 22

[PATCH 10/10] drm/amd/pm: update SMU13.0.0 reported maximum shader clock

2022-12-08 Thread Evan Quan
Update the reported maximum shader clock to the value which can be guarded to be achieved on all cards. This is to align with Window setting. Signed-off-by: Evan Quan Change-Id: I83da5ec931664af36ee6db3cb13ef655db54220e --- .../drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c | 70 ++-

[PATCH 09/10] drm/amdgpu: bump minor version number for DEV_INFO and SENSOR IOCTLs update

2022-12-08 Thread Evan Quan
Update AMDGPU_INFO_DEV_INFO IOCTL for minimum engine and memory clock. And update AMDGPU_INFO_SENSOR IOCTL for PEAK_PSTATE engine and memory clock. User applications can better utilize these IOCTLs to get needed informations. Increase the minor version number to indicate that the new flags are ava

[PATCH 08/10] drm/amdgpu: expose the minimum shader/memory clock frequency

2022-12-08 Thread Evan Quan
Otherwise, some UMD tools will treate them as 0 at default while actually they are not. Signed-off-by: Evan Quan Change-Id: I524a512eb538dba626edd6d2c73a370dd6a1b4a5 --- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 10 -- include/uapi/drm/amdgpu_drm.h | 2 ++ 2 files changed, 10

[PATCH 05/10] drm/amd/pm: fulfill swsmu peak profiling mode shader/memory clock settings

2022-12-08 Thread Evan Quan
Enable peak profiling mode shader/memory clocks reporting for swsmu framework. Signed-off-by: Evan Quan Change-Id: Iebefecc9addd7352a50baec571791edc8d968375 --- drivers/gpu/drm/amd/include/kgd_pp_interface.h | 2 ++ drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 8 2 files changed, 10

[PATCH 06/10] drm/amd/pm: fulfill powerplay peak profiling mode shader/memory clock settings

2022-12-08 Thread Evan Quan
Enable peak profiling mode shader/memory clock reporting for powerplay framework. Signed-off-by: Evan Quan Change-Id: Ied28f5921c3e72d86d8e769908910f1b11a0100b --- .../gpu/drm/amd/pm/powerplay/amd_powerplay.c | 10 ++- .../drm/amd/pm/powerplay/hwmgr/smu10_hwmgr.c | 16 +++- .../drm/amd/pm/powe

[PATCH 04/10] drm/amd/pm: drop unused SMU v13 API

2022-12-08 Thread Evan Quan
The API is not in use. And it's unlikely to be used in the future either. Signed-off-by: Evan Quan Change-Id: I7ace04dda5752d940fdd630e6b86879f748a3ac8 --- drivers/gpu/drm/amd/pm/swsmu/inc/smu_v13_0.h | 5 --- .../gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c| 39 --- 2 files chan

[PATCH 03/10] drm/amd/pm: correct SMU13.0.0 pstate profiling clock settings

2022-12-08 Thread Evan Quan
Correct the pstate standard/peak profiling mode clock settings for SMU13.0.0. Signed-off-by: Evan Quan Change-Id: Ic47b18904b1fa021588b6d4b599f1cf0fe4b7a58 --- .../drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c | 22 +-- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/d

[PATCH 01/10] drm/amd/pm: enable GPO dynamic control support for SMU13.0.0

2022-12-08 Thread Evan Quan
To better support UMD pstate profilings, the GPO feature needs to be switched on/off accordingly. Signed-off-by: Evan Quan Change-Id: I162139a9e1ecac0a75d0fc3f93f608bf2223ac8c --- drivers/gpu/drm/amd/pm/swsmu/inc/smu_types.h | 3 ++- drivers/gpu/drm/amd/pm/swsmu/inc/smu_v13_0.h | 3 +

[PATCH 02/10] drm/amd/pm: enable GPO dynamic control support for SMU13.0.7

2022-12-08 Thread Evan Quan
To better support UMD pstate profilings, the GPO feature needs to be switched on/off accordingly. Signed-off-by: Evan Quan Change-Id: Ia0236c05d507b6c253fd558482c665528aa0ceb8 --- drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/g

RE: [PATCH] drm/amdgpu: handle polaris10/11 overlap asics (v2)

2022-12-08 Thread Quan, Evan
[AMD Official Use Only - General] Reviewed-by: Evan Quan > -Original Message- > From: amd-gfx On Behalf Of Alex > Deucher > Sent: Thursday, December 8, 2022 1:06 AM > To: amd-gfx@lists.freedesktop.org > Cc: Deucher, Alexander > Subject: [PATCH] drm/amdgpu: handle polaris10/11 overlap a

Re: [PATCH] drm/display: Include missing DPCD definitions from DP2.0 spec

2022-12-08 Thread Alex Deucher
+ dri-devel On Thu, Dec 8, 2022 at 2:25 PM Sung Joon Kim wrote: > > The missing DPCD defintions from DP2.0 spec is as follows: > > DOWNSPREAD_CTRL (107h): > ADAPTIVE_SYNC_SDP_EN (bit 6) > For sink devices that support Adaptive-Sync operation > and Panel Rep

[PATCH] drm/display: Include missing DPCD definitions from DP2.0 spec

2022-12-08 Thread Sung Joon Kim
The missing DPCD defintions from DP2.0 spec is as follows: DOWNSPREAD_CTRL (107h): ADAPTIVE_SYNC_SDP_EN (bit 6) For sink devices that support Adaptive-Sync operation and Panel Replay DPRX_FEATURE_ENUMERATION_LIST_CONT_1 (2214h): ADAPTIVE_SYNC_SDP_SU

Re: Another circular lock dependency involving fs-reclaim and drm_buddy

2022-12-08 Thread Felix Kuehling
Am 2022-12-08 um 12:39 schrieb Christian König: Am 08.12.22 um 17:28 schrieb Felix Kuehling: Am 2022-12-08 um 10:44 schrieb Christian König: Am 08.12.22 um 16:19 schrieb Felix Kuehling: Am 2022-12-08 um 07:32 schrieb Christian König: Hi Felix, digging though the code I think I know now how w

Re: [PATCH v3 1/3] ACPI: video: Allow GPU drivers to report no panels

2022-12-08 Thread Limonciello, Mario
On 12/8/2022 11:49, Daniel Dadap wrote: On Thu, Dec 08, 2022 at 10:42:05AM -0600, Mario Limonciello wrote: The current logic for the ACPI backlight detection will create a backlight device if no native or vendor drivers have created 8 seconds after the system has booted if the ACPI tables includ

Re: [PATCH v3 1/3] ACPI: video: Allow GPU drivers to report no panels

2022-12-08 Thread Daniel Dadap
On Thu, Dec 08, 2022 at 10:42:05AM -0600, Mario Limonciello wrote: > The current logic for the ACPI backlight detection will create > a backlight device if no native or vendor drivers have created > 8 seconds after the system has booted if the ACPI tables > included backlight control methods. > >

Re: [PATCH] drm/amdgpu: Retry DDC probing on DVI on failure if we got an HPD interrupt

2022-12-08 Thread Alex Deucher
On Wed, Dec 7, 2022 at 3:09 AM xurui wrote: > > HPD signals on DVI ports can be fired off before the pins required for > DDC probing actually make contact, due to the pins for HPD making > contact first. This results in a HPD signal being asserted but DDC > probing failing, resulting in hotpluggin

Re: Another circular lock dependency involving fs-reclaim and drm_buddy

2022-12-08 Thread Christian König
Am 08.12.22 um 17:28 schrieb Felix Kuehling: Am 2022-12-08 um 10:44 schrieb Christian König: Am 08.12.22 um 16:19 schrieb Felix Kuehling: Am 2022-12-08 um 07:32 schrieb Christian König: Hi Felix, digging though the code I think I know now how we can solve this. The lock which needs to protec

Re: [PATCH 4/4] drm/amdgpu: rework reserved VMID handling

2022-12-08 Thread Alex Deucher
Series is: Reviewed-by: Alex Deucher On Mon, Dec 5, 2022 at 5:43 AM Christian König wrote: > > Instead of reserving a VMID for a single process allow that many > processes use the reserved ID. This allows for proper isolation > between the processes. > > Signed-off-by: Christian König > --- >

[PATCH v3 3/3] ACPI: video: Don't enable fallback path for creating ACPI backlight by default

2022-12-08 Thread Mario Limonciello
The ACPI video detection code has a module parameter `register_backlight_delay` which is currently configured to 8 seconds. This means that if after 8 seconds of booting no native driver has created a backlight device then the code will attempt to make an ACPI video backlight device. This was inte

[PATCH v3 1/3] ACPI: video: Allow GPU drivers to report no panels

2022-12-08 Thread Mario Limonciello
The current logic for the ACPI backlight detection will create a backlight device if no native or vendor drivers have created 8 seconds after the system has booted if the ACPI tables included backlight control methods. If the GPU drivers have loaded, they may be able to report whether any LCD pane

[PATCH v3 2/3] drm/amd/display: Report to ACPI video if no panels were found

2022-12-08 Thread Mario Limonciello
On desktop APUs amdgpu doesn't create a native backlight device as no eDP panels are found. However if the BIOS has reported backlight control methods in the ACPI tables then an acpi_video0 backlight device will be made 8 seconds after boot. This has manifested in a power slider on a number of de

[PATCH v3 0/3] Adjust ACPI video detection fallback path

2022-12-08 Thread Mario Limonciello
In kernel 6.1 the backlight registration code was overhauled so that at most one backlight device got registered. As part of this change there was code added to still allow making an acpi_video0 device if the BIOS contained backlight control methods but no native or vendor drivers registered. Even

Re: Another circular lock dependency involving fs-reclaim and drm_buddy

2022-12-08 Thread Felix Kuehling
Am 2022-12-08 um 10:44 schrieb Christian König: Am 08.12.22 um 16:19 schrieb Felix Kuehling: Am 2022-12-08 um 07:32 schrieb Christian König: Hi Felix, digging though the code I think I know now how we can solve this. The lock which needs to protect the validity of the pages is the vm->evicti

Re: Another circular lock dependency involving fs-reclaim and drm_buddy

2022-12-08 Thread Christian König
Am 08.12.22 um 16:19 schrieb Felix Kuehling: Am 2022-12-08 um 07:32 schrieb Christian König: Hi Felix, digging though the code I think I know now how we can solve this. The lock which needs to protect the validity of the pages is the vm->eviction_lock, cause this one is what serializes the up

Re: [PATCH] drm/amd/display: Fix spelling mistake: "dram_clk_chanage" -> "dram_clk_change"

2022-12-08 Thread Hamza Mahfooz
On 12/8/22 07:18, Colin Ian King wrote: There is a spelling mistake in the struct field dram_clk_chanage. Fix it. Signed-off-by: Colin Ian King Applied. Thanks! --- drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hubbub.c | 8 drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_seque

Re: Another circular lock dependency involving fs-reclaim and drm_buddy

2022-12-08 Thread Felix Kuehling
Am 2022-12-08 um 07:32 schrieb Christian König: Hi Felix, digging though the code I think I know now how we can solve this. The lock which needs to protect the validity of the pages is the vm->eviction_lock, cause this one is what serializes the updates of our page table. This means that th

Re: [PATCH v2 0/3] Adjust ACPI video detection fallback path

2022-12-08 Thread Hans de Goede
Hi, On 12/8/22 02:09, Mario Limonciello wrote: > In kernel 6.1 the backlight registration code was overhauled so that > at most one backlight device got registered. As part of this change > there was code added to still allow making an acpi_video0 device if the > BIOS contained backlight control m

[PATCH] drm/amd/display: Fix spelling mistake: "dram_clk_chanage" -> "dram_clk_change"

2022-12-08 Thread Colin Ian King
There is a spelling mistake in the struct field dram_clk_chanage. Fix it. Signed-off-by: Colin Ian King --- drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hubbub.c | 8 drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c | 2 +- .../drm/amd/display/dc/dcn10/dcn10_hw_sequencer_de

Re: Another circular lock dependency involving fs-reclaim and drm_buddy

2022-12-08 Thread Christian König
Hi Felix, digging though the code I think I know now how we can solve this. The lock which needs to protect the validity of the pages is the vm->eviction_lock, cause this one is what serializes the updates of our page table. This means that the amdgpu_vm_update_range() function needs to be

Re: [PATCH] drm/amdgpu: Add an extra evict_resource call during device_suspend.

2022-12-08 Thread Christian König
Am 08.12.22 um 12:55 schrieb Shikang Fan: - evict_resource is taking too long causing sriov full access mode timeout. So, add an extra evict_resource in the beginning as an early evict. Signed-off-by: Shikang Fan Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_devic

[PATCH] drm/amdgpu: Add an extra evict_resource call during device_suspend.

2022-12-08 Thread Shikang Fan
- evict_resource is taking too long causing sriov full access mode timeout. So, add an extra evict_resource in the beginning as an early evict. Signed-off-by: Shikang Fan --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/gpu/drm/amd

Re: [PATCH v2 1/3] ACPI: video: Allow GPU drivers to report no panels

2022-12-08 Thread Rafael J. Wysocki
On Thu, Dec 8, 2022 at 2:09 AM Mario Limonciello wrote: > > The current logic for the ACPI backlight detection will create > a backlight device if no native or vendor drivers have created > 8 seconds after the system has booted if the ACPI tables > included backlight control methods. > > If the GP

Re: [PATCH] drm/amdgpu: Add an extra evict_resource call during device_suspend.

2022-12-08 Thread Christian König
Hi Shikang, good point. The double checking this the second eviction was removed by Nirmoy because we didn't needed it any more. The GART table and fw images are now just uploaded to VRAM again after resume. I didn't had that info in my mind any more, so sorry my fault :) Adding and extra e

RE: [PATCH] drm/amdgpu: Add an extra evict_resource call during device_suspend.

2022-12-08 Thread Fan, Shikang
[AMD Official Use Only - General] Hi Christian, http://gerrit-git.amd.com/c/brahma/ec/linux/+/620522 In this patch I saw that there was originally two evict in the suspend and this patch the second one (the one after ip_suspend2) were removed. I am a little bit confused on this, should I just

Re: [PATCH] drm/amdgpu: Add an extra evict_resource call during device_suspend.

2022-12-08 Thread Christian König
Am 08.12.22 um 10:25 schrieb Shikang Fan: - evict_resource is taking too long causing sriov full access mode timeout. So, add an extra evict_resource in the beginning as an early evict. - Move the original evict_resource after ip_suspend2. Signed-off-by: Shikang Fan --- drivers/gpu/drm/amd

[PATCH] drm/amdgpu: Add an extra evict_resource call during device_suspend.

2022-12-08 Thread Shikang Fan
- evict_resource is taking too long causing sriov full access mode timeout. So, add an extra evict_resource in the beginning as an early evict. - Move the original evict_resource after ip_suspend2. Signed-off-by: Shikang Fan --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 12 1 f

RE: [PATCH] drm/amdgpu: try allowed domain when pin framebuffer failed

2022-12-08 Thread Zhang, Yifan
[AMD Official Use Only - General] Hi Alex, Yes, I realized within the condition my change is meaningless, please ignore it. And the V2 patch (0001-drm-amdgpu-make-display-pinning-more-flexible-v2.patch) is actually dynamic domain fb allocation, it is good enough to handle most of our fb pin f

Re: [PATCH] drm/amdgpu: Add notifier lock for KFD userptrs

2022-12-08 Thread Chen, Xiaogang
On 12/5/2022 6:54 PM, Felix Kuehling wrote: Add a per-process MMU notifier lock for processing notifiers from userptrs. Use that lock to properly synchronize page table updates with MMU notifiers. v2: rebased Signed-off-by: Felix Kuehling Reviewed-by: Xiaogang Chen (v1) This patch is revie

RE: [PATCH 7/7] drm/amdgpu: define RAS poison mode query function

2022-12-08 Thread Zhang, Hawking
[AMD Official Use Only - General] Series is Reviewed-by: Hawking Zhang Regards, Hawking -Original Message- From: amd-gfx On Behalf Of Tao Zhou Sent: Thursday, December 8, 2022 15:51 To: amd-gfx@lists.freedesktop.org; Zhang, Hawking ; Yang, Stanley ; Wan, Gavin ; Chander, Vignesh ; Yu

Re: [PATCH] drm/amdgpu: try allowed domain when pin framebuffer failed

2022-12-08 Thread Christian König
Am 08.12.22 um 05:40 schrieb Alex Deucher: On Wed, Dec 7, 2022 at 11:35 PM Zhang, Yifan wrote: [AMD Official Use Only - General] We encountered some issues in recent APUs when tried to pin a large framebuffer (e.g. 64MB w/ dual 4K display), switch to display SG could resolve such issue. Act