Age | Commit message (Collapse) | Author |
|
intel_gen is designed to return a big unsigned number for an unknown device.
The value is interpreted to be the newest generation possible, and the matching
configuration is used. Some functions incorrectly pass the gen value as a signed
number, meaning it becomes negative, and the oldest configuration is used
instead of the newest one. This leads to GPU hangs in some cases.
Update the definition of submit functions in gem_exec_gttfill and gem_softpin,
and has_cs_timestamp in gem_ctx_engines to use a correct type for gen parameter.
Signed-off-by: Karolina Drobnik <karolina.drobnik@intel.com>
Cc: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
|
|
Not supported on discrete. Here the object will already have the GTT
caching bits enabled, and the mapping will be WB, which looks inline
with what the test is expecting here.
Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/4926
Signed-off-by: Matthew Auld <matthew.auld@intel.com>
Cc: Nirmoy Das <nirmoy.das@linux.intel.com>
Reviewed-by: Nirmoy Das <nirmoy.das@intel.com>
|
|
Resolved __gem_execbuf error seen, by passing spin->execbuf.rsvd2 >> 32.
As we are creating ctx for each engine .
Error resolved:-
(gem_ctx_engines:4117) CRITICAL: Failed assertion: __gem_execbuf(i915, &execbuf) == expected
(gem_ctx_engines:4117) CRITICAL: Failed to report the valid engine for slot 0 (valid at 0)
Introducing IGT_SPIN_FENCE_OUT means we can stop using the
no-preemption in spinner. Added
I915_EXEC_FENCE_IN to the execbuf.flags so that it
is executed after the spinner.
This is enhancement to the code .
Cc: Chris Wilson <chris.p.wilson@intel.com>
Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Signed-off-by: Arjun Melkaveri <arjun.melkaveri@intel.com>
Reviewed-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
|
|
For newer gens we're not able to rely on relocations. Adopt to use
offsets acquired from the allocator.
Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Cc: Petri Latvala <petri.latvala@intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
|
|
Since we no longer allow setting engines multiple times on one context,
we need to create a new context every time. We've also got more invalid
cases that need testing.
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
|
|
Instead of relying on the context param, check for the device query or
attempt to set engines as a create param.
v2 (Jason Ekstrand):
- Add a common gem_has_context_engines helper
v3 (Jason Ekstrand):
- Drop gem_has_context_engines and always check I915_QUERY_ENGINE_INFO
v4 (Ashutosh Dixit):
- Add a comment to the gem_has_engine_topology docs saying that it can
be used to query either feature.
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
|
|
It just tests enumeration APIs that we're about to delete.
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
|
|
This just tests the engines CONTEXT_GETPARAM which we're going to be
dropping from i915.
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
|
|
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
|
|
Instead of switching out the set of engines constantly, create a new
context for every set of engines. This means, among other things, that
there's no point in testing whether or not the context is in a "default"
because there's no more resetting it.
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
|
|
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
|
|
Add a wrapper for gem_create_ext ioctl (a version of gem_create that
accepts extensions). In preparation for the driver change implementing it,
a local definition of its id and necessary structs have been added,
which are to be erased as soon as those definitions
appear in the i915_drm.h file.
The new ioctl wrapper is added to a separate file.
For consistency the wrapper of the old ioctl, gem_create
is moved from ioctl_wrappers to gem_create.
Signed-off-by: Andrzej Turko <andrzej.turko@linux.intel.com>
Cc: Zbigniew Kempczynski <zbigniew.kempczynski@intel.com>
Cc: Dominik Grzegorzek <dominik.grzegorzek@intel.com>
Cc: Petri Latvala <petri.latvala@intel.com>
Cc: Chris P Wilson <chris.p.wilson@intel.com>
Signed-off-by: Matthew Auld <matthew.auld@intel.com>
Acked-by: Petri Latvala <petri.latvala@intel.com>
|
|
If the engine does not support MI_STORE_DWORD, we cannot use
IGT_SPIN_POLL_RUN. For simplicity, skip testing that engine, slightly
better than skipping the entire test at least.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
Set the spinner and target execbuf up before we start the test; this not
only saves time in recreating the spinner on each loop, but it ensures
that we don't antagonise ourselves by fighting over GTT offsets.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Venkata Sandeep Dhanalakota <venkata.s.dhanalakota@intel.com>
Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
Skip reading CS_TIMESTAMP on Sandybridge/bcs as it doesn't exist.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Don't rely on just rcs0 being well defined, check that we return a list
of each engine when asked.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: "Melkaveri, Arjun" <arjun.melkaveri@intel.com>
Reviewed-by: Arjun Melkaveri <arjun.melkaveri@intel.com>
|
|
Run the 'independent' subtest on all all engines.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Andi Shyti <andi.shyti@intel.com>
|
|
We want to recognise future devices (gen = -1u) and treat them as an
extension of the latest known device, which is typically true.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
|
|
If we are using GPU relocations, then the batch may legitimately be marked
as having been written to by the GPU. As this is expected, remove the
write marker, which may be a different engine to that we execute on, and
the corresponding read engine if different.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
igt_require_gem() is a pecularity of i915/, move it out of the core.
Similar opportunistic move of gem_reopen_driver() and
gem_quiescent_gpu().
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Set up a custom engine map with no engines, and check that the
for_each_context_engine() correctly iterates over nothing.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
Setup a context with no engines, and make sure we reject all execution
attempts.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
It suffices to use any mmap-offset generated pointer for our invalid
pointers, not just gem_map__gtt, as the crucial part is the faulthandler
vs revocation and is the same for all mmap-offsets.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
No need to memset(0) the mapping of a fresh buffer, as we expect it to
be 0 already.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chuansheng Liu <chuansheng.liu@intel.com>
|
|
As Braswell is using aliasing-ppgtt, softpinning is trick as we have to
avoid overlapping with HW objects in the GGTT (like context images).
Typically allocations are from either end, so if we provide a hint to
use the middle, we should be safe from overlap.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
To run the independent subtests requires to issue the requests
not-in-submission order, we need a scheduler.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
The intent of the test is to exercise that each channel in the engine[]
is an independent context/ring/timeline. It setups 64 channels pointing
to rcs0 and then submits one request to each in turn waiting on a
timeline that will force them to run out of submission order. They can
only run in fence order and not submission order if the timelines of
each channel are truly independent.
However, we released the fences en masse, and once the requests are
ready they are independent and may be executed in any order by the HW,
especially true with timeslicing that may reorder the requests on a
whim. So instead of releasing all requests at once, increment the
timeline step by step and check we get our results advancing. If the
requests can not be run in fence order and fall back to submission
order, we will time out waiting for our incremental results and trigger
a few GPU hangs.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110987
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Andi Shyti <andi.shyti@intel.com>
|
|
In order to pin the engine as busy, we have to prevent the kernel from
executing other independent work ahead of our plug, so tell the spinner
to not allow preemption.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
|
|
The per-engine TIMESTAMP (at least at the offset I know about) only came
into being with gen6. So skip the test on older gen as the results are
garbage.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110874
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
To exercise the new I915_CONTEXT_PARAM_ENGINES and interactions with
gem_execbuf().
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
Cc: Andi Shyti <andi@etezian.org>
Reviewed-by: Andi Shyti <andi@etezian.org>
|