[Intel-gfx] [PATCH 7/7] drm/i915/selftests: check for missing aperture
Chris Wilson
chris at chris-wilson.co.uk
Tue Oct 29 10:09:08 UTC 2019
Quoting Matthew Auld (2019-10-29 09:58:56)
> We may be missing support for the mappable aperture on some platforms.
>
> Signed-off-by: Matthew Auld <matthew.auld at intel.com>
> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio at intel.com>
> ---
> .../drm/i915/gem/selftests/i915_gem_coherency.c | 5 ++++-
> drivers/gpu/drm/i915/gem/selftests/i915_gem_mman.c | 6 ++++++
> drivers/gpu/drm/i915/gt/selftest_hangcheck.c | 14 ++++++++++----
> drivers/gpu/drm/i915/selftests/i915_gem.c | 4 ++++
> drivers/gpu/drm/i915/selftests/i915_gem_gtt.c | 3 +++
> 5 files changed, 27 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/gem/selftests/i915_gem_coherency.c b/drivers/gpu/drm/i915/gem/selftests/i915_gem_coherency.c
> index 0a195e5b98e6..279e9047bc6d 100644
> --- a/drivers/gpu/drm/i915/gem/selftests/i915_gem_coherency.c
> +++ b/drivers/gpu/drm/i915/gem/selftests/i915_gem_coherency.c
> @@ -250,7 +250,10 @@ static bool always_valid(struct context *ctx)
>
> static bool needs_fence_registers(struct context *ctx)
> {
I vote for a struct intel_gt *gt = ctx->engine->gt;
> - return !intel_gt_is_wedged(ctx->engine->gt);
> + if (intel_gt_is_wedged(ctx->engine->gt))
> + return false;
> +
> + return ctx->engine->gt->ggtt->num_fences;
> }
Reviewed-by: Chris Wilson <chris at chris-wilson.co.uk>
-Chris
More information about the Intel-gfx
mailing list