drm/amdgpu: update the handle ptr in resume
Update the *handle to amdgpu_ip_block ptr for all functions pointers of resume. Signed-off-by: Sunil Khatri <sunil.khatri@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
982d7f9bfe
commit
7feb4f3ad8
88 changed files with 182 additions and 182 deletions
|
@ -246,7 +246,7 @@ static int aldebaran_mode2_restore_ip(struct amdgpu_device *adev)
|
|||
dev_err(adev->dev, "Failed to get BIF handle\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
r = cmn_block->version->funcs->resume(adev);
|
||||
r = cmn_block->version->funcs->resume(cmn_block);
|
||||
if (r)
|
||||
return r;
|
||||
|
||||
|
@ -282,7 +282,7 @@ static int aldebaran_mode2_restore_ip(struct amdgpu_device *adev)
|
|||
adev->ip_blocks[i].version->type ==
|
||||
AMD_IP_BLOCK_TYPE_SDMA))
|
||||
continue;
|
||||
r = adev->ip_blocks[i].version->funcs->resume(adev);
|
||||
r = adev->ip_blocks[i].version->funcs->resume(&adev->ip_blocks[i]);
|
||||
if (r) {
|
||||
dev_err(adev->dev,
|
||||
"resume of IP block <%s> failed %d\n",
|
||||
|
|
|
@ -575,9 +575,9 @@ static int acp_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int acp_resume(void *handle)
|
||||
static int acp_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
/* power down again on resume */
|
||||
if (!adev->acp.acp_cell)
|
||||
|
|
|
@ -2744,7 +2744,7 @@ static int amdgpu_device_fw_loading(struct amdgpu_device *adev)
|
|||
break;
|
||||
|
||||
if (amdgpu_in_reset(adev) || adev->in_suspend) {
|
||||
r = adev->ip_blocks[i].version->funcs->resume(adev);
|
||||
r = adev->ip_blocks[i].version->funcs->resume(&adev->ip_blocks[i]);
|
||||
if (r) {
|
||||
DRM_ERROR("resume of IP block <%s> failed %d\n",
|
||||
adev->ip_blocks[i].version->funcs->name, r);
|
||||
|
@ -3666,7 +3666,7 @@ static int amdgpu_device_ip_reinit_late_sriov(struct amdgpu_device *adev)
|
|||
continue;
|
||||
|
||||
if (block->version->type == AMD_IP_BLOCK_TYPE_SMC)
|
||||
r = block->version->funcs->resume(adev);
|
||||
r = block->version->funcs->resume(&adev->ip_blocks[i]);
|
||||
else
|
||||
r = block->version->funcs->hw_init(adev);
|
||||
|
||||
|
@ -3704,7 +3704,7 @@ static int amdgpu_device_ip_resume_phase1(struct amdgpu_device *adev)
|
|||
adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_IH ||
|
||||
(adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_PSP && amdgpu_sriov_vf(adev))) {
|
||||
|
||||
r = adev->ip_blocks[i].version->funcs->resume(adev);
|
||||
r = adev->ip_blocks[i].version->funcs->resume(&adev->ip_blocks[i]);
|
||||
if (r) {
|
||||
DRM_ERROR("resume of IP block <%s> failed %d\n",
|
||||
adev->ip_blocks[i].version->funcs->name, r);
|
||||
|
@ -3742,7 +3742,7 @@ static int amdgpu_device_ip_resume_phase2(struct amdgpu_device *adev)
|
|||
adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_IH ||
|
||||
adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_PSP)
|
||||
continue;
|
||||
r = adev->ip_blocks[i].version->funcs->resume(adev);
|
||||
r = adev->ip_blocks[i].version->funcs->resume(&adev->ip_blocks[i]);
|
||||
if (r) {
|
||||
DRM_ERROR("resume of IP block <%s> failed %d\n",
|
||||
adev->ip_blocks[i].version->funcs->name, r);
|
||||
|
|
|
@ -88,7 +88,7 @@ static int isp_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int isp_resume(void *handle)
|
||||
static int isp_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -3089,10 +3089,10 @@ out:
|
|||
return ret;
|
||||
}
|
||||
|
||||
static int psp_resume(void *handle)
|
||||
static int psp_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int ret;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
struct psp_context *psp = &adev->psp;
|
||||
|
||||
dev_info(adev->dev, "PSP is resuming...\n");
|
||||
|
|
|
@ -880,9 +880,9 @@ static int umsch_mm_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return umsch_mm_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int umsch_mm_resume(void *handle)
|
||||
static int umsch_mm_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return umsch_mm_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -616,12 +616,12 @@ static int amdgpu_vkms_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_vkms_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int amdgpu_vkms_resume(void *handle)
|
||||
static int amdgpu_vkms_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r;
|
||||
|
||||
r = amdgpu_vkms_hw_init(handle);
|
||||
r = amdgpu_vkms_hw_init(adev);
|
||||
if (r)
|
||||
return r;
|
||||
return drm_mode_config_helper_resume(adev_to_drm(adev));
|
||||
|
|
|
@ -443,9 +443,9 @@ static int vpe_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return vpe_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int vpe_resume(void *handle)
|
||||
static int vpe_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return vpe_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -2160,9 +2160,9 @@ static int cik_common_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return cik_common_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int cik_common_resume(void *handle)
|
||||
static int cik_common_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return cik_common_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -344,9 +344,9 @@ static int cik_ih_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return cik_ih_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int cik_ih_resume(void *handle)
|
||||
static int cik_ih_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return cik_ih_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -1018,11 +1018,11 @@ static int cik_sdma_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return cik_sdma_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int cik_sdma_resume(void *handle)
|
||||
static int cik_sdma_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
cik_sdma_soft_reset(handle);
|
||||
cik_sdma_soft_reset(ip_block);
|
||||
|
||||
return cik_sdma_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -340,9 +340,9 @@ static int cz_ih_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return cz_ih_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int cz_ih_resume(void *handle)
|
||||
static int cz_ih_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return cz_ih_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -2920,15 +2920,15 @@ static int dce_v10_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return dce_v10_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int dce_v10_0_resume(void *handle)
|
||||
static int dce_v10_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int ret;
|
||||
|
||||
amdgpu_atombios_encoder_set_backlight_level_to_reg(adev,
|
||||
adev->mode_info.bl_level);
|
||||
|
||||
ret = dce_v10_0_hw_init(handle);
|
||||
ret = dce_v10_0_hw_init(adev);
|
||||
|
||||
/* turn on the BL */
|
||||
if (adev->mode_info.bl_encoder) {
|
||||
|
|
|
@ -3058,15 +3058,15 @@ static int dce_v11_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return dce_v11_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int dce_v11_0_resume(void *handle)
|
||||
static int dce_v11_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int ret;
|
||||
|
||||
amdgpu_atombios_encoder_set_backlight_level_to_reg(adev,
|
||||
adev->mode_info.bl_level);
|
||||
|
||||
ret = dce_v11_0_hw_init(handle);
|
||||
ret = dce_v11_0_hw_init(adev);
|
||||
|
||||
/* turn on the BL */
|
||||
if (adev->mode_info.bl_encoder) {
|
||||
|
|
|
@ -2815,15 +2815,15 @@ static int dce_v6_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return dce_v6_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int dce_v6_0_resume(void *handle)
|
||||
static int dce_v6_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int ret;
|
||||
|
||||
amdgpu_atombios_encoder_set_backlight_level_to_reg(adev,
|
||||
adev->mode_info.bl_level);
|
||||
|
||||
ret = dce_v6_0_hw_init(handle);
|
||||
ret = dce_v6_0_hw_init(adev);
|
||||
|
||||
/* turn on the BL */
|
||||
if (adev->mode_info.bl_encoder) {
|
||||
|
|
|
@ -2838,15 +2838,15 @@ static int dce_v8_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return dce_v8_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int dce_v8_0_resume(void *handle)
|
||||
static int dce_v8_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int ret;
|
||||
|
||||
amdgpu_atombios_encoder_set_backlight_level_to_reg(adev,
|
||||
adev->mode_info.bl_level);
|
||||
|
||||
ret = dce_v8_0_hw_init(handle);
|
||||
ret = dce_v8_0_hw_init(adev);
|
||||
|
||||
/* turn on the BL */
|
||||
if (adev->mode_info.bl_encoder) {
|
||||
|
|
|
@ -7463,9 +7463,9 @@ static int gfx_v10_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gfx_v10_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gfx_v10_0_resume(void *handle)
|
||||
static int gfx_v10_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
return gfx_v10_0_hw_init(handle);
|
||||
return gfx_v10_0_hw_init(ip_block->adev);
|
||||
}
|
||||
|
||||
static bool gfx_v10_0_is_idle(void *handle)
|
||||
|
|
|
@ -4712,9 +4712,9 @@ static int gfx_v11_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gfx_v11_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gfx_v11_0_resume(void *handle)
|
||||
static int gfx_v11_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
return gfx_v11_0_hw_init(handle);
|
||||
return gfx_v11_0_hw_init(ip_block->adev);
|
||||
}
|
||||
|
||||
static bool gfx_v11_0_is_idle(void *handle)
|
||||
|
|
|
@ -3650,9 +3650,9 @@ static int gfx_v12_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gfx_v12_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gfx_v12_0_resume(void *handle)
|
||||
static int gfx_v12_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
return gfx_v12_0_hw_init(handle);
|
||||
return gfx_v12_0_hw_init(ip_block->adev);
|
||||
}
|
||||
|
||||
static bool gfx_v12_0_is_idle(void *handle)
|
||||
|
|
|
@ -3160,9 +3160,9 @@ static int gfx_v6_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gfx_v6_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gfx_v6_0_resume(void *handle)
|
||||
static int gfx_v6_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return gfx_v6_0_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -4506,9 +4506,9 @@ static int gfx_v7_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gfx_v7_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gfx_v7_0_resume(void *handle)
|
||||
static int gfx_v7_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return gfx_v7_0_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -4924,9 +4924,9 @@ static int gfx_v8_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gfx_v8_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gfx_v8_0_resume(void *handle)
|
||||
static int gfx_v8_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
return gfx_v8_0_hw_init(handle);
|
||||
return gfx_v8_0_hw_init(ip_block->adev);
|
||||
}
|
||||
|
||||
static bool gfx_v8_0_check_soft_reset(struct amdgpu_ip_block *ip_block)
|
||||
|
|
|
@ -4081,9 +4081,9 @@ static int gfx_v9_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gfx_v9_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gfx_v9_0_resume(void *handle)
|
||||
static int gfx_v9_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
return gfx_v9_0_hw_init(handle);
|
||||
return gfx_v9_0_hw_init(ip_block->adev);
|
||||
}
|
||||
|
||||
static bool gfx_v9_0_is_idle(void *handle)
|
||||
|
|
|
@ -2393,9 +2393,9 @@ static int gfx_v9_4_3_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gfx_v9_4_3_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gfx_v9_4_3_resume(void *handle)
|
||||
static int gfx_v9_4_3_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
return gfx_v9_4_3_hw_init(handle);
|
||||
return gfx_v9_4_3_hw_init(ip_block->adev);
|
||||
}
|
||||
|
||||
static bool gfx_v9_4_3_is_idle(void *handle)
|
||||
|
|
|
@ -1062,10 +1062,10 @@ static int gmc_v10_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int gmc_v10_0_resume(void *handle)
|
||||
static int gmc_v10_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = gmc_v10_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -970,10 +970,10 @@ static int gmc_v11_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int gmc_v11_0_resume(void *handle)
|
||||
static int gmc_v11_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = gmc_v11_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -954,10 +954,10 @@ static int gmc_v12_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int gmc_v12_0_resume(void *handle)
|
||||
static int gmc_v12_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = gmc_v12_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -944,10 +944,10 @@ static int gmc_v6_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int gmc_v6_0_resume(void *handle)
|
||||
static int gmc_v6_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = gmc_v6_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -1120,10 +1120,10 @@ static int gmc_v7_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int gmc_v7_0_resume(void *handle)
|
||||
static int gmc_v7_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = gmc_v7_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -1251,10 +1251,10 @@ static int gmc_v8_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int gmc_v8_0_resume(void *handle)
|
||||
static int gmc_v8_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = gmc_v8_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -2435,10 +2435,10 @@ static int gmc_v9_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return gmc_v9_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int gmc_v9_0_resume(void *handle)
|
||||
static int gmc_v9_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = gmc_v9_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -334,9 +334,9 @@ static int iceland_ih_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return iceland_ih_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int iceland_ih_resume(void *handle)
|
||||
static int iceland_ih_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return iceland_ih_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -651,9 +651,9 @@ static int ih_v6_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return ih_v6_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int ih_v6_0_resume(void *handle)
|
||||
static int ih_v6_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return ih_v6_0_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -630,9 +630,9 @@ static int ih_v6_1_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return ih_v6_1_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int ih_v6_1_resume(void *handle)
|
||||
static int ih_v6_1_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return ih_v6_1_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -620,9 +620,9 @@ static int ih_v7_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return ih_v7_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int ih_v7_0_resume(void *handle)
|
||||
static int ih_v7_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return ih_v7_0_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -187,10 +187,10 @@ static int jpeg_v2_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init JPEG block
|
||||
*/
|
||||
static int jpeg_v2_0_resume(void *handle)
|
||||
static int jpeg_v2_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_jpeg_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -256,9 +256,9 @@ static int jpeg_v2_5_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init JPEG block
|
||||
*/
|
||||
static int jpeg_v2_5_resume(void *handle)
|
||||
static int jpeg_v2_5_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r;
|
||||
|
||||
r = amdgpu_jpeg_resume(adev);
|
||||
|
|
|
@ -201,9 +201,9 @@ static int jpeg_v3_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init JPEG block
|
||||
*/
|
||||
static int jpeg_v3_0_resume(void *handle)
|
||||
static int jpeg_v3_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r;
|
||||
|
||||
r = amdgpu_jpeg_resume(adev);
|
||||
|
|
|
@ -235,9 +235,9 @@ static int jpeg_v4_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init JPEG block
|
||||
*/
|
||||
static int jpeg_v4_0_resume(void *handle)
|
||||
static int jpeg_v4_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r;
|
||||
|
||||
r = amdgpu_jpeg_resume(adev);
|
||||
|
|
|
@ -405,9 +405,9 @@ static int jpeg_v4_0_3_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init JPEG block
|
||||
*/
|
||||
static int jpeg_v4_0_3_resume(void *handle)
|
||||
static int jpeg_v4_0_3_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r;
|
||||
|
||||
r = amdgpu_jpeg_resume(adev);
|
||||
|
|
|
@ -262,9 +262,9 @@ static int jpeg_v4_0_5_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init JPEG block
|
||||
*/
|
||||
static int jpeg_v4_0_5_resume(void *handle)
|
||||
static int jpeg_v4_0_5_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r;
|
||||
|
||||
r = amdgpu_jpeg_resume(adev);
|
||||
|
|
|
@ -198,9 +198,9 @@ static int jpeg_v5_0_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init JPEG block
|
||||
*/
|
||||
static int jpeg_v5_0_0_resume(void *handle)
|
||||
static int jpeg_v5_0_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r;
|
||||
|
||||
r = amdgpu_jpeg_resume(adev);
|
||||
|
|
|
@ -1641,10 +1641,10 @@ static int mes_v11_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return mes_v11_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int mes_v11_0_resume(void *handle)
|
||||
static int mes_v11_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = mes_v11_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -1605,10 +1605,10 @@ static int mes_v12_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return mes_v12_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int mes_v12_0_resume(void *handle)
|
||||
static int mes_v12_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = mes_v12_0_hw_init(adev);
|
||||
if (r)
|
||||
|
|
|
@ -625,9 +625,9 @@ static int navi10_ih_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return navi10_ih_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int navi10_ih_resume(void *handle)
|
||||
static int navi10_ih_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return navi10_ih_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -1036,9 +1036,9 @@ static int nv_common_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return nv_common_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int nv_common_resume(void *handle)
|
||||
static int nv_common_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return nv_common_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -908,9 +908,9 @@ static int sdma_v2_4_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return sdma_v2_4_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int sdma_v2_4_resume(void *handle)
|
||||
static int sdma_v2_4_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return sdma_v2_4_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -1195,9 +1195,9 @@ static int sdma_v3_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return sdma_v3_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int sdma_v3_0_resume(void *handle)
|
||||
static int sdma_v3_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return sdma_v3_0_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -2001,9 +2001,9 @@ static int sdma_v4_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return sdma_v4_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int sdma_v4_0_resume(void *handle)
|
||||
static int sdma_v4_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
/* SMU restores SDMA state for us */
|
||||
if (adev->in_s0ix) {
|
||||
|
|
|
@ -1518,9 +1518,9 @@ static int sdma_v4_4_2_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return sdma_v4_4_2_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int sdma_v4_4_2_resume(void *handle)
|
||||
static int sdma_v4_4_2_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return sdma_v4_4_2_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -1509,9 +1509,9 @@ static int sdma_v5_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return sdma_v5_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int sdma_v5_0_resume(void *handle)
|
||||
static int sdma_v5_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return sdma_v5_0_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -1409,9 +1409,9 @@ static int sdma_v5_2_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return sdma_v5_2_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int sdma_v5_2_resume(void *handle)
|
||||
static int sdma_v5_2_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return sdma_v5_2_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -1407,9 +1407,9 @@ static int sdma_v6_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return sdma_v6_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int sdma_v6_0_resume(void *handle)
|
||||
static int sdma_v6_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return sdma_v6_0_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -1365,9 +1365,9 @@ static int sdma_v7_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return sdma_v7_0_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int sdma_v7_0_resume(void *handle)
|
||||
static int sdma_v7_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return sdma_v7_0_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -2657,9 +2657,9 @@ static int si_common_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return si_common_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int si_common_resume(void *handle)
|
||||
static int si_common_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return si_common_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -540,9 +540,9 @@ static int si_dma_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return si_dma_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int si_dma_resume(void *handle)
|
||||
static int si_dma_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return si_dma_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -209,9 +209,9 @@ static int si_ih_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return si_ih_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int si_ih_resume(void *handle)
|
||||
static int si_ih_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return si_ih_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -175,7 +175,7 @@ static int sienna_cichlid_mode2_restore_ip(struct amdgpu_device *adev)
|
|||
|
||||
for (i = 0; i < adev->num_ip_blocks; i++) {
|
||||
if (adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_IH) {
|
||||
r = adev->ip_blocks[i].version->funcs->resume(adev);
|
||||
r = adev->ip_blocks[i].version->funcs->resume(&adev->ip_blocks[i]);
|
||||
if (r) {
|
||||
dev_err(adev->dev,
|
||||
"resume of IP block <%s> failed %d\n",
|
||||
|
@ -193,7 +193,7 @@ static int sienna_cichlid_mode2_restore_ip(struct amdgpu_device *adev)
|
|||
adev->ip_blocks[i].version->type ==
|
||||
AMD_IP_BLOCK_TYPE_SDMA))
|
||||
continue;
|
||||
r = adev->ip_blocks[i].version->funcs->resume(adev);
|
||||
r = adev->ip_blocks[i].version->funcs->resume(&adev->ip_blocks[i]);
|
||||
if (r) {
|
||||
dev_err(adev->dev,
|
||||
"resume of IP block <%s> failed %d\n",
|
||||
|
|
|
@ -186,7 +186,7 @@ static int smu_v13_0_10_mode2_restore_ip(struct amdgpu_device *adev)
|
|||
adev->ip_blocks[i].version->type ==
|
||||
AMD_IP_BLOCK_TYPE_SDMA))
|
||||
continue;
|
||||
r = adev->ip_blocks[i].version->funcs->resume(adev);
|
||||
r = adev->ip_blocks[i].version->funcs->resume(&adev->ip_blocks[i]);
|
||||
if (r) {
|
||||
dev_err(adev->dev,
|
||||
"resume of IP block <%s> failed %d\n",
|
||||
|
|
|
@ -1325,9 +1325,9 @@ static int soc15_common_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return soc15_common_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int soc15_common_resume(void *handle)
|
||||
static int soc15_common_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
if (soc15_need_reset_on_resume(adev)) {
|
||||
dev_info(adev->dev, "S3 suspend abort case, let's reset ASIC.\n");
|
||||
|
|
|
@ -917,9 +917,9 @@ static bool soc21_need_reset_on_resume(struct amdgpu_device *adev)
|
|||
return false;
|
||||
}
|
||||
|
||||
static int soc21_common_resume(void *handle)
|
||||
static int soc21_common_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
if (soc21_need_reset_on_resume(adev)) {
|
||||
dev_info(adev->dev, "S3 suspend aborted, resetting...");
|
||||
|
|
|
@ -519,9 +519,9 @@ static int soc24_common_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return soc24_common_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int soc24_common_resume(void *handle)
|
||||
static int soc24_common_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return soc24_common_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -352,9 +352,9 @@ static int tonga_ih_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return tonga_ih_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int tonga_ih_resume(void *handle)
|
||||
static int tonga_ih_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return tonga_ih_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -747,10 +747,10 @@ static int uvd_v3_1_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_uvd_suspend(adev);
|
||||
}
|
||||
|
||||
static int uvd_v3_1_resume(void *handle)
|
||||
static int uvd_v3_1_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_uvd_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -261,10 +261,10 @@ static int uvd_v4_2_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_uvd_suspend(adev);
|
||||
}
|
||||
|
||||
static int uvd_v4_2_resume(void *handle)
|
||||
static int uvd_v4_2_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_uvd_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -259,10 +259,10 @@ static int uvd_v5_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_uvd_suspend(adev);
|
||||
}
|
||||
|
||||
static int uvd_v5_0_resume(void *handle)
|
||||
static int uvd_v5_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_uvd_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -583,10 +583,10 @@ static int uvd_v6_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_uvd_suspend(adev);
|
||||
}
|
||||
|
||||
static int uvd_v6_0_resume(void *handle)
|
||||
static int uvd_v6_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_uvd_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -651,10 +651,10 @@ static int uvd_v7_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_uvd_suspend(adev);
|
||||
}
|
||||
|
||||
static int uvd_v7_0_resume(void *handle)
|
||||
static int uvd_v7_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_uvd_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -526,10 +526,10 @@ static int vce_v2_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_vce_suspend(adev);
|
||||
}
|
||||
|
||||
static int vce_v2_0_resume(void *handle)
|
||||
static int vce_v2_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vce_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -540,10 +540,10 @@ static int vce_v3_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_vce_suspend(adev);
|
||||
}
|
||||
|
||||
static int vce_v3_0_resume(void *handle)
|
||||
static int vce_v3_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vce_resume(adev);
|
||||
if (r)
|
||||
|
@ -726,7 +726,7 @@ static int vce_v3_0_post_soft_reset(struct amdgpu_ip_block *ip_block)
|
|||
|
||||
mdelay(5);
|
||||
|
||||
return vce_v3_0_resume(adev);
|
||||
return vce_v3_0_resume(ip_block);
|
||||
}
|
||||
|
||||
static int vce_v3_0_set_interrupt_state(struct amdgpu_device *adev,
|
||||
|
|
|
@ -606,9 +606,9 @@ static int vce_v4_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return amdgpu_vce_suspend(adev);
|
||||
}
|
||||
|
||||
static int vce_v4_0_resume(void *handle)
|
||||
static int vce_v4_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r, idx;
|
||||
|
||||
if (adev->vce.vcpu_bo == NULL)
|
||||
|
|
|
@ -322,10 +322,10 @@ static int vcn_v1_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init VCN block
|
||||
*/
|
||||
static int vcn_v1_0_resume(void *handle)
|
||||
static int vcn_v1_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vcn_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -351,10 +351,10 @@ static int vcn_v2_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init VCN block
|
||||
*/
|
||||
static int vcn_v2_0_resume(void *handle)
|
||||
static int vcn_v2_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vcn_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -436,10 +436,10 @@ static int vcn_v2_5_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init VCN block
|
||||
*/
|
||||
static int vcn_v2_5_resume(void *handle)
|
||||
static int vcn_v2_5_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vcn_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -468,10 +468,10 @@ static int vcn_v3_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init VCN block
|
||||
*/
|
||||
static int vcn_v3_0_resume(void *handle)
|
||||
static int vcn_v3_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vcn_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -397,10 +397,10 @@ static int vcn_v4_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init VCN block
|
||||
*/
|
||||
static int vcn_v4_0_resume(void *handle)
|
||||
static int vcn_v4_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vcn_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -352,9 +352,9 @@ static int vcn_v4_0_3_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init VCN block
|
||||
*/
|
||||
static int vcn_v4_0_3_resume(void *handle)
|
||||
static int vcn_v4_0_3_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
int r;
|
||||
|
||||
r = amdgpu_vcn_resume(adev);
|
||||
|
|
|
@ -345,10 +345,10 @@ static int vcn_v4_0_5_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init VCN block
|
||||
*/
|
||||
static int vcn_v4_0_5_resume(void *handle)
|
||||
static int vcn_v4_0_5_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vcn_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -309,10 +309,10 @@ static int vcn_v5_0_0_suspend(struct amdgpu_ip_block *ip_block)
|
|||
*
|
||||
* Resume firmware and hw init VCN block
|
||||
*/
|
||||
static int vcn_v5_0_0_resume(void *handle)
|
||||
static int vcn_v5_0_0_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
r = amdgpu_vcn_resume(adev);
|
||||
if (r)
|
||||
|
|
|
@ -557,9 +557,9 @@ static int vega10_ih_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return vega10_ih_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int vega10_ih_resume(void *handle)
|
||||
static int vega10_ih_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return vega10_ih_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -623,9 +623,9 @@ static int vega20_ih_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return vega20_ih_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int vega20_ih_resume(void *handle)
|
||||
static int vega20_ih_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return vega20_ih_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -1738,9 +1738,9 @@ static int vi_common_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return vi_common_hw_fini(adev);
|
||||
}
|
||||
|
||||
static int vi_common_resume(void *handle)
|
||||
static int vi_common_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
return vi_common_hw_init(adev);
|
||||
}
|
||||
|
|
|
@ -3124,9 +3124,9 @@ cleanup:
|
|||
kfree(bundle);
|
||||
}
|
||||
|
||||
static int dm_resume(void *handle)
|
||||
static int dm_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
struct drm_device *ddev = adev_to_drm(adev);
|
||||
struct amdgpu_display_manager *dm = &adev->dm;
|
||||
struct amdgpu_dm_connector *aconnector;
|
||||
|
|
|
@ -389,7 +389,7 @@ struct amd_ip_funcs {
|
|||
void (*late_fini)(struct amdgpu_ip_block *ip_block);
|
||||
int (*prepare_suspend)(struct amdgpu_ip_block *ip_block);
|
||||
int (*suspend)(struct amdgpu_ip_block *ip_block);
|
||||
int (*resume)(void *handle);
|
||||
int (*resume)(struct amdgpu_ip_block *ip_block);
|
||||
bool (*is_idle)(void *handle);
|
||||
int (*wait_for_idle)(struct amdgpu_ip_block *ip_block);
|
||||
bool (*check_soft_reset)(struct amdgpu_ip_block *ip_block);
|
||||
|
|
|
@ -3075,10 +3075,10 @@ static int kv_dpm_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int kv_dpm_resume(void *handle)
|
||||
static int kv_dpm_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int ret;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
if (adev->pm.dpm_enabled) {
|
||||
/* asic init will reset to the boot state */
|
||||
|
|
|
@ -7818,10 +7818,10 @@ static int si_dpm_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int si_dpm_resume(void *handle)
|
||||
static int si_dpm_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int ret;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
|
||||
if (adev->pm.dpm_enabled) {
|
||||
/* asic init will reset to the boot state */
|
||||
|
|
|
@ -271,9 +271,9 @@ static int pp_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return hwmgr_suspend(hwmgr);
|
||||
}
|
||||
|
||||
static int pp_resume(void *handle)
|
||||
static int pp_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
struct amdgpu_device *adev = handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
struct pp_hwmgr *hwmgr = adev->powerplay.pp_handle;
|
||||
|
||||
return hwmgr_resume(hwmgr);
|
||||
|
|
|
@ -2109,10 +2109,10 @@ static int smu_suspend(struct amdgpu_ip_block *ip_block)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int smu_resume(void *handle)
|
||||
static int smu_resume(struct amdgpu_ip_block *ip_block)
|
||||
{
|
||||
int ret;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
struct amdgpu_device *adev = ip_block->adev;
|
||||
struct smu_context *smu = adev->powerplay.pp_handle;
|
||||
|
||||
if (amdgpu_sriov_vf(adev)&& !amdgpu_sriov_is_pp_one_vf(adev))
|
||||
|
|
Loading…
Add table
Reference in a new issue