From: Paulo Zanoni <przanoni@gmail.com>
To: intel-gfx@lists.freedesktop.org
Cc: Paulo Zanoni <paulo.r.zanoni@intel.com>
Subject: [PATCH 2/4] drm/i915: add workarounds directly to gen6_render_ring_flush
Date: Fri, 17 Aug 2012 18:35:42 -0300 [thread overview]
Message-ID: <1345239344-9968-3-git-send-email-przanoni@gmail.com> (raw)
In-Reply-To: <1345239344-9968-1-git-send-email-przanoni@gmail.com>
From: Paulo Zanoni <paulo.r.zanoni@intel.com>
Since gen 7+ now run the new gen7_render_ring_flush function.
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
drivers/gpu/drm/i915/intel_ringbuffer.c | 21 ++++++---------------
1 file changed, 6 insertions(+), 15 deletions(-)
diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.c b/drivers/gpu/drm/i915/intel_ringbuffer.c
index 32e3034..dc5272b 100644
--- a/drivers/gpu/drm/i915/intel_ringbuffer.c
+++ b/drivers/gpu/drm/i915/intel_ringbuffer.c
@@ -218,6 +218,11 @@ gen6_render_ring_flush(struct intel_ring_buffer *ring,
u32 scratch_addr = pc->gtt_offset + 128;
int ret;
+ /* Force SNB workarounds for PIPE_CONTROL flushes */
+ ret = intel_emit_post_sync_nonzero_flush(ring);
+ if (ret)
+ return ret;
+
/* Just flush everything. Experiments have shown that reducing the
* number of bits based on the write domains has little performance
* impact.
@@ -305,20 +310,6 @@ gen7_render_ring_flush(struct intel_ring_buffer *ring,
return 0;
}
-static int
-gen6_render_ring_flush__wa(struct intel_ring_buffer *ring,
- u32 invalidate_domains, u32 flush_domains)
-{
- int ret;
-
- /* Force SNB workarounds for PIPE_CONTROL flushes */
- ret = intel_emit_post_sync_nonzero_flush(ring);
- if (ret)
- return ret;
-
- return gen6_render_ring_flush(ring, invalidate_domains, flush_domains);
-}
-
static void ring_write_tail(struct intel_ring_buffer *ring,
u32 value)
{
@@ -1435,7 +1426,7 @@ int intel_init_render_ring_buffer(struct drm_device *dev)
ring->add_request = gen6_add_request;
ring->flush = gen7_render_ring_flush;
if (INTEL_INFO(dev)->gen == 6)
- ring->flush = gen6_render_ring_flush__wa;
+ ring->flush = gen6_render_ring_flush;
ring->irq_get = gen6_ring_get_irq;
ring->irq_put = gen6_ring_put_irq;
ring->irq_enable_mask = GT_USER_INTERRUPT;
--
1.7.11.2
next prev parent reply other threads:[~2012-08-17 21:35 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-17 21:35 [PATCH 0/4] Haswell GPU hang fixes Paulo Zanoni
2012-08-17 21:35 ` [PATCH 1/4] drm/i915: add gen7_render_ring_flush Paulo Zanoni
2012-08-17 21:35 ` Paulo Zanoni [this message]
2012-08-17 21:35 ` [PATCH 3/4] drm/i915: add workaround to gen7_render_ring_flush Paulo Zanoni
2012-08-28 9:17 ` Daniel Vetter
2012-08-28 13:10 ` Paulo Zanoni
2012-08-28 15:17 ` Daniel Vetter
2012-08-17 21:35 ` [PATCH 4/4] drm/i915: add one more " Paulo Zanoni
2012-08-17 22:39 ` [PATCH 0/4] Haswell GPU hang fixes Ben Widawsky
2012-08-17 22:42 ` Paulo Zanoni
2012-08-17 22:53 ` Ben Widawsky
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=1345239344-9968-3-git-send-email-przanoni@gmail.com \
--to=przanoni@gmail.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=paulo.r.zanoni@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox