public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH 1/2] drm/i915/bdw: Use scratch page table for GEN8 PPGTT
@ 2014-03-08 19:58 Ben Widawsky
  2014-03-08 19:58 ` [PATCH 2/2] drm/i915: Correct PPGTT total size Ben Widawsky
  2014-03-08 19:59 ` [PATCH 1/2] drm/i915/bdw: Use scratch page table for GEN8 PPGTT Ben Widawsky
  0 siblings, 2 replies; 9+ messages in thread
From: Ben Widawsky @ 2014-03-08 19:58 UTC (permalink / raw)
  To: Intel GFX; +Cc: Ben Widawsky, Ben Widawsky

I'm not clear if the hardware is still subject to the same prefetching
issues that made us use a scratch page in the first place. In either
case, we're using garbage with the current code (we will end up using
offset 0).

This may be the cause of our current gem_cpu_reloc regression with
PPGTT. I cannot test it at the moment.

Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
---
 drivers/gpu/drm/i915/i915_gem_gtt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
index 5427d6d..0f39090 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
@@ -1169,7 +1169,6 @@ static int gen6_ppgtt_init(struct i915_hw_ppgtt *ppgtt)
 	ppgtt->base.clear_range = gen6_ppgtt_clear_range;
 	ppgtt->base.insert_entries = gen6_ppgtt_insert_entries;
 	ppgtt->base.cleanup = gen6_ppgtt_cleanup;
-	ppgtt->base.scratch = dev_priv->gtt.base.scratch;
 	ppgtt->base.start = 0;
 	ppgtt->base.total = GEN6_PPGTT_PD_ENTRIES * I915_PPGTT_PT_ENTRIES * PAGE_SIZE;
 	ppgtt->debug_dump = gen6_dump_ppgtt;
@@ -1192,6 +1191,7 @@ int i915_gem_init_ppgtt(struct drm_device *dev, struct i915_hw_ppgtt *ppgtt)
 	int ret = 0;
 
 	ppgtt->base.dev = dev;
+	ppgtt->base.scratch = dev_priv->gtt.base.scratch;
 
 	if (INTEL_INFO(dev)->gen < 8)
 		ret = gen6_ppgtt_init(ppgtt);
-- 
1.9.0

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2014-03-11 20:06 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-08 19:58 [PATCH 1/2] drm/i915/bdw: Use scratch page table for GEN8 PPGTT Ben Widawsky
2014-03-08 19:58 ` [PATCH 2/2] drm/i915: Correct PPGTT total size Ben Widawsky
2014-03-11 12:21   ` Chris Wilson
2014-03-11 20:06     ` Daniel Vetter
2014-03-08 19:59 ` [PATCH 1/2] drm/i915/bdw: Use scratch page table for GEN8 PPGTT Ben Widawsky
2014-03-11 12:24   ` Chris Wilson
2014-03-11 16:39     ` Ben Widawsky
2014-03-11 16:46       ` Chris Wilson
2014-03-11 16:56         ` Ben Widawsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox