drm/amd/powerplay: move the smc_if_version to asic file
Subsystems (2)
PATCH 1/1 drm/amd/powerplay: move the smc_if_version to asic file
each asic may be has different smc if version,
so move its to asic file to implement.
--- drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h | 2 ++ drivers/gpu/drm/amd/powerplay/smu_v11_0.c | 4 ++-- drivers/gpu/drm/amd/powerplay/vega20_ppt.c | 1 + 3 files changed, 5 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h +2 -0
@@ -401,6 +401,8 @@ struct smu_contextuint32_t workload_setting[WORKLOAD_POLICY_MAX ];uint32_t power_profile_mode;uint32_t default_power_profile_mode; + +uint32_t smc_if_version; };struct pptable_funcs {
drivers/gpu/drm/amd/powerplay/smu_v11_0.c +2 -2
@@ -224,8 +224,8 @@ static int smu_v11_0_check_fw_version(struct smu_context *smu)if (ret) goto err; -if (smu_version ==SMU11_DRIVER_IF_VERSION ) -return 0 ; +if (smu_version != smu->smc_if_version) + ret = -EINVAL ; err:return ret; }
drivers/gpu/drm/amd/powerplay/vega20_ppt.c +1 -0
@@ -2704,4 +2704,5 @@ static const struct pptable_funcs vega20_ppt_funcs = {void vega20_set_ppt_funcs (struct smu_context *smu) { smu->ppt_funcs = &vega20_ppt_funcs; + smu->smc_if_version =SMU11_DRIVER_IF_VERSION ; }
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 1552273553-28570-1-git-send-email-kevin1.wang-5C7GfCeVMHo@public.gmane.org
Huang, Ray
Reviewed-by Huang RuiQuoted 8 lines
-----Original Message-----
From: Wang, Kevin(Yang)
Sent: Monday, March 11, 2019 11:06 AM
To: [email protected]
Cc: Huang, Ray <[email protected]>; Wang, Kevin(Yang) <[email protected]>
Subject: [PATCH] drm/amd/powerplay: move thesmc_if_versionto asic file
Quoted 4 lines
each asic may be has different smc if version, so move its to asic file to implement.
Signed-off-by Kevin Wang <[email protected]>
Quoted 48 lines
--- drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h | 2 ++ drivers/gpu/drm/amd/powerplay/smu_v11_0.c | 4 ++-- drivers/gpu/drm/amd/powerplay/vega20_ppt.c | 1 + 3 files changed, 5 insertions(+), 2 deletions(-)drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h +2
-0@@ -401,6 +401,8 @@ struct smu_contextuint32_t workload_setting[WORKLOAD_POLICY_MAX ];uint32_t power_profile_mode;uint32_t default_power_profile_mode; + +uint32_t smc_if_version; };struct pptable_funcs {drivers/gpu/drm/amd/powerplay/smu_v11_0.c +2
-2@@ -224,8 +224,8 @@ static int smu_v11_0_check_fw_version(struct smu_context *smu)if (ret) goto err; -if (smu_version ==SMU11_DRIVER_IF_VERSION ) -return 0 ; +if (smu_version != smu->smc_if_version) + ret = -EINVAL ; err:return ret;}
drivers/gpu/drm/amd/powerplay/vega20_ppt.c +1
-1@@ -2704,4 +2704,5 @@ static const struct pptable_funcs vega20_ppt_funcs = { void vega20_set_ppt_funcs(struct smu_context *smu) { smu->ppt_funcs = &vega20_ppt_funcs; + smu->smc_if_version =SMU11_DRIVER_IF_VERSION ; } --
Quoted 1 line
2.7.4
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx