diff options
author | Alex Deucher <alexander.deucher@amd.com> | 2016-08-31 17:23:31 -0400 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-09-02 10:34:49 -0400 |
commit | 9b96b63fed542598054dbf249360d413f7bd6059 (patch) | |
tree | 0e146274991d56ad83acd9d1a6b3bc1ab96d2ec1 /drivers/gpu/drm/radeon/radeon_kms.c | |
parent | d6bda7b4b4997f1062844dbc8b47708d244c10be (diff) | |
download | op-kernel-dev-9b96b63fed542598054dbf249360d413f7bd6059.zip op-kernel-dev-9b96b63fed542598054dbf249360d413f7bd6059.tar.gz |
drm/radeon: handle runtime pm in drm pre/post close
Close was not handled correctly.
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_kms.c')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_kms.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c index 0aa8eac..4388dde 100644 --- a/drivers/gpu/drm/radeon/radeon_kms.c +++ b/drivers/gpu/drm/radeon/radeon_kms.c @@ -718,6 +718,8 @@ void radeon_driver_postclose_kms(struct drm_device *dev, kfree(fpriv); file_priv->driver_priv = NULL; } + pm_runtime_mark_last_busy(dev->dev); + pm_runtime_put_autosuspend(dev->dev); } /** @@ -734,6 +736,8 @@ void radeon_driver_preclose_kms(struct drm_device *dev, { struct radeon_device *rdev = dev->dev_private; + pm_runtime_get_sync(dev->dev); + mutex_lock(&rdev->gem.mutex); if (rdev->hyperz_filp == file_priv) rdev->hyperz_filp = NULL; |