RE: [PATCH] drm/amdgpu: remove redundant semicolons in RAS_EVENT_LOG

2024-07-03 Thread Zhou1, Tao
[AMD Official Use Only - AMD Internal Distribution Only] Reviewed-by: Tao Zhou > -Original Message- > From: Wang, Yang(Kevin) > Sent: Thursday, July 4, 2024 1:53 PM > To: amd-gfx@lists.freedesktop.org > Cc: Zhang, Hawking ; Zhou1, Tao > > Subject: [PATCH] drm/amdgpu: remove redundant s

RE: [PATCH 4/4] drm/amdgpu: add ras event state device attribute support

2024-07-03 Thread Zhou1, Tao
[AMD Official Use Only - AMD Internal Distribution Only] The series is: Reviewed-by: Tao Zhou > -Original Message- > From: Wang, Yang(Kevin) > Sent: Wednesday, July 3, 2024 5:03 PM > To: amd-gfx@lists.freedesktop.org > Cc: Zhang, Hawking ; Zhou1, Tao > > Subject: [PATCH 4/4] drm/amdgp

RE: [PATCH 2/2] drm/amdgpu: timely save bad pages to eeprom after gpu ras reset is complete

2024-07-03 Thread Chai, Thomas
[AMD Official Use Only - AMD Internal Distribution Only] - Best Regards, Thomas -Original Message- From: Zhou1, Tao Sent: Thursday, July 4, 2024 11:40 AM To: Chai, Thomas ; amd-gfx@lists.freedesktop.org Cc: Zhang, Hawking ; Li, Candice ; Wang, Yang(Kevin) ; Yang, Stanley

[PATCH] drm/amdgpu: remove redundant semicolons in RAS_EVENT_LOG

2024-07-03 Thread Yang Wang
remove redundant semicolons in RAS_EVENT_LOG to avoid code format check warning. Fixes: 951c09c88fca ("drm/amdgpu: fix compiler 'side-effect' check issue for RAS_EVENT_LOG()") Signed-off-by: Yang Wang --- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.h | 2 +- 1 file changed, 1 insertion(+), 1 deletio

RE: [PATCH 2/2] drm/amdgpu: timely save bad pages to eeprom after gpu ras reset is complete

2024-07-03 Thread Zhou1, Tao
[AMD Official Use Only - AMD Internal Distribution Only] > -Original Message- > From: Chai, Thomas > Sent: Wednesday, July 3, 2024 4:41 PM > To: amd-gfx@lists.freedesktop.org > Cc: Zhang, Hawking ; Zhou1, Tao > ; Li, Candice ; Wang, Yang(Kevin) > ; Yang, Stanley ; Chai, > Thomas > Subjec

RE: [PATCH] amdgpu/pm: support gpu_metrics sysfs interface for smu v14.0.2/3

2024-07-03 Thread Wang, Yang(Kevin)
[AMD Official Use Only - AMD Internal Distribution Only] Reviewed-by: Yang Wang It is better to change the patch tile prefix to 'drm/amd/pm' . Best Regards, Kevin -Original Message- From: Kenneth Feng Sent: Thursday, July 4, 2024 8:17 AM To: amd-gfx@lists.freedesktop.org Cc: Wang, Yan

[PATCH] amdgpu/pm: support gpu_metrics sysfs interface for smu v14.0.2/3

2024-07-03 Thread Kenneth Feng
support gpu_metrics sysfs interface for smu v14.0.2/3 Signed-off-by: Kenneth Feng --- .../drm/amd/pm/swsmu/smu14/smu_v14_0_2_ppt.c | 86 ++- 1 file changed, 84 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu14/smu_v14_0_2_ppt.c b/drivers/gpu/drm/amd

[pull] amdgpu, radeon drm-next-6.11

2024-07-03 Thread Alex Deucher
Hi Dave, Sima, More new stuff for 6.11. There will be a few additional patches next week for new IPs that were added in this cycle just to get them tied off, but this should be it for general changes. The following changes since commit 15eb8573ad72a97b8f70e3c88b9bef6ddc861f77: drm/amd: Don't

[PATCH 2/2] MAINTAINERS: fix Xinhui's name

2024-07-03 Thread Alex Deucher
Switch to fist last for consistency. Signed-off-by: Alex Deucher Cc: Xinhui Pan --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index 3b7aac333d8e..5fd6fba07fa6 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -18648,7 +18648,7 @@ F:

[PATCH 1/2] MAINTAINERS: update powerplay and swsmu

2024-07-03 Thread Alex Deucher
Evan is no longer maintaining powerplay and swsmu. Add Kenneth Feng as his replacement. Signed-off-by: Alex Deucher Cc: Kenneth Feng --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index 082483b40fac..3b7aac333d8e 100644 --- a/MAINTA

Re: [PATCH] MAINTAINERS: add an entry for AMD DC DML

2024-07-03 Thread Alex Deucher
On Wed, Jul 3, 2024 at 3:20 PM Hamza Mahfooz wrote: > > We want all DML changes to be reviewed by Chaitanya or Jun. So, add an > entry for DML to MAINTAINERS. > > Suggested-by: Rodrigo Siqueira > Signed-off-by: Hamza Mahfooz Acked-by: Alex Deucher > --- > MAINTAINERS | 7 +++ > 1 file ch

[PATCH] MAINTAINERS: add an entry for AMD DC DML

2024-07-03 Thread Hamza Mahfooz
We want all DML changes to be reviewed by Chaitanya or Jun. So, add an entry for DML to MAINTAINERS. Suggested-by: Rodrigo Siqueira Signed-off-by: Hamza Mahfooz --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 7fec8ddb8d5b..d2fb60fee7e8

[pull] amdgpu, radeon drm-fixes-6.10

2024-07-03 Thread Alex Deucher
Hi Dave, Sima, Fixes for 6.10. The following changes since commit 22a40d14b572deb80c0648557f4bd502d7e83826: Linux 6.10-rc6 (2024-06-30 14:40:44 -0700) are available in the Git repository at: https://gitlab.freedesktop.org/agd5f/linux.git tags/amd-drm-fixes-6.10-2024-07-03 for you to fetc

Re: [PATCH v1 2/2] drm/amdgpu: enable redirection of irq's for IH v7.0

2024-07-03 Thread Alex Deucher
Series is: Reviewed-by: Alex Deucher On Wed, Jul 3, 2024 at 1:49 PM Sunil Khatri wrote: > > Enable redirection of irq for pagefaults for specific > clients to avoid overflow without dropping interrupts. > > So here we redirect the interrupts to another IH ring > i.e ring1 where only these interr

[PATCH v1 1/2] drm:amdgpu: enable IH ring1 for IH v7.0

2024-07-03 Thread Sunil Khatri
We need IH ring1 for handling the pagefault interrupts which over flow in default ring for specific usecases. Enable ring1 allows software to redirect high interrupts to ring1 from default IH ring. Signed-off-by: Sunil Khatri --- drivers/gpu/drm/amd/amdgpu/ih_v7_0.c | 11 +-- 1 file cha

[PATCH v1 2/2] drm/amdgpu: enable redirection of irq's for IH v7.0

2024-07-03 Thread Sunil Khatri
Enable redirection of irq for pagefaults for specific clients to avoid overflow without dropping interrupts. So here we redirect the interrupts to another IH ring i.e ring1 where only these interrupts are processed. Signed-off-by: Sunil Khatri --- drivers/gpu/drm/amd/amdgpu/ih_v7_0.c | 15 +

Re: [PATCH v1 4/4] drm/amdgpu: add gfx queue support for gfx12 ipdump

2024-07-03 Thread Alex Deucher
Series is: Reviewed-by: Alex Deucher On Wed, Jul 3, 2024 at 3:39 AM Sunil Khatri wrote: > > Add support of all the CP GFX queues for gfx12 ipdump > to be used by devcoredump. > > Signed-off-by: Sunil Khatri > --- > drivers/gpu/drm/amd/amdgpu/gfx_v12_0.c | 94 ++ > 1 fil

Re: [PATCH] drm/amdgpu: disallow multiple BO_HANDLES chunks in one submit

2024-07-03 Thread Christian König
Am 03.07.24 um 14:48 schrieb Pierre-Eric Pelloux-Prayer: Le 02/07/2024 à 15:35, Christian König a écrit : Am 02.07.24 um 15:23 schrieb Pierre-Eric Pelloux-Prayer: Before this commit, only submits with both a BO_HANDLES chunk and a 'bo_list_handle' would be rejected (by amdgpu_cs_parser_bos). B

RE: [PATCH 3/3] drm/amd/display: Solve mst monitors blank out problem after resume

2024-07-03 Thread Zuo, Jerry
[AMD Official Use Only - AMD Internal Distribution Only] Reviewed-by: Fangzhi Zuo > -Original Message- > From: Wayne Lin > Sent: Wednesday, June 26, 2024 4:48 AM > To: amd-gfx@lists.freedesktop.org; dri-de...@lists.freedesktop.org > Cc: ly...@redhat.com; jani.nik...@intel.com; imre.d...

Re: [PATCH 2/3] drm/dp_mst: Skip CSN if topology probing is not done yet

2024-07-03 Thread Lyude Paul
Ah yep! I thought you had push rights for some reason Also, just so patchwork picks up on it before I push: Reviewed-by: Lyude Paul On Wed, 2024-07-03 at 08:13 +, Lin, Wayne wrote: > [Public] > > > -Original Message- > > From: Lyude Paul > > Sent: Saturday, June 29, 2024 1:40 AM >

[PATCH v9 40/52] drm-dyndbg: add DRM_CLASSMAP_USE to simpledrm

2024-07-03 Thread Jim Cromie
tiny/simpledrm has 3 DRM_UT_DRIVER debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/tiny/simpledrm.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/tiny/si

[PATCH v9 13/52] dyndbg: reduce verbose=3 messages in ddebug_add_module

2024-07-03 Thread Jim Cromie
When modprobing a module, dyndbg currently logs/says "add-module", and then "skipping" if the module has no prdbgs. Instead just check 1st and return quietly. no functional change Signed-off-by: Jim Cromie --- lib/dynamic_debug.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) di

[PATCH v9 52/53] drm-dyndbg: add DRM_CLASSMAP_USE to the drm_gem_shmem_helper driver

2024-07-03 Thread Jim Cromie
The drm_gem_shmem_helper driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/drm_gem_shmem_helper.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/driv

[PATCH v9 48/52] drm-dyndbg: add DRM_CLASSMAP_USE to mgag200 driver

2024-07-03 Thread Jim Cromie
The mgag200 driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/mgag200/mgag200_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/mg

[PATCH v9 33/52] drm-dyndbg: DRM_CLASSMAP_USE in i915 driver

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 45/52] drm-dyndbg: add DRM_CLASSMAP_USE to vmwgfx driver

2024-07-03 Thread Jim Cromie
The vmwgfx driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/vmwgf

[PATCH v9 34/53] drm-dyndbg: DRM_CLASSMAP_USE in i915 driver

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 44/52] drm-dyndbg: add DRM_CLASSMAP_USE to radeon

2024-07-03 Thread Jim Cromie
radeon has some DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg about its use of the class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/radeon/radeon_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/radeon/radeon

[PATCH v9 21/52] dyndbg: split multi-query strings with %

2024-07-03 Thread Jim Cromie
Since commit 85f7f6c0edb8 ("dynamic_debug: process multiple debug-queries on a line") Multi-query commands have been allowed: modprobe drm dyndbg="class DRM_UT_CORE +p; class DRM_UT_KMS +p" modprobe drm dyndbg=< [ 203.902703] dyndbg: query parse failed [ 203.902871] dyndbg: processed 2 quer

[PATCH v9 41/52] drm-dyndbg: add DRM_CLASSMAP_USE to bochs

2024-07-03 Thread Jim Cromie
tiny/bochs has 5 DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/tiny/bochs.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/tiny/bochs.c b/drive

[PATCH v9 37/52] drm-print: workaround unused variable compiler meh

2024-07-03 Thread Jim Cromie
With CONFIG_DRM_USE_DYNAMIC_DEBUG=y, I'm getting an unused variable warning/error on 'category', though the usage follows immediately, in drm_debug_enabled(). This drops the local var and refs the field directly in the macro-call, which avoids the warning. For static-key optimized dyndbg, the mac

[PATCH v9 34/52] drm-dyndbg: DRM_CLASSMAP_USE in drm_crtc_helper

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 43/53] drm-dyndbg: add DRM_CLASSMAP_USE to etnaviv

2024-07-03 Thread Jim Cromie
etnaviv has 5 DRM_UT_CORE debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs as well as plain-old pr_debug()s Signed-off-by: Jim Cromie --- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --g

[PATCH v9 42/52] drm-dyndbg: add DRM_CLASSMAP_USE to etnaviv

2024-07-03 Thread Jim Cromie
etnaviv has 5 DRM_UT_CORE debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs as well as plain-old pr_debug()s Signed-off-by: Jim Cromie --- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --g

[PATCH v9 32/52] drm-dyndbg: DRM_CLASSMAP_USE in amdgpu driver

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 10/52] dyndbg: silence debugs with no-change updates

2024-07-03 Thread Jim Cromie
In ddebug_apply_class_bitmap(), check for actual changes to the bits before announcing them, to declutter logs. no functional change. Signed-off-by: Jim Cromie --- lib/dynamic_debug.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/lib/dynamic_debug.c b/lib/dyna

[PATCH v9 22/52] selftests-dyndbg: test_percent_splitting

2024-07-03 Thread Jim Cromie
This does basic testing of classmaps using '%' separated multi-queries. It modprobes test_dynamic_debug with several classes enabled, and counts to verify that the expected sites show the enablement in the control file. Signed-off-by: Jim Cromie --- .../dynamic_debug/dyndbg_selftest.sh

[PATCH v9 05/52] dyndbg: replace classmap list with a vector

2024-07-03 Thread Jim Cromie
Classmaps are stored in an elf section/array, but are individually list-linked onto dyndbg's per-module ddebug_table for operation. This is unnecessary; even when ddebug_attach_classmap() is handling the builtin section (with classmaps for multiple builtin modules), its contents are ordered, so a

[PATCH v9 44/53] drm-dyndbg: add DRM_CLASSMAP_USE to gma500 driver

2024-07-03 Thread Jim Cromie
The gma500 has 126 DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/gma500/psb_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/gma500/psb_drv

[PATCH v9 14/52] dyndbg-API: remove DD_CLASS_TYPE_(DISJOINT|LEVEL)_NAMES and code

2024-07-03 Thread Jim Cromie
Remove the NAMED class types; these 2 classmap types accept class names at the PARAM interface, for example: echo +DRM_UT_CORE,-DRM_UT_KMS > /sys/module/drm/parameters/debug_names The code works, but its only used by test-dynamic-debug, and wasn't asked for by anyone else, so reduce test-surfac

[PATCH v9 41/53] drm-dyndbg: add DRM_CLASSMAP_USE to simpledrm

2024-07-03 Thread Jim Cromie
tiny/simpledrm has 3 DRM_UT_DRIVER debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/tiny/simpledrm.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/tiny/si

[PATCH v9 33/53] drm-dyndbg: DRM_CLASSMAP_USE in amdgpu driver

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 11/52] dyndbg: tighten ddebug_class_name() 1st arg type

2024-07-03 Thread Jim Cromie
Change function's 1st arg-type, and deref in the caller. The fn doesn't need any other fields in the struct. no functional change. Signed-off-by: Jim Cromie --- lib/dynamic_debug.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/dynamic_debug.c b/lib/dynamic_d

[PATCH v9 35/53] drm-dyndbg: DRM_CLASSMAP_USE in drm_crtc_helper

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 37/53] drm-dyndbg: DRM_CLASSMAP_USE in nouveau

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 39/52] drm-dyndbg: add DRM_CLASSMAP_USE to virtio_gpu

2024-07-03 Thread Jim Cromie
virtio_gpu has 10 DRM_UT_CORE debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/virtio/virtgpu_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/virtio/v

[PATCH v9 32/53] DRM-CLASSMAP-USE in drm-drv.c

2024-07-03 Thread Jim Cromie
--- drivers/gpu/drm/drm_drv.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c index 243cacb3575c..f511d40f577a 100644 --- a/drivers/gpu/drm/drm_drv.c +++ b/drivers/gpu/drm/drm_drv.c @@ -56,6 +56,9 @@ MODULE_LICENSE("GPL and additional ri

[PATCH v9 27/52] selftests-dyndbg: check KCONFIG_CONFIG to avoid silly fails

2024-07-03 Thread Jim Cromie
Several tests are dependent upon config choices. Lets avoid failing where that is noise. The KCONFIG_CONFIG var exists to convey the config-file around. If the var names a file, read it and extract the relevant CONFIG items, and use them to skip the dependent tests, thus avoiding the fails that w

[PATCH v9 36/53] drm-dyndbg: DRM_CLASSMAP_USE in drm_dp_helper

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 53/53] drm: restore CONFIG_DRM_USE_DYNAMIC_DEBUG un-BROKEN

2024-07-03 Thread Jim Cromie
end of official submission. Time for some quality CI Signed-off-by: Jim Cromie --- drivers/gpu/drm/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig index 5a0c476361c3..b2ea73ae48f0 100644 --- a/drivers/gpu/drm/Kconfi

[PATCH v9 36/52] drm-dyndbg: DRM_CLASSMAP_USE in nouveau

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 45/53] drm-dyndbg: add DRM_CLASSMAP_USE to radeon

2024-07-03 Thread Jim Cromie
radeon has some DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg about its use of the class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/radeon/radeon_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/radeon/radeon

[PATCH v9 26/52] dyndbg: change __dynamic_func_call_cls* macros into expressions

2024-07-03 Thread Jim Cromie
The Xe driver's XE_IOCTL_DBG macro calls drm_dbg() from inside an if (expression). This breaks when CONFIG_DRM_USE_DYNAMIC_DEBUG=y because the invoked macro has a do-while-0 wrapper. if (cond && (drm_dbg("expr-form"),1)) { ... do some more stuff } Fix it by changing __dynamic_func_ca

[PATCH v9 48/53] drm-dyndbg: add DRM_CLASSMAP_USE to udl driver

2024-07-03 Thread Jim Cromie
The udl driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/udl/udl_main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/udl/udl_main.

[PATCH v9 52/52] drm: restore CONFIG_DRM_USE_DYNAMIC_DEBUG un-BROKEN

2024-07-03 Thread Jim Cromie
end of official submission. Time for some quality CI Signed-off-by: Jim Cromie --- drivers/gpu/drm/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig index 5a0c476361c3..b2ea73ae48f0 100644 --- a/drivers/gpu/drm/Kconfi

[PATCH v9 24/52] selftests-dyndbg: add test_mod_submod

2024-07-03 Thread Jim Cromie
This new test-fn runs 3 module/submodule modprobe scenarios, variously using both the generic dyndbg= modprobe arg, and the test-module's classmap-params to manipulate the test-mod*'s pr_debugs. In all cases, the current flag-settings are counted and tested vs expectations. The 3rd scenario recapi

Re: [PATCH v9 00/53] fix CONFIG_DRM_USE_DYNAMIC_DEBUG=y

2024-07-03 Thread jim . cromie
On Tue, Jul 2, 2024 at 4:01 PM Luis Chamberlain wrote: > > On Tue, Jul 02, 2024 at 03:56:50PM -0600, Jim Cromie wrote: > > This fixes dynamic-debug support for DRM.debug, added via classmaps. > > commit bb2ff6c27bc9 (drm: Disable dynamic debug as broken) > > > > CONFIG_DRM_USE_DYNAMIC_DEBUG=y was

[PATCH v9 49/53] drm-dyndbg: add DRM_CLASSMAP_USE to mgag200 driver

2024-07-03 Thread Jim Cromie
The mgag200 driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/mgag200/mgag200_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/mg

[PATCH v9 38/52] drm-dyndbg: add DRM_CLASSMAP_USE to Xe driver

2024-07-03 Thread Jim Cromie
Invoke DRM_CLASSMAP_USE from xe_drm_client.c. When built with CONFIG_DRM_USE_DYNAMIC_DEBUG=y, this tells dydnbg that Xe uses has drm.debug calls. Signed-off-by: Jim Cromie --- drivers/gpu/drm/xe/xe_drm_client.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/xe/xe_drm_clie

[PATCH v9 35/52] drm-dyndbg: DRM_CLASSMAP_USE in drm_dp_helper

2024-07-03 Thread Jim Cromie
Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the control file for the driver's drm_dbg()s. Fixes: f

[PATCH v9 02/52] test-dyndbg: fixup CLASSMAP usage error

2024-07-03 Thread Jim Cromie
A more careful reading of logging output from test_dynamic_debug.ko reveals: lib/test_dynamic_debug.c:103 [test_dynamic_debug]do_cats =pmf "doing categories\n" lib/test_dynamic_debug.c:105 [test_dynamic_debug]do_cats =p "LOW msg\n" class:MID lib/test_dynamic_debug.c:106 [test_dynamic_debug]do_ca

[PATCH v9 51/53] drm-dyndbg: add DRM_CLASSMAP_USE to the qxl driver

2024-07-03 Thread Jim Cromie
The qxl driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/qxl/qxl_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/qxl/qxl_drv.c

[PATCH v9 04/52] dyndbg: make ddebug_class_param union members same size

2024-07-03 Thread Jim Cromie
struct ddebug_class_param keeps a ref to the state-storage of the param; make both class-types use the same unsigned long storage type. ISTM this is simpler and safer; it avoids an irrelevant difference, and if 2 users somehow get class-type mixed up (or refer to the wrong union member), at least

[PATCH v9 01/52] docs/dyndbg: update examples \012 to \n

2024-07-03 Thread Jim Cromie
commit 47ea6f99d06e ("dyndbg: use ESCAPE_SPACE for cat control") changed the control-file to display format strings with "\n" rather than "\012". Update the docs to match the new reality. Signed-off-by: Jim Cromie --- Documentation/admin-guide/dynamic-debug-howto.rst | 10 +- 1 file ch

Re: [PATCH v9 32/53] DRM-CLASSMAP-USE in drm-drv.c

2024-07-03 Thread jim . cromie
On Tue, Jul 2, 2024 at 3:58 PM Jim Cromie wrote: > > --- > drivers/gpu/drm/drm_drv.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c > index 243cacb3575c..f511d40f577a 100644 > --- a/drivers/gpu/drm/drm_drv.c > +++ b/drivers/gpu/dr

[PATCH v9 28/52] dyndbg-selftest: reduce default verbosity

2024-07-03 Thread Jim Cromie
Remove the '-v' arg from the tests in test_mod_submod(). Setting V=1 in the environment turns it back on, for all tests. Signed-off-by: Jim Cromie --- .../dynamic_debug/dyndbg_selftest.sh | 23 +-- 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/tools/tes

[PATCH v9 47/53] drm-dyndbg: add DRM_CLASSMAP_USE to vkms driver

2024-07-03 Thread Jim Cromie
The vkms driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/vkms/vkms_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/vkms/vkms_d

[PATCH v9 42/53] drm-dyndbg: add DRM_CLASSMAP_USE to bochs

2024-07-03 Thread Jim Cromie
tiny/bochs has 5 DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/tiny/bochs.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/tiny/bochs.c b/drive

[PATCH v9 39/53] drm-dyndbg: add DRM_CLASSMAP_USE to Xe driver

2024-07-03 Thread Jim Cromie
Invoke DRM_CLASSMAP_USE from xe_drm_client.c. When built with CONFIG_DRM_USE_DYNAMIC_DEBUG=y, this tells dydnbg that Xe uses has drm.debug calls. Signed-off-by: Jim Cromie --- drivers/gpu/drm/xe/xe_drm_client.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/xe/xe_drm_clie

[PATCH v9 07/52] dyndbg: split param_set_dyndbg_classes to _module & wrapper fns

2024-07-03 Thread Jim Cromie
Split api-fn: param_set_dyndbg_classes(), adding modname param and passing NULL in from api-fn. The new arg allows caller to specify that only one module is affected by a prdbgs update. This selectivity will be used later to narrow the scope of changes made. no functional change. Signed-off-by:

[PATCH v9 46/53] drm-dyndbg: add DRM_CLASSMAP_USE to vmwgfx driver

2024-07-03 Thread Jim Cromie
The vmwgfx driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/vmwgf

[PATCH v9 16/52] selftests-dyndbg: add tools/testing/selftests/dynamic_debug/*

2024-07-03 Thread Jim Cromie
Add a selftest script for dynamic-debug. The config requires CONFIG_TEST_DYNAMIC_DEBUG=m (and CONFIG_TEST_DYNAMIC_DEBUG_SUBMOD=m), which tacitly requires either CONFIG_DYNAMIC_DEBUG=y or CONFIG_DYNAMIC_DEBUG_CORE=y ATM this has just basic_tests(), it modifies pr_debug flags in a few builtins (ini

[PATCH v9 03/52] dyndbg: reword "class unknown, " to "class:_UNKNOWN_"

2024-07-03 Thread Jim Cromie
When a dyndbg classname is unknown to a kernel module (as before previous patch), the callsite is un-addressable via >control queries. The control-file displays this condition as "class unknown," currently. That spelling is sub-optimal/too-generic, so change it to "class:_UNKNOWN_" to loudly anno

[PATCH v9 31/52] drm-dyndbg: adapt DRM to invoke DYNDBG_CLASSMAP_PARAM

2024-07-03 Thread Jim Cromie
Invoke DYNDBG_CLASSMAP_PARAM to hook drm.debug (__drm_debug) to the DRM_UT_* classmap, replacing the ad-hoc wiring previously doing it. Signed-off-by: Jim Cromie --- drivers/gpu/drm/drm_print.c | 8 ++-- include/drm/drm_print.h | 6 -- 2 files changed, 6 insertions(+), 8 deletions(-)

[PATCH v9 47/52] drm-dyndbg: add DRM_CLASSMAP_USE to udl driver

2024-07-03 Thread Jim Cromie
The udl driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/udl/udl_main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/udl/udl_main.

[PATCH v9 19/52] dyndbg: treat comma as a token separator

2024-07-03 Thread Jim Cromie
Treat comma as a token terminator, just like a space. This allows a user to avoid quoting hassles when spaces are otherwise needed: :#> modprobe drm dyndbg=class,DRM_UT_CORE,+p\;class,DRM_UT_KMS,+p or as a boot arg: drm.dyndbg=class,DRM_UT_CORE,+p # todo: support multi-query here Given the

[PATCH v9 08/52] dyndbg: drop NUM_TYPE_ARRAY

2024-07-03 Thread Jim Cromie
ARRAY_SIZE works here, since array decl is complete. no functional change Signed-off-by: Jim Cromie --- include/linux/dynamic_debug.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h index b53217e4b711..8116d0a0

[PATCH v9 25/52] dyndbg-doc: explain flags parse 1st

2024-07-03 Thread Jim Cromie
When writing queries to >control, flags are parsed 1st, since they are the only required field. So if the flags draw an error, then keyword errors aren't reported. This can be mildly confusing/annoying, so explain it instead. This note could be moved up to just after the grammar id's the flags,

[PATCH v9 51/52] drm-dyndbg: add DRM_CLASSMAP_USE to the drm_gem_shmem_helper driver

2024-07-03 Thread Jim Cromie
The drm_gem_shmem_helper driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/drm_gem_shmem_helper.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/driv

Re: High Power Consumption of AMD RX6800xt in Idle with Secondary Monitor Connected

2024-07-03 Thread Jaroslav Pulchart
Yes, I can try two panels of the same model. The results are: LG 32UL950 + LG 27UL850 => "MCLK constant boost" (issue) LG 27UL950 + LG 27UL850 => "MCLK is scaling down" (no-issue) > > [AMD Official Use Only - AMD Internal Distribution Only] > > > yeah, there timings look the same, but could you t

[PATCH v9 40/53] drm-dyndbg: add DRM_CLASSMAP_USE to virtio_gpu

2024-07-03 Thread Jim Cromie
virtio_gpu has 10 DRM_UT_CORE debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/virtio/virtgpu_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/virtio/v

[PATCH v9 15/52] dyndbg-API: fix DECLARE_DYNDBG_CLASSMAP

2024-07-03 Thread Jim Cromie
DECLARE_DYNDBG_CLASSMAP() has a design error; its usage fails a basic K&R rule: "define once, refer many times". It is used across DRM core & drivers, each use re-defines the classmap understood by that module; and all must match for the modules to respond together when DRM.debug categories are en

Re: [PATCH v9 30/52] drm-dyndbg: adapt drm core to use dyndbg classmaps-v2

2024-07-03 Thread jim . cromie
On Tue, Jul 2, 2024 at 5:33 PM Ville Syrjälä wrote: > > On Tue, Jul 02, 2024 at 03:57:20PM -0600, Jim Cromie wrote: > > dyndbg's CLASSMAP-v1 api was broken; DECLARE_DYNDBG_CLASSMAP tried to > > do too much. Its replaced by DRM_CLASSMAP_DEFINE, which creates & > > EXPORTs the classmap when CONFIG_

[PATCH v9 06/52] dyndbg: ddebug_apply_class_bitmap - add module arg, select on it

2024-07-03 Thread Jim Cromie
Add param: query_module to ddebug_apply_class_bitmap(), and pass it thru to _ddebug_queries(), replacing NULL with query_module. This allows its caller to update just one module, or all (as currently). We'll use this later to propagate drm.debug to each USEr as they're modprobed. No functional c

[PATCH v9 23/52] docs/dyndbg: explain new delimiters: comma, percent

2024-07-03 Thread Jim Cromie
Add mention of comma and percent delimiters into the respective paragraphs describing their equivalents: space and newline. Signed-off-by: Jim Cromie --- .../admin-guide/dynamic-debug-howto.rst| 18 ++ 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/Documen

[PATCH v9 50/52] drm-dyndbg: add DRM_CLASSMAP_USE to the qxl driver

2024-07-03 Thread Jim Cromie
The qxl driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/qxl/qxl_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/qxl/qxl_drv.c

[PATCH v9 30/52] drm-dyndbg: adapt drm core to use dyndbg classmaps-v2

2024-07-03 Thread Jim Cromie
dyndbg's CLASSMAP-v1 api was broken; DECLARE_DYNDBG_CLASSMAP tried to do too much. Its replaced by DRM_CLASSMAP_DEFINE, which creates & EXPORTs the classmap when CONFIG_DRM_USE_DYNAMIC_DEBUG=y, for direct reference by drivers. The drivers still use DECLARE_DYNDBG_CLASSMAP for now, so they still r

[PATCH v9 50/53] drm-dyndbg: add DRM_CLASSMAP_USE to the gud driver

2024-07-03 Thread Jim Cromie
The gud driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/gud/gud_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/gud/gud_drv.c

[PATCH v9 12/52] dyndbg: tighten fn-sig of ddebug_apply_class_bitmap

2024-07-03 Thread Jim Cromie
old_bits arg is currently a pointer to the input bits, but this could allow inadvertent changes to the input by the fn. Disallow this. And constify new_bits while here. Signed-off-by: Jim Cromie --- lib/dynamic_debug.c | 21 +++-- 1 file changed, 11 insertions(+), 10 deletions(-

[PATCH v9 17/52] dyndbg-API: promote DYNDBG_CLASSMAP_PARAM to API

2024-07-03 Thread Jim Cromie
move the DYNDBG_CLASSMAP_PARAM macro from test-dynamic-debug.c into the header, and refine it, by distinguishing the 2 use cases: 1.DYNDBG_CLASSMAP_PARAM_REF for DRM, to pass in extern __drm_debug by name. dyndbg keeps bits in it, so drm can still use it as before 2.DYNDBG_CLASSMAP_PARAM

[PATCH v9 18/52] dyndbg-doc: add classmap info to howto

2024-07-03 Thread Jim Cromie
Describe the 3 API macros providing dynamic_debug's classmaps DYNDBG_CLASSMAP_DEFINE - create, exports a module's classmap DYNDBG_CLASSMAP_USE- refer to exported map DYNDBG_CLASSMAP_PARAM - bind control param to the classmap DYNDBG_CLASSMAP_PARAM_REF + use module's storage - __drm_debug cc:

[PATCH v9 00/53] fix CONFIG_DRM_USE_DYNAMIC_DEBUG=y

2024-07-03 Thread Jim Cromie
This fixes dynamic-debug support for DRM.debug, added via classmaps. commit bb2ff6c27bc9 (drm: Disable dynamic debug as broken) CONFIG_DRM_USE_DYNAMIC_DEBUG=y was marked broken because drm.debug=val was applied when drm.ko was modprobed; too early for the yet-to-load drivers, which thus missed the

[PATCH v9 46/52] drm-dyndbg: add DRM_CLASSMAP_USE to vkms driver

2024-07-03 Thread Jim Cromie
The vkms driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/vkms/vkms_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/vkms/vkms_d

[PATCH v9 38/53] drm-print: workaround unused variable compiler meh

2024-07-03 Thread Jim Cromie
With CONFIG_DRM_USE_DYNAMIC_DEBUG=y, I'm getting an unused variable warning/error on 'category', though the usage follows immediately, in drm_debug_enabled(). This drops the local var and refs the field directly in the macro-call, which avoids the warning. For static-key optimized dyndbg, the mac

[PATCH v9 49/52] drm-dyndbg: add DRM_CLASSMAP_USE to the gud driver

2024-07-03 Thread Jim Cromie
The gud driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie --- drivers/gpu/drm/gud/gud_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/gud/gud_drv.c

[PATCH v9 43/52] drm-dyndbg: add DRM_CLASSMAP_USE to gma500 driver

2024-07-03 Thread Jim Cromie
The gma500 has 126 DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie --- drivers/gpu/drm/gma500/psb_drv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/gma500/psb_drv

[PATCH v9 09/52] dyndbg: reduce verbose/debug clutter

2024-07-03 Thread Jim Cromie
currently, for verbose=3, these are logged (blank lines for clarity): dyndbg: query 0: "class DRM_UT_CORE +p" mod:* dyndbg: split into words: "class" "DRM_UT_CORE" "+p" dyndbg: op='+' dyndbg: flags=0x1 dyndbg: *flagsp=0x1 *maskp=0x dyndbg: parsed: func="" file="" module="" format="

[PATCH v9 20/52] selftests-dyndbg: add comma_terminator_tests

2024-07-03 Thread Jim Cromie
New fn validates parsing and effect of queries using combinations of commas and spaces to delimit the tokens. It manipulates pr-debugs in builtin module/params, so might have deps I havent foreseen on odd configurations. Signed-off-by: Jim Cromie --- .../selftests/dynamic_debug/dyndbg_selftest.

[PATCH v9 29/52] drm: use correct ccflags-y spelling

2024-07-03 Thread Jim Cromie
Incorrectly spelled CFLAGS- failed to add -DDYNAMIC_DEBUG_MODULE, which broke builds with: CONFIG_DRM_USE_DYNAMIC_DEBUG=y CONFIG_DYNAMIC_DEBUG_CORE=y CONFIG_DYNAMIC_DEBUG=n Also add subdir-ccflags so that all drivers pick up the addition. Fixes: 84ec67288c10 ("drm_print: wrap drm_*_dbg in dyndbg

RE: [PATCH] drm/amdgpu/atomfirmware: silence UBSAN warning

2024-07-03 Thread SHANMUGAM, SRINIVASAN
[Public] Acked-by: Srinivasan Shanmugam -Original Message- From: amd-gfx On Behalf Of Alex Deucher Sent: Monday, July 1, 2024 10:25 PM To: amd-gfx@lists.freedesktop.org; jlay...@kernel.org Cc: Deucher, Alexander Subject: [PATCH] drm/amdgpu/atomfirmware: silence UBSAN warning This is a

  1   2   >