Age | Commit message (Collapse) | Author |
|
Missed the new method for igt_require(gem_has_contexts()) in the rebase.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
The previous patch said :
"verify that the time is always longer or equal to the period we've
asked for"
This is an obvious error, it only worked on my machine and the CI
because only one longer period was observed. But another CI run caught
the issue :
https://intel-gfx-ci.01.org/tree/drm-tip/IGT_4280/shard-glkb6/igt@perf@oa-exponents.html
Fixes: c3d11ca104fa ("tests/perf: make oa-exponents subtest more reliable")
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
|
|
for chipset support
If the machine doesn't support PSR, it will return -ENODEV from
i915_edp_psr_status, which we want to interpret as unsupported.
This is in line with what Chris just fixed for FBC.
V2: Copy-pasted to the correct place
Signed-off-by: Marta Lofstedt <marta.lofstedt@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
chipset support
If the machine doesn't support PSR, it will return -ENODEV from
i915_edp_psr_status, which we want to interpret as unsupported.
This is in line with what Chris just fixed for FBC.
V2: Copy-pasted to the correct position.
Signed-off-by: Marta Lofstedt <marta.lofstedt@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
My bad,
perf_pmu.c: In function ‘accuracy’:
perf_pmu.c:1533:4: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 5 has type ‘uint64_t’ [-Wformat]
perf_pmu.c:1533:4: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 6 has type ‘uint64_t’ [-Wformat]
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
Apollolake machine in the shards cannot bring the CPU0 back online so
skip the test on all Broxtons for now.
v2: Fix inverted check.
v3: igt_skip_on. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Acked-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Convert the busy pwm from using a single calibration pass with a fixed
target into a self-correcting pwm that tries to adjust how long to sleep
on each pwm in order to converge at the target busy %%.
Being self-correcting, it should fare better against the more variable
systems CI presents.
v2: Be fair and equally strict for low/high busy %%
v3: target_idle_us and calculate expected from timing of each individual pass
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105157
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
If the machine doesn't support FBC, it will return -ENODEV from
i915_fbc_info, which we want to interpret as unsupported.
Reported-by: Marta Lofstedt<marta.lofstedt@intel.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Marta Lofstedt<marta.lofstedt@intel.com>
|
|
A new context assumes that all of its registers are in the default state
when it is created. What may happen is that a register written by one
context may leak into the second, causing mass confusion.
v2: Extend back to Sandybridge (etc)
v3: Check context preserves registers across suspend/hibernate and resets.
v4: Complete the remapping onto the new class:instance
v5: Not like that, like this, try again to use class:instance
v6: Prepare for retrospective gen4 contexts!
v7: Repaint register set name to nonpriv, as this is what bspec calls the
registers that are writable by userspace.
v8: Fix a typo for LRM on gen8
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
We know the OA unit might skip some reports from time to time (reasons
include pressure on memory controller, power management, ...). So
rather than checking that the time between periodic reports is about
the period we asked for, let's verify that the time is always longer
or equal to the period we've asked for.
We still have to leave some room for errors. Here is dump of an error
in this updated test :
(perf:405) DEBUG: report0019 ts=e217de20 hw_id=0x00000014 delta=64
(perf:405) DEBUG: report0020 ts=e217de60 hw_id=0x00000014 delta=64
(perf:405) DEBUG: report0021 ts=e217dea0 hw_id=0x00000014 delta=64
(perf:405) DEBUG: report0022 ts=e217df66 hw_id=0x00000014 delta=198 ******
(perf:405) DEBUG: report0023 ts=e217dfa0 hw_id=0x00000014 delta=58 ******
(perf:405) DEBUG: report0024 ts=e217dfe0 hw_id=0x00000014 delta=64
(perf:405) DEBUG: report0025 ts=e217e020 hw_id=0x00000014 delta=64
(perf:405) DEBUG: report0026 ts=e217e060 hw_id=0x00000014 delta=64
As you can see there is a discrepency in the periodic reports. I have
no explanation for it. This isn't a programming error since the same
context has correct periods before and after, so it must be some kind
of hardware glitch/corner-case that hasn't be been documented.
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
|
|
Ensure that we always use every context at least once before we start
running the stress-test.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
One weird issue we see in bug 104676 is that the hangs are too fast on
HSW! So force the use of the slow spinners that do not try to trigger
a hang by injecting random bytes into the batch.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104676
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
s/16/MAX_ELSP_QLEN/ as appropriate
v2: Use ARRAY_SIZE for loop bounds over fixed size arrays
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
It is useful to dump the request layout between engines help debug
ordering issues and stuck preemption, so add it to preempt_other().
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
icl offers a much reduced context space, and in its simplest setup we
cannot allocate one context per priority level, so trim the number and
reuse the same context for multiple priority requests.
v2: Bump the MAX to 1024 (still lower than the ~4096 previously in use)
v3: Also limit NCTX to MAX_CONTEXTS for wide-*
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Antonio Argenziano <antonio.argenziano@intel.com>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
PSR may not exit instantaneously, so while asserting that PSR is
disabled after an action, we may have to wait a short while. Currently
that wait is waiting for PSR to enabled and expecting to timeout; this
fails when we start the assertion with PSR already enabled. Fix the wait
to wait until PSR is disabled rather than timeout.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Convert from using constant loops of indeterminate loads over to using a
duration based with precise dummyloads, we are able to do more cycles in
less time by limiting the amount of BUSY_LOAD required to exercise the
test.
v2: Bump limits and make the checks tighter.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
This reduces the amount of state to reset on each preparation, and allows
us to keep CRC enabled. With 2 outputs on KBL the test time goes from
approximately 9.2s to 7s on KBL.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
itg_kms already defines an api that creates and colors a new fb, let's
use that instead of recreating that all over again.
Signed-off-by: Carlos Santa <carlos.santa@intel.com>
CC: Jyoti Yadav <jyoti.r.yadav@intel.com>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
|
|
syncobj_basic.c: In function ‘__real_main225’:
syncobj_basic.c:202:26: warning: ‘fd’ may be used uninitialized in this function [-Wmaybe-uninitialized]
syncobj_basic.c:227:6: note: ‘fd’ was declared here
syncobj_wait.c: In function ‘test_wait_complex’:
syncobj_wait.c:702:3: warning: ‘first_signaled’ may be used uninitialized in this function [-Wmaybe-uninitialized]
syncobj_wait.c: In function ‘__real_main758’:
syncobj_wait.c:492:24: warning: ‘timeline’ may be used uninitialized in this function [-Wmaybe-uninitialized]
syncobj_wait.c:473:15: note: ‘timeline’ was declared here
syncobj_wait.c:326:23: warning: ‘timeline’ may be used uninitialized in this function [-Wmaybe-uninitialized]
syncobj_wait.c:320:6: note: ‘timeline’ was declared here
syncobj_wait.c:406:31: warning: ‘fd’ may be used uninitialized in this function [-Wmaybe-uninitialized]
syncobj_wait.c:760:6: note: ‘fd’ was declared here
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
gem_exec_flush.c: In function ‘batch’:
gem_exec_flush.c:443:15: warning: ‘ptr’ may be used uninitialized in this function [-Wmaybe-uninitialized]
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
Don't just wait for the batch to be completed, wait for the system to
idle! Then wake it up and do it again.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
|
|
Correct printf format for uint64_t and one "may be uninitialized".
v2: Fix one more "may be uninitialized". (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reported-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Since the spin batch contains a relocation to itself, when we resubmit
the spinner, we must ensure that it is executed at the same location.
While the spinner is busy, resubmitting will reuse the same location,
but if it is idle, the kernel may move it between execution. In this
case, we need to record the previous location (in obj.offset) and then
demand the kernel reuse the location using EXEC_OBJECT_PINNED.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
We're seeing failures on the CI but we're missing the dump of what has
been read to help us understand what's going wrong.
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Since commit: drm/i915/scheduler: Support user-defined priorities, the
driver support an extra context param to set context's priority. Add
tests for that interface and update invalid tests.
v2:
- Add arg size validation test. (Chris)
- Add arg value overflow test. (Chris)
- Add test for unsupported platforms. (Chris)
- Feed interface with all priority values and in random order. (Chris)
v3:
- Parametrize tests. (Chris)
v4:
- Code-style refactoring. (Chris)
Signed-off-by: Antonio Argenziano <antonio.argenziano@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Michal Winiarski <michal.winiarski@intel.com>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
|
|
A subtest to verify that the engine busyness is reported with expected
accuracy on platforms where the feature is available.
We test three patterns: 2%, 50% and 98% load per engine.
v2:
* Use spin batch instead of nop calibration.
* Various tweaks.
v3:
* Change loops to be time based.
* Use __igt_spin_batch_new inside timing sensitive loops.
* Fixed PWM sleep handling.
v4:
* Use restarting spin batch.
* Calibrate more carefully by looking at the real PWM loop.
v5:
* Made standalone.
* Better info messages.
* Tweak sleep compensation.
v6:
* Some final tweaks. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
We need more data to debug sporadic test failures.
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
When an out-fence is returned we expect that the in-fence is not
overwritten. Add a test to check for that.
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
We get occasional errors like:
(perf_pmu:21315) CRITICAL: Test assertion failure function sema_wait, file perf_pmu.c:631:
(perf_pmu:21315) CRITICAL: Failed assertion: (double)(val[1] - val[0]) <= (1.0 + (tolerance)) * (double)(slept) && (double)(val[1] - val[0]) >= (1.0 - (tolerance)) * (double)(slept)
(perf_pmu:21315) CRITICAL: 'val[1] - val[0]' != 'slept' (450000000.000000 not within 5.000000% tolerance of 500129618.000000)
Suggesting a time disagreement between userspace and the PMU.
At the moment I got no better ideas than fiddling with delays to see if it
improves things.
v2: Wait for sampling to start instead of hardcoded sleep. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Some systems cannot reach the advertised maximum frequency due throttling.
Handle them by considering a 100MHz lower limit.
v2: Use more relaxed tolerance only in the downward direction.
(Chris Wilson)
v3: Improved assert message. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Use perf timestamps in more places where possible.
v2: Log measure_usleep vs perf timestamps. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
ctg/ilk
On ctg/ilk, for whatever reason, MI_STORE_DWORD is a privileged operation
so we must request a SECURE batch.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
We run the per-engine scheduling smoketests across all engines, the
opposite of what was intended!
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: vinay.belgaumkar@intel.com
|
|
The test is modified to test all pixel formats on a plane, unless
the pixel format is overridden by the subtest.
Attempting to test all pixel formats requires even more runtime and
the overhead of toggling crc collection to capture a single CRC
becomes significant, so keep the crc collection enabled during the entire test.
This reduces the runtime from ~24s to ~16s per subtest on SKL.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
This seems to open code igt_calc_fb_size and igt_create_fb, just use both.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
This won't clean up resources between subtests, so if subtests fail
the next subtest will clean up everything. This allows all subtests
even if one fails.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
This is already tested by the rotation tests, which require Y-tiled
for 90° and 270° rotations.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
The -flip tests are the same, but with a pageflip at the end,
since the test is otherwise the same, run the test once with flips
always enabled when possible.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
Instead of 2 functions doing the same thing, consolidate to a single function.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
bad-tiling test didn't work, LOCAL_DRM_FORMAT_MODE_NONE == 0, so
the fb was created with tiling = Y, but because test_bad_format
was set but override_tiling wasn't, we fell through to the success
case. Always assume failure if test_bad_format is set, and pass X
tiled for fb, so the format override works.
Also clear variables after subtests in main, so if the next subtest
doesn't run we still clear the variables.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
Collecting CRC may result in a modeset and extra vblank waits. On some
tests this will increase the runtime a lot, so it makes sense to
keep it enabled, and only collect the most recent CRC when needed.
Changes since v1:
- Fix read_crc semantics. (Ville)
Changes since v2:
- Remove EAGAIN assert, can be reached from drain_crc.
Changes since v3:
- Do not infinitely loop in igt_pipe_crc_drain().
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com> #v2
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
This makes it possible to iterate whether a format is supported or not,
without each driver having to open code it.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
This cleans up the tests slightly.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
|
|
We don't expect to be able to open the I915_SAMPLE_SEMA on gen5 and
earlier as the HW doesn't support semaphores.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
During the startup, we try to determine if the system supports rc6 prior
to testing. However, the startup check asserts the residency debugfs
exists, instead of testing for a requirement.
v2: Throw in some passing indentation cleanups.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
Make sure we test every plane on the pipe, and only report a SKIP
if none of the planes support CCS (or the pixel format).
Cc: Gabriel Krisman Bertazi <krisman@collabora.co.uk>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104724
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Marta Lofstedt<marta.lofstedt@intel.com>
|
|
There's no need to house fb and fb_sprite in the data_t. Just suck
them into try_config(). Much cleaner since we no longer have to match
the fb setup done in try_config() in test_output(). Also I think doing
multiple try_config()s (like done by TEST_CRC) would leak one of the
primary fbs.
Cc: Gabriel Krisman Bertazi <krisman@collabora.co.uk>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Marta Lofstedt<marta.lofstedt@intel.com>
|
|
Test to check that the RC6 counter works as expected during and after
runtime suspend.
v2:
* Use correct sysfs root by using IGT helpers.
* Turn off display to allow runtime suspend. (Imre)
* Two subtest flavours.
v3:
* drmModeFreeResources. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|