WARN_ON(!mutex_is_locked(&dev_priv->fbc.lock));
- if (!dev_priv->display.enable_fbc)
- return;
-
intel_fbc_cancel_work(dev_priv);
work = kzalloc(sizeof(*work), GFP_KERNEL);
intel_fbc_cancel_work(dev_priv);
- if (!dev_priv->display.disable_fbc)
- return;
-
dev_priv->display.disable_fbc(dev);
dev_priv->fbc.crtc = NULL;
}
{
struct drm_i915_private *dev_priv = dev->dev_private;
+ if (!dev_priv->display.enable_fbc)
+ return;
+
mutex_lock(&dev_priv->fbc.lock);
__intel_fbc_disable(dev);
mutex_unlock(&dev_priv->fbc.lock);
struct drm_device *dev = crtc->base.dev;
struct drm_i915_private *dev_priv = dev->dev_private;
+ if (!dev_priv->display.enable_fbc)
+ return;
+
mutex_lock(&dev_priv->fbc.lock);
if (dev_priv->fbc.crtc == crtc)
__intel_fbc_disable(dev);
{
struct drm_i915_private *dev_priv = dev->dev_private;
+ if (!dev_priv->display.enable_fbc)
+ return;
+
mutex_lock(&dev_priv->fbc.lock);
__intel_fbc_cleanup_cfb(dev);
mutex_unlock(&dev_priv->fbc.lock);
const struct drm_display_mode *adjusted_mode;
unsigned int max_width, max_height;
- if (!HAS_FBC(dev))
- return;
-
WARN_ON(!mutex_is_locked(&dev_priv->fbc.lock));
/* disable framebuffer compression in vGPU */
{
struct drm_i915_private *dev_priv = dev->dev_private;
+ if (!dev_priv->display.enable_fbc)
+ return;
+
mutex_lock(&dev_priv->fbc.lock);
__intel_fbc_update(dev);
mutex_unlock(&dev_priv->fbc.lock);
struct drm_device *dev = dev_priv->dev;
unsigned int fbc_bits;
+ if (!dev_priv->display.enable_fbc)
+ return;
+
if (origin == ORIGIN_GTT)
return;
{
struct drm_device *dev = dev_priv->dev;
+ if (!dev_priv->display.enable_fbc)
+ return;
+
mutex_lock(&dev_priv->fbc.lock);
if (!dev_priv->fbc.busy_bits)