Commit 82088d5d authored by Alex Deucher's avatar Alex Deucher

drm/amdgpu/pp/smu7: remove local mc_addr variable

use the structure member directly.
Acked-by: default avatarChristian König <christian.koenig@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 2bce4be0
...@@ -571,7 +571,6 @@ int smu7_setup_pwr_virus(struct pp_hwmgr *hwmgr) ...@@ -571,7 +571,6 @@ int smu7_setup_pwr_virus(struct pp_hwmgr *hwmgr)
int smu7_init(struct pp_hwmgr *hwmgr) int smu7_init(struct pp_hwmgr *hwmgr)
{ {
struct smu7_smumgr *smu_data; struct smu7_smumgr *smu_data;
uint64_t mc_addr = 0;
int r; int r;
/* Allocate memory for backend private data */ /* Allocate memory for backend private data */
smu_data = (struct smu7_smumgr *)(hwmgr->smu_backend); smu_data = (struct smu7_smumgr *)(hwmgr->smu_backend);
...@@ -585,14 +584,12 @@ int smu7_init(struct pp_hwmgr *hwmgr) ...@@ -585,14 +584,12 @@ int smu7_init(struct pp_hwmgr *hwmgr)
PAGE_SIZE, PAGE_SIZE,
AMDGPU_GEM_DOMAIN_VRAM, AMDGPU_GEM_DOMAIN_VRAM,
&smu_data->header_buffer.handle, &smu_data->header_buffer.handle,
&mc_addr, &smu_data->header_buffer.mc_addr,
&smu_data->header_buffer.kaddr); &smu_data->header_buffer.kaddr);
if (r) if (r)
return -EINVAL; return -EINVAL;
smu_data->header_buffer.mc_addr = mc_addr;
if (!hwmgr->not_vf) if (!hwmgr->not_vf)
return 0; return 0;
...@@ -602,7 +599,7 @@ int smu7_init(struct pp_hwmgr *hwmgr) ...@@ -602,7 +599,7 @@ int smu7_init(struct pp_hwmgr *hwmgr)
PAGE_SIZE, PAGE_SIZE,
AMDGPU_GEM_DOMAIN_VRAM, AMDGPU_GEM_DOMAIN_VRAM,
&smu_data->smu_buffer.handle, &smu_data->smu_buffer.handle,
&mc_addr, &smu_data->smu_buffer.mc_addr,
&smu_data->smu_buffer.kaddr); &smu_data->smu_buffer.kaddr);
if (r) { if (r) {
...@@ -611,7 +608,6 @@ int smu7_init(struct pp_hwmgr *hwmgr) ...@@ -611,7 +608,6 @@ int smu7_init(struct pp_hwmgr *hwmgr)
&smu_data->header_buffer.kaddr); &smu_data->header_buffer.kaddr);
return -EINVAL; return -EINVAL;
} }
smu_data->smu_buffer.mc_addr = mc_addr;
if (smum_is_hw_avfs_present(hwmgr)) if (smum_is_hw_avfs_present(hwmgr))
hwmgr->avfs_supported = true; hwmgr->avfs_supported = true;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment