From: Paulo Zanoni <paulo.r.zanoni@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: Paulo Zanoni <paulo.r.zanoni@intel.com>
Subject: [PATCH 1/7] drm/i915/fbc: move the intel_fbc_can_choose() call out of the loop
Date: Fri, 11 Nov 2016 14:57:35 -0200 [thread overview]
Message-ID: <1478883461-20201-2-git-send-email-paulo.r.zanoni@intel.com> (raw)
In-Reply-To: <1478883461-20201-1-git-send-email-paulo.r.zanoni@intel.com>
We can just call it earlier, so do it. The goal of the loop is to get
the plane's CRTC state, and we don't need it in order to call
intel_fbc_can_choose().
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
drivers/gpu/drm/i915/intel_fbc.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/i915/intel_fbc.c b/drivers/gpu/drm/i915/intel_fbc.c
index e230d48..ded77bd 100644
--- a/drivers/gpu/drm/i915/intel_fbc.c
+++ b/drivers/gpu/drm/i915/intel_fbc.c
@@ -1096,6 +1096,9 @@ void intel_fbc_choose_crtc(struct drm_i915_private *dev_priv,
if (!intel_plane_state->base.visible)
continue;
+ if (!intel_fbc_can_choose(to_intel_crtc(plane_state->crtc)))
+ continue;
+
for_each_crtc_in_state(state, crtc, crtc_state, j) {
struct intel_crtc_state *intel_crtc_state =
to_intel_crtc_state(crtc_state);
@@ -1103,9 +1106,6 @@ void intel_fbc_choose_crtc(struct drm_i915_private *dev_priv,
if (plane_state->crtc != crtc)
continue;
- if (!intel_fbc_can_choose(to_intel_crtc(crtc)))
- break;
-
intel_crtc_state->enable_fbc = true;
goto out;
}
--
2.7.4
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2016-11-11 16:57 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-11 16:57 [PATCH 0/7] FBC atomic cleanups Paulo Zanoni
2016-11-11 16:57 ` Paulo Zanoni [this message]
2016-11-11 17:33 ` [PATCH 1/7] drm/i915/fbc: move the intel_fbc_can_choose() call out of the loop Chris Wilson
2016-11-11 16:57 ` [PATCH 2/7] drm/i915/fbc: replace a loop with drm_atomic_get_existing_crtc_state() Paulo Zanoni
2016-11-11 17:46 ` Chris Wilson
2016-11-11 18:01 ` Ville Syrjälä
2016-11-11 16:57 ` [PATCH 3/7] drm/i915/fbc: extract intel_fbc_can_enable() Paulo Zanoni
2016-11-11 17:35 ` Chris Wilson
2016-11-11 16:57 ` [PATCH 4/7] drm/i915/fbc: inline intel_fbc_can_choose() Paulo Zanoni
2016-11-11 17:31 ` Chris Wilson
2016-11-11 16:57 ` [PATCH 5/7] drm/i915/fbc: use drm_atomic_get_existing_crtc_state when appropriate Paulo Zanoni
2016-11-11 17:45 ` Chris Wilson
2016-11-11 16:57 ` [PATCH 6/7] drm/i915/fbc: move from crtc_state->enable_fbc to plane_state->enable_fbc Paulo Zanoni
2016-11-11 18:51 ` Ville Syrjälä
2016-11-11 19:01 ` Paulo Zanoni
2016-11-11 19:13 ` Ville Syrjälä
2016-11-11 19:57 ` Paulo Zanoni
2016-11-11 20:24 ` Ville Syrjälä
2016-11-11 20:49 ` Paulo Zanoni
2016-11-14 20:26 ` Ville Syrjälä
2016-11-14 20:49 ` Paulo Zanoni
2016-11-15 9:43 ` Ville Syrjälä
2016-11-11 16:57 ` [PATCH 7/7] drm/i915/fbc: convert intel_fbc.c to use INTEL_GEN() Paulo Zanoni
2016-11-11 17:32 ` Chris Wilson
2016-11-11 17:20 ` ✗ Fi.CI.BAT: warning for FBC atomic cleanups Patchwork
2016-11-14 20:04 ` [PATCH 0/7] " Paulo Zanoni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1478883461-20201-2-git-send-email-paulo.r.zanoni@intel.com \
--to=paulo.r.zanoni@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.