]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
drm/i915/fbc: Clear frontbuffer busy bits on flip
authorJouni Högander <jouni.hogander@intel.com>
Fri, 1 Sep 2023 09:34:57 +0000 (12:34 +0300)
committerJouni Högander <jouni.hogander@intel.com>
Mon, 4 Sep 2023 09:03:07 +0000 (12:03 +0300)
We are planning to move flush performed from work queue. This
means it is possible to have invalidate -> flip -> flush sequence.
Handle this by clearing possible busy bits on flip.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Jouni Högander <jouni.hogander@intel.com>
Reviewed-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230901093500.3463046-2-jouni.hogander@intel.com
drivers/gpu/drm/i915/display/intel_fbc.c

index 1c6d467cec267c0339d7390b2470b54d152c1562..817e5784660baf47cbc3535cee017e02cd6110e1 100644 (file)
@@ -1307,11 +1307,9 @@ static void __intel_fbc_post_update(struct intel_fbc *fbc)
        lockdep_assert_held(&fbc->lock);
 
        fbc->flip_pending = false;
+       fbc->busy_bits = 0;
 
-       if (!fbc->busy_bits)
-               intel_fbc_activate(fbc);
-       else
-               intel_fbc_deactivate(fbc, "frontbuffer write");
+       intel_fbc_activate(fbc);
 }
 
 void intel_fbc_post_update(struct intel_atomic_state *state,