mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-02 05:07:46 -04:00
drm/amd/pm: fix rpm refcount handling on error
pm_runtime_put_autosuspend must be called from all exit paths. Tested-by: Mario Limonciello <mario.limonciello@amd.com> Reviewed-by: Kenneth Feng <kenneth.feng@amd.com> Signed-off-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
committed by
Alex Deucher
parent
e15ec812b5
commit
b0fca32755
@@ -1815,6 +1815,8 @@ static ssize_t amdgpu_set_apu_thermal_cap(struct device *dev,
|
||||
|
||||
ret = amdgpu_dpm_set_apu_thermal_limit(adev, value);
|
||||
if (ret) {
|
||||
pm_runtime_mark_last_busy(ddev->dev);
|
||||
pm_runtime_put_autosuspend(ddev->dev);
|
||||
dev_err(dev, "failed to update thermal limit\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user