Skip to contentSkip to conversation

drm/i915/bdw: Always issue a force restore

PATCH Superseded Ben Widawsky 2 participants 4 messages May 28, 2014 – May 29, 2014 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

PATCH v2 1/1 drm/i915/bdw: Always issue a force restore

The PDPs seem to get screwed up otherwise, specifically PDP0. I am not really clear why this is required, it just works with full PPGTT.

v2: Only do it for gen8, to limit regression potential

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78891
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78934
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78935
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78936
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78937

---
 drivers/gpu/drm/i915/i915_gem_context.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/gpu/drm/i915/i915_gem_context.c +3 -0
index 3ffe308..c5330ab 100644
@@ -568,6 +568,9 @@ mi_set_context(struct intel_engine_cs *ring,
 	else
 		intel_ring_emit(ring, MI_NOOP);
 
+	if (INTEL_INFO(ring->dev)->gen == 8)
+		hw_flags |= MI_FORCE_RESTORE;
+
 	intel_ring_emit(ring, MI_NOOP);
 	intel_ring_emit(ring, MI_SET_CONTEXT);
 	intel_ring_emit(ring, i915_gem_obj_ggtt_offset(new_context->obj) |
Signature · 1 line
1.9.3
#2 lore raw

PATCH v3 1/1 drm/i915/bdw: Always issue a force restore

In reply to a message not in the archive

The PDPs seem to get screwed up otherwise, specifically PDP0. I am not really clear why this is required, it just works with full PPGTT.

v2: Only do it for gen8, to limit regression potential

v3: Fix the bugzilla links

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78891
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78935
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78936
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78937
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78938

---
 drivers/gpu/drm/i915/i915_gem_context.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/gpu/drm/i915/i915_gem_context.c +3 -0
index 3ffe308..c5330ab 100644
@@ -568,6 +568,9 @@ mi_set_context(struct intel_engine_cs *ring,
 	else
 		intel_ring_emit(ring, MI_NOOP);
 
+	if (INTEL_INFO(ring->dev)->gen == 8)
+		hw_flags |= MI_FORCE_RESTORE;
+
 	intel_ring_emit(ring, MI_NOOP);
 	intel_ring_emit(ring, MI_SET_CONTEXT);
 	intel_ring_emit(ring, i915_gem_obj_ggtt_offset(new_context->obj) |
Signature · 1 line
1.9.3
#3 lore raw
Quoted 6 lines · Ben Widawsky

The PDPs seem to get screwed up otherwise, specifically PDP0. I am not really clear why this is required, it just works with full PPGTT.

v2: Only do it for gen8, to limit regression potential

v3: Fix the bugzilla links

I should note there is a problem with this patch. Without full PPGTT, we also do a restore inhibit on the default context, and therefore any test which is running and not using contexts (like everything in IGT) is programming restore inhibit as well as force restore, which as has been pointed out in the semaphore series is weird at best.

All I know is the patch fixed at least a few of the bugs mentioned below. I guess we'll figure out what to do when the QA results come in.

[snip]

Signature · 1 line
Ben Widawsky, Intel Open Source Technology Center
#4 lore raw
Quoted 14 lines · Ben Widawsky
Quoted 6 lines · Ben Widawsky

The PDPs seem to get screwed up otherwise, specifically PDP0. I am not really clear why this is required, it just works with full PPGTT.

v2: Only do it for gen8, to limit regression potential

v3: Fix the bugzilla links

I should note there is a problem with this patch. Without full PPGTT, we also do a restore inhibit on the default context, and therefore any test which is running and not using contexts (like everything in IGT) is programming restore inhibit as well as force restore, which as has been pointed out in the semaphore series is weird at best.

Quoted 5 lines

All I know is the patch fixed at least a few of the bugs mentioned below. I guess we'll figure out what to do when the QA results come in.

[snip]

Okay, now I am really confused. I've changed machines and none of these tests are passing for me now. Until I figured out what happened, please ignore this thread. Sorry for the noise.

Signature · 1 line
Ben Widawsky, Intel Open Source Technology Center