Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 62cf4e6f authored by Chris Wilson's avatar Chris Wilson
Browse files

drm/i915/overlay: Destroy reg_bo on shutdown.

parent a2930128
Loading
Loading
Loading
Loading
+9 −7
Original line number Diff line number Diff line
@@ -1461,15 +1461,17 @@ void intel_cleanup_overlay(struct drm_device *dev)
{
	drm_i915_private_t *dev_priv = dev->dev_private;

	if (dev_priv->overlay) {
	if (!dev_priv->overlay)
		return;

	/* The bo's should be free'd by the generic code already.
	 * Furthermore modesetting teardown happens beforehand so the
	 * hardware should be off already */
	BUG_ON(dev_priv->overlay->active);

	drm_gem_object_unreference_unlocked(&dev_priv->overlay->reg_bo->base);
	kfree(dev_priv->overlay);
}
}

struct intel_overlay_error_state {
	struct overlay_registers regs;