@@ -1097,6 +1097,8 @@ void intel_fbc_enable(struct intel_crtc *crtc,
if (fbc->crtc == crtc) {
WARN_ON(!crtc_state->enable_fbc);
WARN_ON(fbc->active);
+ if (IS_GEN9(dev_priv))
+ intel_wait_for_vblank(dev_priv, crtc->pipe);
}
goto out;
}
@@ -1137,8 +1139,11 @@ void intel_fbc_disable(struct intel_crtc *crtc)
return;
mutex_lock(&fbc->lock);
- if (fbc->crtc == crtc)
+ if (fbc->crtc == crtc) {
__intel_fbc_disable(dev_priv);
+ if (IS_GEN9(dev_priv))
+ intel_wait_for_vblank(dev_priv, crtc->pipe);
+ }
mutex_unlock(&fbc->lock);
}
On Gen9 chromebooks, we are seeing the screen shows several large blue horizontal stripes over the top. Also, corruption happens when we switch from a chrome browser tab to VT2 mode(by pressing Ctrl+Alt+F2) and then back to chrome tab. As per the display workaround #1200, FBC needs wait for vblank before enabling and before disabling FBC. Signed-off-by: Gaurav K Singh <gaurav.k.singh@intel.com> --- drivers/gpu/drm/i915/display/intel_fbc.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)