]> Git Repo - linux.git/commitdiff
drm/i915/gt: Assert the kernel context is using the HWSP
authorChris Wilson <[email protected]>
Tue, 14 Jul 2020 11:44:19 +0000 (12:44 +0100)
committerChris Wilson <[email protected]>
Wed, 15 Jul 2020 09:18:29 +0000 (10:18 +0100)
We need to ensure that the kernel context is using the permanently pinned
HWSP so that we can always submit a pm request from any context. By
construction, the engine->kernel_context should only be using the
engine->status_page.vma so let's assert that is still true when we have
to submit a request for parking the engine.

Signed-off-by: Chris Wilson <[email protected]>
Cc: Tvrtko Ursulin <[email protected]>
Reviewed-by: Mika Kuoppala <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
drivers/gpu/drm/i915/gt/intel_engine_pm.c

index d0a1078ef63249909960efb336f951b2c911a6df..8ec3eecf3e397d0cda63fa33d47366e6f6818cbb 100644 (file)
@@ -142,6 +142,7 @@ static bool switch_to_kernel_context(struct intel_engine_cs *engine)
                return true;
 
        GEM_BUG_ON(!intel_context_is_barrier(ce));
+       GEM_BUG_ON(ce->timeline->hwsp_ggtt != engine->status_page.vma);
 
        /* Already inside the kernel context, safe to power down. */
        if (engine->wakeref_serial == engine->serial)
This page took 0.061898 seconds and 4 git commands to generate.