diff options
author | Paulo Zanoni <paulo.r.zanoni@intel.com> | 2016-01-13 13:02:35 -0200 |
---|---|---|
committer | Paulo Zanoni <paulo.r.zanoni@intel.com> | 2016-01-13 13:02:35 -0200 |
commit | bcfbc03520be4075d22a31222b8c3f3ba6b31142 (patch) | |
tree | 5444cc4ab6f5143307e4e7c06e554dedd4c631fa | |
parent | 20d758e3dece1b4d1f4bc5aa767077e13f9075bd (diff) |
drm/i915/fbc: make sure we cancel the work function at fbc_disablefbc-2016-01-13
Just to be sure nothing will survive a module unload. We need to do
this after the unlock in order to make sure the function won't get
stuck trying to grab the lock we already own while we wait for it to
finish.
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
-rw-r--r-- | drivers/gpu/drm/i915/intel_fbc.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/intel_fbc.c b/drivers/gpu/drm/i915/intel_fbc.c index b9cc2127d344..208b77911a0b 100644 --- a/drivers/gpu/drm/i915/intel_fbc.c +++ b/drivers/gpu/drm/i915/intel_fbc.c @@ -1096,6 +1096,8 @@ void intel_fbc_disable(struct intel_crtc *crtc) __intel_fbc_disable(dev_priv); } mutex_unlock(&fbc->lock); + + cancel_work_sync(&fbc->work.work); } /** @@ -1115,6 +1117,8 @@ void intel_fbc_global_disable(struct drm_i915_private *dev_priv) if (fbc->enabled) __intel_fbc_disable(dev_priv); mutex_unlock(&fbc->lock); + + cancel_work_sync(&fbc->work.work); } /** |