]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/gen9: Fix runtime PM refcounting in case DMC firmware isn't loaded
authorImre Deak <imre.deak@intel.com>
Mon, 18 Apr 2016 11:48:21 +0000 (14:48 +0300)
committerImre Deak <imre.deak@intel.com>
Tue, 19 Apr 2016 09:33:48 +0000 (12:33 +0300)
commitf70c58b822eb5f89934cb7302b4f9e6773525c73
tree3dc05c647eae7669f66089bb37d996e0a07ae22e
parent06d8ea458a283520e900273c236022f4a6bcbd74
drm/i915/gen9: Fix runtime PM refcounting in case DMC firmware isn't loaded

While we disable runtime PM and with that display power well support if
the DMC firmware isn't loaded, we still want to disable power wells
during system suspend and driver unload. So drop/reacquire the
corresponding power refcount during suspend/resume and driver unloading.
This also means we have to check if DMC is not loaded and skip enabling
DC states in the power well code.

v2:
- Reuse intel_csr_ucode_suspend() in intel_csr_ucode_fini() instead of
  opencoding the former. (Chris)
- Add docbook comment to the public resume and suspend functions.

CC: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: http://patchwork.freedesktop.org/patch/msgid/1460980101-14713-1-git-send-email-imre.deak@intel.com
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/intel_csr.c
drivers/gpu/drm/i915/intel_drv.h
drivers/gpu/drm/i915/intel_runtime_pm.c