Re: [PATCH] drm/amdgpu: Correct the parameter name of amdgpu_ring_init

2022-03-22 Thread Ma, Jun
On 3/22/2022 9:33 PM, Christian König wrote: > Am 22.03.22 um 13:53 schrieb Ma Jun: >> Correct the parameter name of amdgpu_ring_init() in header file. > > Maybe write "Sync up header and implementation to use the same parameter > names", otherwise somebody cou

Re: [PATCH] drm/amdgpu: Correct the parameter name of amdgpu_ring_init

2022-03-23 Thread Ma, Jun
On 3/23/2022 2:22 PM, Paul Menzel wrote: > Dear Jun, > > > Thank you for your patch. > > Am 23.03.22 um 04:02 schrieb Ma, Jun: > >> On 3/22/2022 9:33 PM, Christian König wrote: >>> Am 22.03.22 um 13:53 schrieb Ma Jun: >>>> Correct the par

[PATCH v2] drm/amdgpu: Sync up header and implementation to use the same parameter names

2022-03-23 Thread Ma Jun
Sync up header and implementation to use the same parameter names in function amdgpu_ring_init. ring_size -> max_dw, prio -> hw_prio v2: - Modify the subject and commit message Reviewed-by: Guchun Chen Reviewed-by: Christian König Signed-off-by: Ma Jun Cha

[PATCH] drm/amdgpu: Correct the parameter name of amdgpu_ring_init

2022-03-22 Thread Ma Jun
Correct the parameter name of amdgpu_ring_init() in header file. Signed-off-by: Ma Jun Change-Id: I202d76ba04b137926b456b1c8a4c05a5b1a01bff --- drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu

Re: [PATCH RESEND] drm/amdgpu: Remove the vega10 from ras support list

2022-01-28 Thread Ma, Jun
; Guchun > > -----Original Message- > From: Ma, Jun > Sent: Thursday, January 27, 2022 7:47 PM > To: amd-gfx@lists.freedesktop.org; brahma_sw_dev > Cc: Zhang, Hawking ; Zhou1, Tao ; > Ma, Jun > Subject: [PATCH RESEND] drm/amdgpu: Remove the vega10 from ras support

Re: [PATCH] amd/amdkfd:Fix the return value in kfd_process_queue_manager

2022-01-19 Thread Ma, Jun
Yes, return is not necessary here. I'll apply this patch on dkms-staging to fix the compile error. On 1/20/2022 1:10 AM, Deucher, Alexander wrote: > [AMD Official Use Only] > > > You can just drop the whole line. > > Alex > >

Re: amd-staging-drm-next breaks suspend

2022-01-20 Thread Ma, Jun
The warn_on is still triggered because of empty gart.ptr in function amdgpu_gart_bind On 1/20/2022 10:56 AM, Chen, Guchun wrote: > [Public] > > [ 1.310551] trying to bind memory to uninitialized GART ! > > This is a warning only, it should not break suspend/resume. There is a fix on > drm-next

[PATCH] drm/amdgpu: Release memory when psp sw_init is failed

2022-04-11 Thread Ma Jun
Release the memory (psp->cmd) when psp initialization is failed in psp_sw_init Signed-off-by: Ma Jun Change-Id: I2f88b5919142d55dd7d3820a7da94823286db235 --- drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 15 +-- 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/drivers/

Re: [PATCH] drm/amd: Fix the flag setting code for interrupt request

2023-09-05 Thread Ma, Jun
On 9/5/2023 1:24 PM, Christian König wrote: > Am 04.09.23 um 08:05 schrieb Ma Jun: >> [1] Remove the irq flags setting code since pci_alloc_irq_vectors() >> handles these flags. >> [2] Free the msi vectors in case of error. >> >> Signed-off-by: Ma Jun >&

[PATCH] drm/amd: Fix the flag setting code for interrupt request

2023-09-04 Thread Ma Jun
[1] Remove the irq flags setting code since pci_alloc_irq_vectors() handles these flags. [2] Free the msi vectors in case of error. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 43 ++--- 1 file changed, 25 insertions(+), 18 deletions(-) diff --git

[PATCH v2] drm/amd: Fix the flag setting code for interrupt request

2023-09-06 Thread Ma Jun
[1] Remove the irq flags setting code since pci_alloc_irq_vectors() handles these flags. [2] Free the msi vectors in case of error. v2: - Remove local variable initializing code (Christian) - Use PCI_IRQ_ALL_TYPES (Alex) Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 45

Re: [PATCH] drm/amd: Fix the flag setting code for interrupt request

2023-09-05 Thread Ma, Jun
On 9/5/2023 10:46 PM, Alex Deucher wrote: > On Mon, Sep 4, 2023 at 2:30 AM Ma Jun wrote: >> >> [1] Remove the irq flags setting code since pci_alloc_irq_vectors() >> handles these flags. >> [2] Free the msi vectors in case of error. >> >> Signed-off-by:

Re: [PATCH v2] drm/amd: Fix the flag setting code for interrupt request

2023-09-06 Thread Ma, Jun
On 9/6/2023 3:23 PM, Christian König wrote: > Am 06.09.23 um 08:55 schrieb Ma Jun: >> [1] Remove the irq flags setting code since pci_alloc_irq_vectors() >> handles these flags. >> [2] Free the msi vectors in case of error. >> >> v2: >> - Remove loca

[PATCH] drm/amd/pm: Add reset option for fan_curve on smu13_0_0

2023-09-10 Thread Ma Jun
Add reset option for fan_curve. User can use command "echo r > fan_cure" to reset the fan_curve to boot value Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/amdgpu_pm.c| 8 .../drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c | 43 +-- 2 files changed,

[PATCH v12 2/9] platform/x86/amd: Add support for AMD ACPI based Wifi band RFI mitigation feature

2023-10-16 Thread Ma Jun
can use to notify active use of particular frequencies so that other devices can make relative internal adjustments as necessary to avoid this resonance. Co-Developed-by: Evan Quan Signed-off-by: Evan Quan Signed-off-by: Ma Jun -- v11: - fix typo(Simon) v12: - Fix the code (Rafael) - Move

[PATCH v12 3/9] cfg80211: expose nl80211_chan_width_to_mhz for wide sharing

2023-10-16 Thread Ma Jun
From: Evan Quan The newly added WBRF feature needs this interface for channel width calculation. Signed-off-by: Ma Jun Signed-off-by: Evan Quan -- v8->v9: - correct typo(Mhz -> MHz) (Johnson) --- include/net/cfg80211.h | 8 net/wireless/chan.c| 3 ++- 2 files chang

[PATCH v12 5/9] drm/amd/pm: update driver_if and ppsmc headers for coming wbrf feature

2023-10-16 Thread Ma Jun
From: Evan Quan Add those data structures to support Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun --- .../pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_0.h | 14 +- .../pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_7.h | 14

[PATCH v12 4/9] wifi: mac80211: Add support for WBRF features

2023-10-16 Thread Ma Jun
interference. Co-developed-by: Mario Limonciello Signed-off-by: Mario Limonciello Co-developed-by: Evan Quan Signed-off-by: Evan Quan Signed-off-by: Ma Jun -- v1->v2: - place the new added member(`wbrf_supported`) in ieee80211_local(Johannes) - handle chandefs change scenario prope

[PATCH v12 0/9] Enable Wifi RFI interference mitigation feature support

2023-10-16 Thread Ma Jun
feature support for SMU13.0.7 Ma Jun (2): Documentation/driver-api: Add document about WBRF mechanism platform/x86/amd: Add support for AMD ACPI based Wifi band RFI mitigation feature Documentation/driver-api/wbrf.rst | 71 +++ drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2

[PATCH v12 1/9] Documentation/driver-api: Add document about WBRF mechanism

2023-10-16 Thread Ma Jun
Add documentation about AMD's Wifi band RFI mitigation (WBRF) mechanism explaining the theory and how it is used. Signed-off-by: Ma Jun --- Documentation/driver-api/wbrf.rst | 73 +++ 1 file changed, 73 insertions(+) create mode 100644 Documentation/driver-api

[PATCH v12 6/9] drm/amd/pm: setup the framework to support Wifi RFI mitigation feature

2023-10-16 Thread Ma Jun
Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun -- v1->v2: - update the prompt for feature support(Lijo) v8->v9: - update parameter document for smu_wbrf_event_handler(Simon) v9->v10: v10->v11: - correct the logics for wbrf range sorting(Lijo) --- drivers/gpu/drm/amd/amd

[PATCH v12 8/9] drm/amd/pm: enable Wifi RFI mitigation feature support for SMU13.0.0

2023-10-16 Thread Ma Jun
From: Evan Quan Fulfill the SMU13.0.0 support for Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun -- v10->v11: - downgrade the prompt level on message failure(Lijo) --- drivers/gpu/drm/amd/pm/swsmu/inc/amdgpu_smu.h | 3 + driv

[PATCH v12 9/9] drm/amd/pm: enable Wifi RFI mitigation feature support for SMU13.0.7

2023-10-16 Thread Ma Jun
From: Evan Quan Fulfill the SMU13.0.7 support for Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun -- v10->v11: - downgrade the prompt level on message failure(Lijo) --- .../drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c |

[PATCH v12 7/9] drm/amd/pm: add flood detection for wbrf events

2023-10-16 Thread Ma Jun
From: Evan Quan To protect PMFW from being overloaded. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 31 +++ drivers/gpu/drm/amd/pm/swsmu/inc/amdgpu_smu.h | 7 + 2 files changed, 32

[PATCH] drm/amd/pm: Support for getting power1_cap_min value

2023-10-17 Thread Ma Jun
Support for getting power1_cap_min value on smu13 and smu11. For other Asics, we still use 0 as the default value. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/amdgpu_pm.c| 14 drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 16 + drivers/gpu/drm/amd/pm/swsmu

[PATCH] drm/amd/pm: Return 0 as default min power limit for legacy asics

2023-10-26 Thread Ma Jun
Return 0 as the default min power limit for the asics using powerplay. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/powerplay/amd_powerplay.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/amd/pm/powerplay/amd_powerplay.c b/drivers/gpu/drm/amd/pm/powerplay

[PATCH] drm/amd/pm: only check sriov vf flag once when creating pm sysfs

2023-10-25 Thread Ma Jun
The current code checks sriov vf flag multiple times when creating pm sysfs. So fix it and optimize related code here. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/amdgpu_pm.c | 27 ++- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/drivers/gpu/drm

Re: [PATCH] drm/amd/pm: only check sriov vf flag once when creating pm sysfs

2023-10-25 Thread Ma, Jun
drop this one for some format issue. I will send a new version. Regards, Ma Jun On 10/26/2023 10:45 AM, Ma Jun wrote: > The current code checks sriov vf flag multiple times when creating > pm sysfs. So fix it and optimize related code here. > > Signed-off-by: Ma Jun > --- >

[PATCH Resend] drm/amd/pm: only check sriov vf flag once when creating hwmon sysfs

2023-10-25 Thread Ma Jun
The current code checks sriov vf flag multiple times when creating hwmon sysfs. So fix it. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/amdgpu_pm.c | 27 ++- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/amdgpu_pm.c b/drivers

[PATCH 1/2] drm/amdgpu: Optimize the asic type fix code

2023-10-31 Thread Ma Jun
Use a new struct array to define the asic information which asic type needs to be fixed. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 35 ++--- include/drm/amd_asic_type.h | 5 2 files changed, 31 insertions(+), 9 deletions(-) diff

[PATCH 2/2] drm/amdgpu: Fix the the asic type of some new asics

2023-10-31 Thread Ma Jun
Some special new asics use the same device id as Sienna_Cichlid. So fix it. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c index

Recall: [PATCH 1/2] drm/amdgpu: Optimize the asic type fix code

2023-10-31 Thread Ma, Jun
Ma, Jun would like to recall the message, "[PATCH 1/2] drm/amdgpu: Optimize the asic type fix code".

Recall: [PATCH 2/2] drm/amdgpu: Fix the the asic type of some new asics

2023-10-31 Thread Ma, Jun
Ma, Jun would like to recall the message, "[PATCH 2/2] drm/amdgpu: Fix the the asic type of some new asics".

[PATCH v2 2/2] drm/amdgpu: Fix the the asic type of some new asics

2023-10-31 Thread Ma Jun
Some new asics use the same device id as Sienna_Cichlid. So fix it. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c index

[PATCH v2 1/2] drm/amdgpu: Optimize the asic type fix code

2023-10-31 Thread Ma Jun
Use a new struct array to define the asic information which asic type needs to be fixed. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 35 ++--- include/drm/amd_asic_type.h | 5 2 files changed, 31 insertions(+), 9 deletions(-) diff

[PATCH] drm/amd/pm: Fix error of MACO flag setting code

2023-10-30 Thread Ma Jun
MACO only works if BACO is supported Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c | 8 drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c | 9 + 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu13

Re: [PATCH v2 1/2] drm/amdgpu: Optimize the asic type fix code

2023-11-01 Thread Ma, Jun
ping... Regards, Ma Jun On 11/1/2023 11:04 AM, Ma Jun wrote: > Use a new struct array to define the asic information which > asic type needs to be fixed. > > Signed-off-by: Ma Jun > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 35 ++--- > includ

[PATCH] drm/amd/pm:Fix return vlaue and drop redundant param

2023-11-02 Thread Ma Jun
Fix the return value and drop redundant parameter of get_asic_baco_capability function to simplify the code Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/include/kgd_pp_interface.h | 2 +- drivers/gpu/drm/amd/pm/amdgpu_dpm.c | 8 +++- drivers/gpu/drm/amd/pm

[PATCH] drm/amd/pm: Move some functions to smu_v13_0.c as generic code

2023-11-03 Thread Ma Jun
Use generic functions and remove the duplicate code Signed-off-by: Ma Jun --- .../gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c| 38 ++- .../drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c | 36 +- .../drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c | 36 +- 3

[PATCH] drm/amd/pm: Remove redundant function members of pptable_funcs

2023-11-06 Thread Ma Jun
Remove redundant functions members of pptable_funcs and change the function type as static because they are not called by other files. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/swsmu/inc/smu_v13_0.h | 4 -- .../gpu/drm/amd/pm/swsmu/smu11/arcturus_ppt.c | 2 - .../gpu/drm/amd/pm/swsmu

Re: [PATCH Resend] drm/amd/pm: only check sriov vf flag once when creating hwmon sysfs

2023-10-30 Thread Ma, Jun
all not supported */ > if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev)) > This function is called for each attribute now, so the vf flags will also be checked multiple times. So move this code to amdgpu_pm_sysfs_init so that the vf flags will only be checked once. Regards, M

[Patch v13 1/9] Documentation/driver-api: Add document about WBRF mechanism

2023-10-30 Thread Ma Jun
Add documentation about AMD's Wifi band RFI mitigation (WBRF) mechanism explaining the theory and how it is used. Signed-off-by: Ma Jun --- Documentation/driver-api/wbrf.rst | 76 +++ 1 file changed, 76 insertions(+) create mode 100644 Documentation/driver-api

[Patch v13 0/9] Enable Wifi RFI interference mitigation feature support

2023-10-30 Thread Ma Jun
/amd/pm: update driver_if and ppsmc headers for coming wbrf feature drm/amd/pm: setup the framework to support Wifi RFI mitigation feature drm/amd/pm: add flood detection for wbrf events drm/amd/pm: enable Wifi RFI mitigation feature support for SMU13.0.7 Ma Jun (3): Documentation/driver-api

Re: [PATCH Resend] drm/amd/pm: only check sriov vf flag once when creating hwmon sysfs

2023-10-30 Thread Ma, Jun
ping... On 10/26/2023 10:50 AM, Ma Jun wrote: > The current code checks sriov vf flag multiple times when creating > hwmon sysfs. So fix it. > > Signed-off-by: Ma Jun > --- > drivers/gpu/drm/amd/pm/amdgpu_pm.c | 27 ++- > 1 file changed, 14 insert

[Patch v13 2/9] platform/x86/amd: Add support for AMD ACPI based Wifi band RFI mitigation feature

2023-10-30 Thread Ma Jun
can use to notify active use of particular frequencies so that other devices can make relative internal adjustments as necessary to avoid this resonance. Co-developed-by: Evan Quan Signed-off-by: Evan Quan Signed-off-by: Ma Jun -- v11: - fix typo(Simon) v12: - Fix the code logic (Rafael

[Patch v13 5/9] drm/amd/pm: update driver_if and ppsmc headers for coming wbrf feature

2023-10-30 Thread Ma Jun
From: Evan Quan Add those data structures to support Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun v13: - Move some struct variables to amdgpu_smu.h to reduce duplicate code --- drivers/gpu/drm/amd/pm/swsmu/inc/amdgpu_smu.h

[Patch v13 6/9] drm/amd/pm: setup the framework to support Wifi RFI mitigation feature

2023-10-30 Thread Ma Jun
Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun -- v1->v2: - update the prompt for feature support(Lijo) v8->v9: - update parameter document for smu_wbrf_event_handler(Simon) v9->v10: v10->v11: - correct the logics for wbrf range sorting(Lijo) v13: - Fix the format issue (I

[Patch v13 3/9] cfg80211: expose nl80211_chan_width_to_mhz for wide sharing

2023-10-30 Thread Ma Jun
From: Evan Quan The newly added WBRF feature needs this interface for channel width calculation. Signed-off-by: Ma Jun Signed-off-by: Evan Quan -- v8->v9: - correct typo(Mhz -> MHz) (Johnson) v13: - Fix the format issue (IIpo Jarvinen) --- include/net/cfg80211.h | 9

[Patch v13 4/9] wifi: mac80211: Add support for WBRF features

2023-10-30 Thread Ma Jun
interference. Co-developed-by: Mario Limonciello Signed-off-by: Mario Limonciello Co-developed-by: Evan Quan Signed-off-by: Evan Quan Signed-off-by: Ma Jun -- v1->v2: - place the new added member(`wbrf_supported`) in ieee80211_local(Johannes) - handle chandefs change scenario prope

[Patch v13 8/9] drm/amd/pm: enable Wifi RFI mitigation feature support for SMU13.0.0

2023-10-30 Thread Ma Jun
Fulfill the SMU13.0.0 support for Wifi RFI mitigation feature. Co-developed-by: Evan Quan Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun -- v10->v11: - downgrade the prompt level on message failure(Lijo) v13: - Fix the format issue (IIpo Jarvinen) - M

[Patch v13 7/9] drm/amd/pm: add flood detection for wbrf events

2023-10-30 Thread Ma Jun
From: Evan Quan To protect PMFW from being overloaded. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 29 +++ drivers/gpu/drm/amd/pm/swsmu/inc/amdgpu_smu.h | 7 + 2 files changed, 30

[Patch v13 9/9] drm/amd/pm: enable Wifi RFI mitigation feature support for SMU13.0.7

2023-10-30 Thread Ma Jun
From: Evan Quan Fulfill the SMU13.0.7 support for Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello Signed-off-by: Ma Jun -- v10->v11: - downgrade the prompt level on message failure(Lijo) v13: - Fix the format issue (IIpo Jarvinen) - Remove duplic

Re: [PATCH] drm/amd/pm: Move some functions to smu_v13_0.c as generic code

2023-11-05 Thread Ma, Jun
Thanks, will fix it in the next version. Regards, Ma Jun On 11/3/2023 9:31 PM, Wang, Yang(Kevin) wrote: > > -Original Message- > From: Ma, Jun > Sent: Friday, November 3, 2023 4:21 PM > To: amd-gfx@lists.freedesktop.org; Feng, Kenneth ; > Deucher, Alexander

[PATCH v2] drm/amd/pm: Move some functions to smu_v13_0.c as generic code

2023-11-05 Thread Ma Jun
Use generic functions and remove the duplicate code Signed-off-by: Ma Jun --- .../gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c| 38 ++- .../drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c | 36 +- .../drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c | 36 +- 3

[PATCH] drm/amd/pm: Fix the return value in default case

2023-10-18 Thread Ma Jun
Fix the return value in default case and drop redundant 'break'. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c

Re: [PATCH v12 0/9] Enable Wifi RFI interference mitigation feature support

2023-10-19 Thread Ma, Jun
ping... Any other comments? Regards, Ma Jun On 10/17/2023 10:53 AM, Ma Jun wrote: > Due to electrical and mechanical constraints in certain platform designs there > may be likely interference of relatively high-powered harmonics of the (G-)DDR > memory clocks with local radio module

Re: [PATCH] drm/amd/pm: Add reset option for fan_curve on smu13_0_0

2023-09-19 Thread Ma, Jun
Hi Alex, On 9/18/2023 10:05 PM, Alex Deucher wrote: > On Mon, Sep 11, 2023 at 2:00 AM Ma Jun wrote: >> >> Add reset option for fan_curve. >> User can use command "echo r > fan_cure" to reset the fan_curve >> to boot value >> >> Signed-off-by: M

[PATCH 1/2] drm/amd/pm: Add reset option for fan_ctrl interfaces

2023-10-10 Thread Ma Jun
Add reset option for fan_ctrl interfaces. For example: User can use the "echo r > acoustic_limit_rpm_threshold" command to reset acoustic_limit_rpm_threshold to boot value Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/amdgpu_pm.c| 12 ++ .../drm/amd/p

[PATCH 2/2] drm/amd/pm: Add reset option for fan_ctrl on smu 13.0.7

2023-10-10 Thread Ma Jun
Add reset option for fan_ctrl interfaces on the smu v13.0.7 User can use command "echo r > interface_name" to reset the interface to boot value Signed-off-by: Ma Jun --- .../drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c | 69 +-- 1 file changed, 64 insertions(+)

Re: [PATCH v12 1/9] Documentation/driver-api: Add document about WBRF mechanism

2023-10-17 Thread Ma, Jun
Hi llpo, Thanks for these comments on format issues, I'll fix it in the next version. Regards, Ma Jun On 10/17/2023 5:20 PM, Ilpo Järvinen wrote: > On Tue, 17 Oct 2023, Ma Jun wrote: > >> Add documentation about AMD's Wifi band RFI mitigation (WBRF) mechanism >> explaining

Re: [PATCH] drm/amd: Simplify the size check funciton

2023-08-27 Thread Ma, Jun
Hi Christian, On 8/25/2023 4:08 PM, Christian König wrote: > > > Am 25.08.23 um 07:22 schrieb Ma Jun: >> Simplify the code logic of size check function amdgpu_bo_validate_size >> >> Signed-off-by: Ma Jun >> --- >> drivers/gpu/drm/amd/amdgpu/amdgpu_obje

Re: [PATCH] drm/amd: Simplify the size check funciton

2023-08-28 Thread Ma, Jun
On 8/28/2023 2:00 PM, Christian König wrote: > Am 28.08.23 um 07:09 schrieb Ma, Jun: >> Hi Christian, >> >> On 8/25/2023 4:08 PM, Christian König wrote: >>> >>> Am 25.08.23 um 07:22 schrieb Ma Jun: >>>> Simplify the code logic of size check fu

[PATCH v2] drm/amd: Simplify the bo size check funciton

2023-08-28 Thread Ma Jun
Simplify the code logic of size check function amdgpu_bo_validate_size Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 29 +- 1 file changed, 12 insertions(+), 17 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c b/drivers/gpu/drm

[PATCH] drm/amd: Simplify the size check funciton

2023-08-24 Thread Ma Jun
Simplify the code logic of size check function amdgpu_bo_validate_size Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 28 +- 1 file changed, 11 insertions(+), 17 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c b/drivers/gpu/drm

Re: [Patch v13 0/9] Enable Wifi RFI interference mitigation feature support

2023-11-09 Thread Ma, Jun
ping... Any other comments? Regards, Ma Jun On 10/30/2023 3:18 PM, Ma Jun wrote: > Due to electrical and mechanical constraints in certain platform designs there > may be likely interference of relatively high-powered harmonics of the (G-)DDR > memory clocks with local radio module

[PATCH] drm/amd/pm: Make smu_v13_0_baco_set_armd3_sequence() static

2023-11-08 Thread Ma Jun
smu_v13_0_baco_set_armd3_sequence is not used by other files, so make it as static type. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/pm/swsmu/inc/smu_v13_0.h | 3 --- drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers

[PATCH RESEND] drm/amdgpu: Remove redundant reference of header file

2022-08-01 Thread Ma Jun
Remove redundant reference of header file dev_printk.h Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/psp_v13_0.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/psp_v13_0.c b/drivers/gpu/drm/amd/amdgpu/psp_v13_0.c index c9821f89eeed..c39e8b333181 100644

[PATCH] drm/amd/display: Remove redundant reference of the header file

2022-08-30 Thread Ma Jun
From: Ma Jun Remove redundant reference of the header file drm_gem_atomic_helper.h Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display

Re: [PATCH 2/2] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-10-25 Thread Ma, Jun
Hi Felix, On 10/25/2022 5:06 AM, Felix Kuehling wrote: > > On 2022-10-24 07:26, Ma Jun wrote: >> For some GPUs with more CUs, the original sibling_map[32] >> in struct crat_subtype_cache is not enough >> to save the cache information when create the VCRAT table, &

Re: [PATCH 1/2] drm/amdkfd: Init the base cu processor id

2022-10-25 Thread Ma, Jun
Hi Felix, Thanks for review. I will fix these problems in v2. Regards, Ma Jun On 10/25/2022 5:03 AM, Felix Kuehling wrote: > On 2022-10-24 07:26, Ma Jun wrote: >> Init and save the base cu processor id for later use >> >> Signed-off-by: Ma Jun >> --- >> driv

[PATCH v2 1/2] drm/amdkfd: Init the base cu processor id

2022-10-26 Thread Ma Jun
Init and save the base cu processor id for later use Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 20 +--- drivers/gpu/drm/amd/amdkfd/kfd_priv.h | 3 +++ 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_crat.c

[PATCH v2 2/2] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-10-26 Thread Ma Jun
: - Remove unnecessary sys interface "cache_ext" Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 307 +++--- drivers/gpu/drm/amd/amdkfd/kfd_crat.h | 12 + drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 238 - drivers/gpu/drm/amd/amdkfd/kfd_

Re: [PATCH v2 1/2] drm/amdkfd: Init the base cu processor id

2022-10-26 Thread Ma, Jun
Hi Felix, On 10/27/2022 3:07 AM, Felix Kuehling wrote: > On 2022-10-26 05:03, Ma Jun wrote: >> Init and save the base cu processor id for later use >> >> Signed-off-by: Ma Jun >> --- >> drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 20 +--- >>

[PATCH v3] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-10-27 Thread Ma Jun
processor id calc function v2: - Remove unnecessary sys interface "cache_ext" Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 307 +++--- drivers/gpu/drm/amd/amdkfd/kfd_crat.h | 12 + drivers/gpu/drm/amd/amdkfd/kfd_topolo

[PATCH] drm/amdkfd: Remove unused variable

2022-10-27 Thread Ma Jun
The kfd_topology_device->cache_count is not used by other fucntions, so remove it. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 1 - drivers/gpu/drm/amd/amdkfd/kfd_topology.h | 1 - 2 files changed, 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_crat.c

[PATCH 2/2] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-10-24 Thread Ma Jun
class/kfd/kfd/topology/nodes/*nodes_num*/caches_ext" is created for cache information showing. The original directory "cache" is reserved for GPU which using real CRAT table. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 1229 +--- driver

[PATCH 1/2] drm/amdkfd: Init the base cu processor id

2022-10-24 Thread Ma Jun
Init and save the base cu processor id for later use Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 24 + drivers/gpu/drm/amd/amdkfd/kfd_device.c | 28 + drivers/gpu/drm/amd/amdkfd/kfd_priv.h | 3 +++ 3 files changed, 32

[PATCH] drm/amdgpu: Fix the lpfn checking condition in drm buddy

2022-09-14 Thread Ma Jun
Because the value of man->size is changed during suspend/resume process, use mgr->mm.size instead of man->size here for lpfn checking. Signed-off-by: Ma Jun Suggested-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_vram_mgr.c | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-10-07 Thread Ma Jun
Increasing the simbling array size to fix the warning of array-index-out-of-bounds. The VCRAT_SIZE_FOR_GPU is also increased accrordingly. Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 2 +- drivers/gpu/drm/amd/amdkfd/kfd_crat.h | 2 +- 2 files changed, 2 insertions(+), 2

Re: [PATCH] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-10-10 Thread Ma, Jun
Hi Felix, Thanks for this suggestion, I'll make a new patch to fix this. Regards, Ma Jun On 10/9/2022 12:34 AM, Felix Kuehling wrote: > This breaks the CRAT table ABI, which will break APUs that use an actual > CRAT table from ACPI. > > I think to fix this, you'll need

Re: [PATCH v4] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-11-01 Thread Ma, Jun
Hi Felix, On 11/2/2022 3:38 AM, Felix Kuehling wrote: > > On 2022-11-01 04:52, Ma Jun wrote: >> For some GPUs with more CUs, the original sibling_map[32] >> >> in struct crat_subtype_cache is not enough >> >> to save the cache information when create th

[PATCH 2/2] drm/ttm: Use debugfs_remove_recursive to remove ttm directory

2023-01-12 Thread Ma Jun
Use debugfs_remove_recursive to remove the /sys/kernel/debug/ttm directory for better compatibility. Becuase debugfs_remove fails on older kernel. Signed-off-by: Ma Jun --- drivers/gpu/drm/ttm/ttm_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/ttm

[PATCH 1/2] drm/ttm: Check ttm_debugfs_root before creating files under it

2023-01-12 Thread Ma Jun
Check the ttm_debugfs_root before creating files under it. If the ttm_debugfs_root is NULL, all the files created for ttm/ will be placed in the /sys/kerne/debug/ but not /sys/kernel/debug/ttm/ Signed-off-by: Ma Jun --- drivers/gpu/drm/ttm/ttm_device.c | 3 ++- drivers/gpu/drm/ttm/ttm_pool.c

[PATCH] drm/plane-helper: Add the missing declaration of drm_atomic_state

2022-12-07 Thread Ma Jun
Add the missing declaration of struct drm_atomic_state Signed-off-by: Ma Jun --- include/drm/drm_plane_helper.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/drm/drm_plane_helper.h b/include/drm/drm_plane_helper.h index b00ad36cf5b6..530f88176db4 100644 --- a/include/drm

Re: [RESEND PATCH] drm/plane-helper: Add the missing declaration of drm_atomic_state

2022-12-15 Thread Ma, Jun
On 12/15/2022 4:40 PM, Thomas Zimmermann wrote: > Hi > > Am 15.12.22 um 04:01 schrieb Ma Jun: >> Add the missing declaration of struct drm_atomic_state to fix the >> compile error below: >> >> error: 'struct drm_atomic_state' declared inside parameter &g

[PATCH V2] drm/plane-helper: Add the missing declaration of drm_atomic_state

2022-12-15 Thread Ma Jun
Add the missing declaration of struct drm_atomic_state to fix the compile error below: error: 'struct drm_atomic_state' declared inside parameter list will not be visible outside of this definition or declaration [-Werror] Signed-off-by: Ma Jun --- include/drm/drm_plane_helper.h | 1 + 1 file

[RESEND PATCH] drm/plane-helper: Add the missing declaration of drm_atomic_state

2022-12-14 Thread Ma Jun
Add the missing declaration of struct drm_atomic_state to fix the compile error below: error: 'struct drm_atomic_state' declared inside parameter list will not be visible outside of this definition or declaration [-Werror] Signed-off-by: Ma Jun --- include/drm/drm_plane_helper.h | 1 + 1 file

[PATCH] drm/amdkfd: Release the topology_lock in error case

2022-11-20 Thread Ma Jun
From: Felix Kuehling Move the topology-locked part of kfd_topology_add_device into a separate function to simlpify error handling and release the topology lock consistently. Reported-by: Dan Carpenter Signed-off-by: Felix Kuehling Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd

Re: [PATCH] drm/amdkfd: Release the topology_lock in error case

2022-11-16 Thread Ma, Jun
Hi Felix, I just tested your patch. It works fine on my test set with the following little fix. Regards, Ma Jun diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c index 7ea3ec1e9e75..7d6fbfbfeb79 100644 --- a/drivers/gpu/drm/amd/amdkfd

Re: [bug report] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-11-15 Thread Ma, Jun
Hi Dan, Thanks for catching this. I'll check it and post a fix patch. Regards, Ma Jun On 11/15/2022 9:00 PM, Dan Carpenter wrote: > [ Ugh... My email messed up and I have to Resend all my emails for the > past two weeks. -dan ] > > Hello Ma Jun, > > The patch c0cc999f3c32

[PATCH] drm/amdkfd: Release the topology_lock in error case

2022-11-16 Thread Ma Jun
Release the topology_lock in error case Signed-off-by: Ma Jun Reported-by: Dan Carpenter --- drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c index

Re: [PATCH 2/2] drm/ttm: Use debugfs_remove_recursive to remove ttm directory

2023-01-15 Thread Ma, Jun
On 1/13/2023 5:38 PM, Christian König wrote: > Am 13.01.23 um 06:34 schrieb Ma Jun: >> Use debugfs_remove_recursive to remove the /sys/kernel/debug/ttm >> directory for better compatibility. Becuase debugfs_remove fails >> on older kernel. > > Again NAK for ups

Re: [PATCH 1/2] drm/ttm: Check ttm_debugfs_root before creating files under it

2023-01-15 Thread Ma, Jun
On 1/13/2023 5:37 PM, Christian König wrote: > Am 13.01.23 um 06:34 schrieb Ma Jun: >> Check the ttm_debugfs_root before creating files under it. >> If the ttm_debugfs_root is NULL, all the files created for >> ttm/ will be placed in the /sys/kerne/debug/ but not >

Re: Coverity: kfd_parse_subtype_cache(): Memory - corruptions

2022-11-06 Thread Ma, Jun
Thanks, I will send the fix patch. Regards, Ma Jun On 11/5/2022 4:40 AM, Felix Kuehling wrote: > On 2022-11-04 15:41, coverity-bot wrote: >> Hello! >> >> This is an experimental semi-automated report about issues detected by >> Coverity from a scan of next-20221104 as

[PATCH] drm/amdkfd: Fix the memory overrun

2022-11-06 Thread Ma Jun
Fix the memory overrun issue caused by wrong array size. Signed-off-by: Ma Jun Reported-by: coverity-bot Addresses-Coverity-ID: 1527133 ("Memory - corruptions") Fixes: 624693863 ("drm/amdkfd: Fix the warning of array-index-out-of-bounds") --- drivers/gpu/drm/amd/a

[PATCH] drm/amdkfd: Make kfd_fill_cache_non_crat_info() as static

2022-11-06 Thread Ma Jun
kfd_fill_cache_non_crat_info() is only used in kfd_topology.c, so make it as static. Signed-off-by: Ma Jun Reported-by: kernel test robot --- drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c

Re: [PATCH v3] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-11-01 Thread Ma, Jun
On 10/29/2022 4:17 AM, Felix Kuehling wrote: > On 2022-10-27 04:14, Ma Jun wrote: >> For some GPUs with more CUs, the original sibling_map[32] >> >> in struct crat_subtype_cache is not enough >> >> to save the cache information when create the VCRAT table,

[PATCH v4] drm/amdkfd: Fix the warning of array-index-out-of-bounds

2022-11-01 Thread Ma Jun
the bug when get cache info v3: - Drop processor id calc function v2: - Remove unnecessary sys interface "cache_ext" Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 312 +++--- drivers/gpu/drm/amd/amdkfd/kfd_crat.h | 12 + drivers/gpu/drm/

[PATCH] drm/amdgpu: Fix the warning info when unload or remove amdgpu

2023-02-07 Thread Ma Jun
] Signed-off-by: Ma Jun --- drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c index 466054719842..5fb919cd9330 100644 --- a/drivers/gpu/drm/amd/amdgpu

[PATCH] drm/ttm: Remove redundant code in ttm_tt_init_fields

2023-05-29 Thread Ma Jun
Remove redundant assignment code for ttm->caching Signed-off-by: Ma Jun --- drivers/gpu/drm/ttm/ttm_tt.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/ttm/ttm_tt.c b/drivers/gpu/drm/ttm/ttm_tt.c index 02b812dacc5d..45a44544b656 100644 --- a/drivers/gpu/drm/ttm/ttm_t

  1   2   3   >