drm/amd/pm: Fill ip version for SMU v13.0.12
Subsystems (3)
Alex Deucher
maintainerPATCH 1/2 drm/amd/pm: Fill ip version for SMU v13.0.12
From: Asad Kamal <[email protected]>
Fill ip version in pm_metrics for SMU v13.0.12
Signed-off-by Asad Kamal <[email protected]>
Reviewed-by Hawking Zhang <[email protected]>
Signed-off-by Alex Deucher <[email protected]>
--- drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c +2 -0
@@ -603,6 +603,8 @@ static ssize_t smu_v13_0_6_get_pm_metrics(struct smu_context *smu, pm_metrics->common_header.mp1_ip_discovery_version =IP_VERSION (13 ,0 ,6 );if (amdgpu_ip_version (smu->adev,MP1_HWIP ,0 ) ==IP_VERSION (13 ,0 ,14 )) pm_metrics->common_header.mp1_ip_discovery_version =IP_VERSION (13 ,0 ,14 ); +if (amdgpu_ip_version (smu->adev,MP1_HWIP ,0 ) ==IP_VERSION (13 ,0 ,12 )) + pm_metrics->common_header.mp1_ip_discovery_version =IP_VERSION (13 ,0 ,12 ); pm_metrics->common_header.pmfw_version = pmfw_version; pm_metrics->common_header.pmmetrics_version = table_version; pm_metrics->common_header.structure_size =
Signature · 1 line
2.47.1
Alex Deucher
maintainerPATCH 2/2 drm/amd/pm: Populate pmfw version for SMU v13.0.12
From: Asad Kamal <[email protected]>
Populate pmfw version for SMU v13.0.12 to device struct
v2: Remove ip version check to get smu version
Signed-off-by Asad Kamal <[email protected]>
Reviewed-by Hawking Zhang <[email protected]>
Signed-off-by Alex Deucher <[email protected]>
--- drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c +1 -4
@@ -267,10 +267,7 @@ int smu_v13_0_check_fw_version(struct smu_context *smu) smu_major = (smu_version >>16 ) &0xff ; smu_minor = (smu_version >>8 ) &0xff ; smu_debug = (smu_version >>0 ) &0xff ; -if (smu->is_apu || -amdgpu_ip_version (adev,MP1_HWIP ,0 ) ==IP_VERSION (13 ,0 ,6 ) || -amdgpu_ip_version (adev,MP1_HWIP ,0 ) ==IP_VERSION (13 ,0 ,14 )) - adev->pm.fw_version = smu_version; + adev->pm.fw_version = smu_version;/* only for dGPU w/ SMU13*/ if (adev->pm.fw)
Signature · 1 line
2.47.1
Quoted 16 lines · Alex Deucher
From: Asad Kamal <[email protected]>
Fill ip version in
pm_metricsfor SMU v13.0.12Signed-off-by Asad Kamal <[email protected]>Reviewed-by Hawking Zhang <[email protected]>Signed-off-by Alex Deucher <[email protected]>--- drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c | 2 ++ 1 file changed, 2 insertions(+)drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c +0
-0
drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c static ssize_t smu_v13_0_6_get_pm_metrics(struct smu_context *smu, · line 607
Quoted 5 lines
drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c +2
-0@@ -603,6 +603,8 @@ static ssize_t smu_v13_0_6_get_pm_metrics(struct smu_context *smu, pm_metrics->common_header.mp1_ip_discovery_version =IP_VERSION (13 ,0 ,6 );if (amdgpu_ip_version (smu->adev,MP1_HWIP ,0 ) ==IP_VERSION (13 ,0 ,14 )) pm_metrics->common_header.mp1_ip_discovery_version =IP_VERSION (13 ,0 ,14 ); +if (amdgpu_ip_version (smu->adev,MP1_HWIP ,0 ) ==IP_VERSION (13 ,0 ,12 )) + pm_metrics->common_header.mp1_ip_discovery_version =IP_VERSION (13 ,0 ,12 );
Please remove all if checks and keep
pm_metrics->common_header.mp1_ip_discovery_version =
amdgpu_ip_version(smu->adev, MP1_HWIP, 0);
Thanks,
Lijo
Quoted 3 lines
drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c +0
-0pm_metrics->common_header.pmfw_version = pmfw_version; pm_metrics->common_header.pmmetrics_version = table_version; pm_metrics->common_header.structure_size =