summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/radeon/radeon_kms.c
diff options
context:
space:
mode:
authorLukas Wunner <lukas@wunner.de>2016-06-08 18:47:27 +0200
committerDaniel Vetter <daniel.vetter@ffwll.ch>2016-06-24 08:49:26 +0200
commit55c868a322fd8687884f0192da8b997d443cad07 (patch)
treeb4793ad6f0ad13c72bc503e9b6d8c0f90ab2bebf /drivers/gpu/drm/radeon/radeon_kms.c
parentc1b16b45607976c76a3c41b8a319172b8b83f996 (diff)
drm/nouveau: Forbid runtime pm on driver unload
The PCI core calls pm_runtime_forbid() on device probe in pci_pm_init(), making this the default state when nouveau is loaded. nouveau_drm_load() therefore calls pm_runtime_allow(), but there's no pm_runtime_forbid() in nouveau_drm_unload() to balance it. Add it so that we leave the device in the same state that we found it. This isn't a bug, it's just good housekeeping. When nouveau is first loaded with runpm=1, then unloaded and loaded again with runpm=0, pm_runtime_forbid() will be called from nouveau_pmops_runtime_idle() or nouveau_pmops_runtime_suspend(), so the behaviour is correct. The nvidia blob doesn't use runtime pm, but if it ever does, this commit avoids that it has to clean up behind nouveau. Cc: Ben Skeggs <bskeggs@redhat.com> Tested-by: Karol Herbst <karolherbst@gmail.com> Tested-by: Peter Wu <peter@lekensteyn.nl> Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/92cf96445088217a4d7d7081b90140f2d6f047da.1465392124.git.lukas@wunner.de
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_kms.c')
0 files changed, 0 insertions, 0 deletions