Re: [PATCH 1/5 V2] drm/amdgpu: Add sysfs interface for gc reset mask

2024-10-23 Thread Lazar, Lijo
On 10/23/2024 8:13 AM, jesse.zh...@amd.com wrote: > Add two sysfs interfaces for gfx and compute: > gfx_reset_mask > compute_reset_mask > > These interfaces are read-only and show the resets supported by the IP. > For example, full adapter reset (mode1/mode2/BACO/etc), > soft reset, queue reset

RE: [PATCH v2 2/2] drm/amdgpu: clean up the suspend_complete

2024-10-23 Thread Liang, Prike
[AMD Official Use Only - AMD Internal Distribution Only] Ping on this series. Thanks, Prike > -Original Message- > From: Liang, Prike > Sent: Monday, October 14, 2024 3:49 PM > To: amd-gfx@lists.freedesktop.org > Cc: Deucher, Alexander ; Lazar, Lijo > ; Liang, Prike > Subject: [PATCH v

Re: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Christian König
Am 23.10.24 um 09:38 schrieb Tvrtko Ursulin: On 22/10/2024 17:24, Christian König wrote: Am 22.10.24 um 17:17 schrieb Li, Yunxiang (Teddy): [Public] +static uint32_t fold_memtype(uint32_t memtype) { In general please add prefixes to even static functions, e.g. amdgpu_vm_ or amdgpu_bo_. + 

Re: [PATCH] drm/amdgpu: handle default profile on on devices without fullscreen 3D

2024-10-23 Thread Michel Dänzer
On 2024-10-22 15:50, Alex Deucher wrote: > Some devices do not support fullscreen 3D. > > v2: Make the check generic. > > Fixes: 336568de918e ("drm/amdgpu/swsmu: default to fullscreen 3D profile for > dGPUs") > Signed-off-by: Alex Deucher > Cc: Kenneth Feng > Cc: Lijo Lazar > --- > drivers/g

[PATCH v3] drm/amdgpu: Add dcn30 drm_panic support

2024-10-23 Thread Jocelyn Falempe
Add support for the drm_panic module, which displays a pretty user friendly message on the screen when a Linux kernel panic occurs. It should work on all radeon using amdgpu_dm_plane.c, when the framebuffer is linear (like when in a VT). For tiled framebuffer, it will only work on radeon with dcn3

Re: [PATCH v2 2/2] drm/amdgpu: clean up the suspend_complete

2024-10-23 Thread Lazar, Lijo
On 10/14/2024 1:19 PM, Prike Liang wrote: > To check the status of S3 suspend completion, > use the PM core pm_suspend_global_flags bit(1) > to detect S3 abort events. Therefore, clean up > the AMDGPU driver's private flag suspend_complete. > > Signed-off-by: Prike Liang > --- > drivers/gpu/d

Re: [PATCH 2/5 V2] drm/amdgpu: Add sysfs interface for sdma reset mask

2024-10-23 Thread Christian König
Am 23.10.24 um 04:43 schrieb jesse.zh...@amd.com: Add the sysfs interface for sdma: sdma_reset_mask The interface is read-only and show the resets supported by the IP. For example, full adapter reset (mode1/mode2/BACO/etc), soft reset, queue reset, and pipe reset. V2: the sysfs node returns

Re: [PATCH] drm/amd/pm: correct the workload setting

2024-10-23 Thread Lazar, Lijo
On 10/23/2024 8:42 AM, Kenneth Feng wrote: > Correct the workload setting in order not to mix the setting > with the end user. Update the workload mask accordingly. > > Signed-off-by: Kenneth Feng > --- > drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 17 ++-- > drivers/gpu/drm/amd/pm/sw

Re: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Christian König
Am 23.10.24 um 13:37 schrieb Tvrtko Ursulin: On 23/10/2024 10:14, Christian König wrote: Am 23.10.24 um 09:38 schrieb Tvrtko Ursulin: On 22/10/2024 17:24, Christian König wrote: Am 22.10.24 um 17:17 schrieb Li, Yunxiang (Teddy): [Public] +static uint32_t fold_memtype(uint32_t memtype) { I

Re: [PATCH] drm/amd/display: add missing tracepoint event in DM atomic_commit_tail

2024-10-23 Thread Leo Li
On 2024-10-23 09:53, Melissa Wen wrote: There are two events to trace the beginning and the end of amdgpu_dm_atomic_commit_tail, but only the one ate the beginning was placed. Place amdgpu_dm_atomic_commit_tail_finish tracepoint at the end than. Signed-off-by: Melissa Wen Reviewed-by: Leo

[PATCH] drm/amd/display: add missing tracepoint event in DM atomic_commit_tail

2024-10-23 Thread Melissa Wen
There are two events to trace the beginning and the end of amdgpu_dm_atomic_commit_tail, but only the one ate the beginning was placed. Place amdgpu_dm_atomic_commit_tail_finish tracepoint at the end than. Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 ++ 1

Re: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Tvrtko Ursulin
On 23/10/2024 10:14, Christian König wrote: Am 23.10.24 um 09:38 schrieb Tvrtko Ursulin: On 22/10/2024 17:24, Christian König wrote: Am 22.10.24 um 17:17 schrieb Li, Yunxiang (Teddy): [Public] +static uint32_t fold_memtype(uint32_t memtype) { In general please add prefixes to even static

Re: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Tvrtko Ursulin
On 22/10/2024 17:24, Christian König wrote: Am 22.10.24 um 17:17 schrieb Li, Yunxiang (Teddy): [Public] +static uint32_t fold_memtype(uint32_t memtype) { In general please add prefixes to even static functions, e.g. amdgpu_vm_ or amdgpu_bo_. +   /* Squash private placements into 'cpu' to

[PATCH] drm/amdgpu/smu13: fix profile reporting

2024-10-23 Thread Alex Deucher
The following 3 commits landed in parallel: commit d7d2688bf4ea ("drm/amd/pm: update workload mask after the setting") commit 7a1613e47e65 ("drm/amdgpu/smu13: always apply the powersave optimization") commit 7c210ca5a2d7 ("drm/amdgpu: handle default profile on on devices without fullscreen 3D") W

RE: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Li, Yunxiang (Teddy)
[AMD Official Use Only - AMD Internal Distribution Only] Yeah it looks like I missed the whole active/purgeable thing as well... Teddy

Re: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Tvrtko Ursulin
On 23/10/2024 13:12, Christian König wrote: Am 23.10.24 um 13:37 schrieb Tvrtko Ursulin: On 23/10/2024 10:14, Christian König wrote: Am 23.10.24 um 09:38 schrieb Tvrtko Ursulin: On 22/10/2024 17:24, Christian König wrote: Am 22.10.24 um 17:17 schrieb Li, Yunxiang (Teddy): [Public] +sta

Re: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Tvrtko Ursulin
On 22/10/2024 18:06, Christian König wrote: Am 22.10.24 um 18:46 schrieb Li, Yunxiang (Teddy): [Public] I suppose we could add a field like amd-memory-private: to cover the private placements. No, that is not really appropriate either. GWS, GDS and OA are not memory in the first place.

Re: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Christian König
Am 23.10.24 um 14:24 schrieb Tvrtko Ursulin: [SNIP] To fold or not the special placements (GWS, GDS & co) is also tangential. In my patch I just preserved the legacy behaviour so it can easily be tweaked on top. Yeah, but again the original behavior is completely broken. GWS, GDS and OA are

RE: [PATCH v5 4/4] drm/amdgpu: track bo memory stats at runtime

2024-10-23 Thread Li, Yunxiang (Teddy)
[AMD Official Use Only - AMD Internal Distribution Only] > From: Tvrtko Ursulin > Sent: Wednesday, October 23, 2024 8:25 > On 23/10/2024 13:12, Christian König wrote: > > Am 23.10.24 um 13:37 schrieb Tvrtko Ursulin: > >> > >> On 23/10/2024 10:14, Christian König wrote: > >>> Am 23.10.24 um 09:38

[PATCH AUTOSEL 6.11 25/30] drm/amdkfd: Accounting pdd vram_usage for svm

2024-10-23 Thread Sasha Levin
From: Philip Yang [ Upstream commit 68d26c10ef503175df3142db6fcd75dd94860592 ] Process device data pdd->vram_usage is read by rocm-smi via sysfs, this is currently missing the svm_bo usage accounting, so "rocm-smi --showpids" per process VRAM usage report is incorrect. Add pdd->vram_usage accou

[PATCH AUTOSEL 6.6 19/23] drm/amdkfd: Accounting pdd vram_usage for svm

2024-10-23 Thread Sasha Levin
From: Philip Yang [ Upstream commit 68d26c10ef503175df3142db6fcd75dd94860592 ] Process device data pdd->vram_usage is read by rocm-smi via sysfs, this is currently missing the svm_bo usage accounting, so "rocm-smi --showpids" per process VRAM usage report is incorrect. Add pdd->vram_usage accou

Re: [PATCH 2/2] Documentation/gpu/amdgpu: Add programming model for DCN

2024-10-23 Thread Harry Wentland
On 2024-10-16 23:34, Rodrigo Siqueira wrote: > One of the challenges to contributing to the display code is the > complexity of the DC component. This commit adds a documentation page > that discusses the programming model used by DCN and an overview of how > the display code is organized. > >

[PATCH] drm/amd/amdgpu: limit single process inside MES

2024-10-23 Thread Shaoyun Liu
This is for MES to limit only one process for the user queues Signed-off-by: Shaoyun Liu --- drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 2 ++ drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c | 24 drivers/gpu/drm/amd/amdgpu/amdgpu_mes.h | 19 +++ drivers/gpu/drm/a

[pull] amdgpu drm-fixes-6.12

2024-10-23 Thread Alex Deucher
Hi Dave, Simona, Fixes for 6.12. The following changes since commit 42f7652d3eb527d03665b09edac47f85fb600924: Linux 6.12-rc4 (2024-10-20 15:19:38 -0700) are available in the Git repository at: https://gitlab.freedesktop.org/agd5f/linux.git tags/amd-drm-fixes-6.12-2024-10-23 for you to fe

Re: [PATCH] drm/amdgpu: Increase MES log buffer to dump mes scratch data

2024-10-23 Thread Deucher, Alexander
[Public] Acked-by: Alex Deucher From: amd-gfx on behalf of Liu, Shaoyun Sent: Tuesday, October 22, 2024 11:21 AM To: Liu, Shaoyun ; amd-gfx@lists.freedesktop.org Subject: RE: [PATCH] drm/amdgpu: Increase MES log buffer to dump mes scratch data [AMD Official

Re: [PATCH 1/2] drm/amd/display: increase max surfaces in line with planes and streams

2024-10-23 Thread Melissa Wen
On 23/10/2024 17:36, Mohamed, Zaeem wrote: [AMD Official Use Only - AMD Internal Distribution Only] Hi, A patch addressing this will be sent out soon. Great! Thanks for the heads up! Melissa Thanks, Zaeem -Original Message- From: Melissa Wen Sent: Tuesday, October 22, 2024 11:

Re: [PATCH] drm/amd/pm: correct the workload setting

2024-10-23 Thread Alex Deucher
On Tue, Oct 22, 2024 at 11:23 PM Kenneth Feng wrote: > > Correct the workload setting in order not to mix the setting > with the end user. Update the workload mask accordingly. Might be better to actually treat the workload like a mask rather than as a discrete setting since that mirrors how the

[PATCH] drm/amd/amdgpu: limit single process inside MES

2024-10-23 Thread Shaoyun Liu
This is for MES to limit only one process for the user queues Signed-off-by: Shaoyun Liu --- drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 2 ++ drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c | 24 drivers/gpu/drm/amd/amdgpu/amdgpu_mes.h | 19 +++ drivers/gpu/drm/a

RE: [PATCH 1/2] drm/amd/display: increase max surfaces in line with planes and streams

2024-10-23 Thread Mohamed, Zaeem
[AMD Official Use Only - AMD Internal Distribution Only] Hi, A patch addressing this will be sent out soon. Thanks, Zaeem -Original Message- From: Melissa Wen Sent: Tuesday, October 22, 2024 11:58 AM To: Mohamed, Zaeem ; Wentland, Harry ; Li, Sun peng (Leo) ; Siqueira, Rodrigo ; Deuc

Re: [PATCH] drm/amd/amdgpu: limit single process inside MES

2024-10-23 Thread Alex Deucher
On Wed, Oct 23, 2024 at 2:08 PM Shaoyun Liu wrote: > > This is for MES to limit only one process for the user queues > > Signed-off-by: Shaoyun Liu > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 2 ++ > drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c | 24 > drivers/gpu/drm/

[PATCH 2/3] drm/amdgpu: Adjust debugfs eviction and IB access permissions

2024-10-23 Thread Alex Deucher
Users should not be able to run these. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c index e44a444052

[PATCH 3/3] drm/amdgpu: add missing size check in amdgpu_debugfs_gprwave_read()

2024-10-23 Thread Alex Deucher
Avoid a possible buffer overflow if size is larger than 4K. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c i

[PATCH 1/3] drm/amdgpu: Adjust debugfs register access permissions

2024-10-23 Thread Alex Deucher
Regular users shouldn't have read access. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c index 6e6092916d4e.

RE: [PATCH v2 2/2] drm/amdgpu: clean up the suspend_complete

2024-10-23 Thread Liang, Prike
[Public] > From: Lazar, Lijo > Sent: Wednesday, October 23, 2024 6:55 PM > To: Liang, Prike ; amd-gfx@lists.freedesktop.org > Cc: Deucher, Alexander > Subject: Re: [PATCH v2 2/2] drm/amdgpu: clean up the suspend_complete > > > > On 10/14/2024 1:19 PM, Prike Liang wrote: > > To check the status o

Re: [PATCH v2 2/2] drm/amdgpu: clean up the suspend_complete

2024-10-23 Thread Lazar, Lijo
On 10/24/2024 8:24 AM, Liang, Prike wrote: > [Public] > >> From: Lazar, Lijo >> Sent: Wednesday, October 23, 2024 6:55 PM >> To: Liang, Prike ; amd-gfx@lists.freedesktop.org >> Cc: Deucher, Alexander >> Subject: Re: [PATCH v2 2/2] drm/amdgpu: clean up the suspend_complete >> >> >> >> On 10/14

[PATCH] drm/amdgpu: skip pci_restore_state under sriov during device init

2024-10-23 Thread Victor Zhao
during device init, under sriov, pci_restore_state happens after fullaccess released, and it can have race condition with mmio protection enable from host side. Since msix was toggled during pci_restore_state, if mmio protection happens during this time, guest side msix will not be properly progra

RE: [PATCH v2 2/2] drm/amdgpu: clean up the suspend_complete

2024-10-23 Thread Liang, Prike
[AMD Official Use Only - AMD Internal Distribution Only] > From: Lazar, Lijo > Sent: Thursday, October 24, 2024 11:39 AM > To: Liang, Prike ; amd-gfx@lists.freedesktop.org > Cc: Deucher, Alexander > Subject: Re: [PATCH v2 2/2] drm/amdgpu: clean up the suspend_complete > > > > On 10/24/2024 8:24