Age | Commit message (Collapse) | Author | Files | Lines |
|
This is another piece of prep work to push the detection of dmesg
warnings into igt itself, so that we can correctly report dmesg
issue on a per-subtest basis even when running the entire binary.
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Needs to be beefed up so that dmesg warning (and worse) are re-emmitted
as IGT_LOG_WARN. But only if they match one of our filters (which we
should probably allow to be extended, e.g. depending upon which driver
has been openened). This also requires that we at least parse the
basic of kmsg lines (adjusting the timestamp to match our own would be
real cool).
v2:
- Seek to the end of the kmsg buffer before starting the capturing.
- Increase linebuffer to avoid dmesg drowning out all the tests
messages.
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
I think this is the more sensible semantics, since this allows you to
still follow what's going on with the test at a high level, while
filtering for a specific (or multiple specific) debug log domains.
For non-debug messages log-domains technically exist, but we're not
making much use of them really.
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
fork() is a pretty thing in a multithreaded program, it's essentially
as bad as handling signals: When we fork the memory snapshot we can
interrupts all other threads at any place, including while they're
holding mutexes and other fun stuff.
libc itself has some internal fork handlers to clear caches and make
sure locks stay in a safe place (we've had plenty of fun with e.g. the
pid/tid caches when a signal happens too fast).
I want to put dmesg capture into igt, into a separate thread (so that
dmesg capture nicely interleaves what the test is doing, +/- races),
and stuff all the dmesg output into the igt logger. Which means we
need to make sure that the log_buffer_mutex is in a predictable state.
Since we have 2 calls to fork() extract a little helper for this.
v2: Stop using fflush(NULL) - somehow this manages to hit a bug in
libc when using a FILE in a separate thread (for capturing dmesg).
Instead explicitly flush stderr and stdout only.
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
I'll need to wrap a bit of magic around all the fork() calls in our
tests. Simplest way to get there is to roll out the existing helpers,
which even saves a bit of boilerplate code.
Cc: Robert Foss <robert.foss@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
The waitboost subtests encode internal knowledge of the kernel, and
should we wish to change how the kernel functions, we also need to
update the test (or reconfigure it somehow to express desired latencies
for certain workloads). One such change proposed is to remove the
waitboost if the target request is also completed, so update the test to
not wait on the current batch.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
As we allow more buffers to be allocated to fill larger apertures, we
may exceed the static allocation of 4096 buffers.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104669
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
Fetch the configuration values in the toplevel meson.build for all
subdirs to share.
v2: Also remember tests/intel-ci/meson.build
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Noticed while I was reading it. Makes for a good first contribution, I
guess.
Changes in v2:
- None
Changes in v3:
- None
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
|
|
Add a subtest to display primary and overlay planes on two
connected pipes and runs scaling test on both pipes
Changes since v1:
- Commit first before trying any scaling. (Maarten)
- Use the same logic as kms_cursor_legacy to find a pipe and output. (Maarten)
- Rework test to work with how cleanup is handled. (Maarten)
Changes since v2:
- Use get_num_scalers() to only use 2 scalers if available. (Maarten)
Signed-off-by: Jyoti Yadav <jyoti.r.yadav@intel.com>
Signed-off-by: Mahesh Kumar <mahesh1.kumar@intel.com>
Signed-off-by: Vidya Srinivas <vidya.srinivas@intel.com>
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
This patch adds subtest to test scaler clipping and clamping
scenario.
Changes since v1:
- Modify test to work with the changes to kms_plane_scaling. (Maarten)
Changes since v2:
- Use get_num_scalers() to skip when needed.
Signed-off-by: Jyoti Yadav <jyoti.r.yadav@intel.com>
Signed-off-by: Mahesh Kumar <mahesh1.kumar@intel.com>
Signed-off-by: Vidya Srinivas <vidya.srinivas@intel.com>
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
formats, v3.
This patch adds subtest for testing scaling in combination with rotation
and pixel formats.
Changes since v1:
- Rework test to work with the other changes to kms_plane_scaling. (Maarten)
- Remove hardcodes for MIN/MAX_SRC_WIDTH, and use the value directly. (Maarten)
Changes since v2:
- Put rotation and tiling in an array. (Maarten)
Signed-off-by: Jyoti Yadav <jyoti.r.yadav@intel.com>
Signed-off-by: Mahesh Kumar <mahesh1.kumar@intel.com>
Signed-off-by: Vidya Srinivas <vidya.srinivas@intel.com>
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
The test only runs on gen9+, so we can safely replace all calls with
COMMIT_ATOMIC.
Also perform some cleanups by making fb an array, and cleaning up in
prepare_crtc. This way failed subtests won't cause failures in other
subtests.
Changes since v1:
- Rebase on top of num_scalers changes.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
The number of scalers can depend on the pipe, so require at least 1
scaler before running any subtests.
Changes since v1:
- More closely match kernel implementation. (Mika)
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
Convert the test to run subtests per pipe, before we start adding
more subtests.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
PIPEC doesnt have 3rd plane in GEN9. So, we skip the
3rd plane related scaling test where 2nd OVERLAY
plane is not available.
Restricting downscaling to (9/10)x original size of the
image to avoid "Max pixel rate limitation" of the hardware.
When testing with a resolution of 1024x768, the test fails
in iterate_plane_scaling because height becomes out of bounds.
Lastly, instead of a fixed test image, generate a test pattern
at runtime to not run into bxt's hardware limits for scaling.
Later patches in this series will cover corner cases of
scaling.
Changes since v1:
- Move out the code reshuffle to a separate commit. (Maarten)
This makes it more clear what's fixed.
Changes since v2:
- Fix iterate_plane_scaling on 1024x768. (Maarten)
- Instead of upscaling a test image, use the test pattern with a color. (Maarten)
Using a 600x600 test pattern doesn't run into BXT's
hardware limits for scaling.
Signed-off-by: Mahesh Kumar <mahesh1.kumar@intel.com>
Signed-off-by: Jyoti Yadav <jyoti.r.yadav@intel.com>
Signed-off-by: Vidya Srinivas <vidya.srinivas@intel.com>
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
We will add more subtests in the future, it's more clear if we split
out the actual test to its own function first.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
Both gem_linear_blits and gem_tiled_blit do not request the full 48b
GTT layout for their objects, restricting themselves to 4G. The
underlying test that they trigger eviction is unaffected by this
restriction, so we can simply reduce their memory requirements to fill
the low 4G GTT space and so allow them to run on 48b machines.
v2: gem_tiled_fenced_blits as well
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Acked-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
Eventually we're switching the official name to "IGT GPU Tools", but
right now there's still a lot of hardcoding to intel-gpu-tools that is
to be fixed in the near future.
Rename the project in toplevel meson.build to intel-gpu-tools to get
meson to generate tarballs roughly the same as autotools in 'dist'.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
If the directories contain spaces, run-test.sh fails.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
If the directories contain spaces, rst2man.sh fails.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
This patch adds a subtest related to pixel format testing. The test
tries to create framebuffer with all supported pixel formats on every plane,
and tries to draw them using cairo and commits the same on display.
Changes since v1:
- Make the test more generic and try on all planes, including legacy cursor.
Signed-off-by: Mahesh Kumar <mahesh1.kumar@intel.com>
Signed-off-by: Jyoti Yadav <jyoti.r.yadav@intel.com>
Signed-off-by: Vidya Srinivas <vidya.srinivas@intel.com>
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
The next patch wants to call for_each_pipe_with_valid_output
with *pipe and *output, this fails miserably without these braces.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
While developing a fix for an accounting hole in busy stats we realized
lite-restore is a potential edge case which would be interesting to check
is properly handled.
It is unfortnately quite timing sensitive to hit lite-restore in the
fashion test needs, so downside of this test is that it sufferes from a
high rate of false negatives.
v2:
* Make the sleep unconditional and use scientific notiation for large
constants. (Chris Wilson)
* Use gem_quiscent_gpu instead of gem_sync+usleep to ensure context
complete was received under execlists. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Make sure busyness is correctly reported when PMU is enabled after the
engine is already busy with a single long batch.
v2:
* Make the sleep unconditional and use scientific notiation for large
constants. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Fixes: 834321a5d76a ("tools: Cannonlake port clock programming")
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Mika Kahola <mika.kahola@intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
This reverts the meson.build changes from commit
07c331773dd3bc4dadb164bcd9bc06dbd01de3b6.
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
I also noticed that meson.sh doesn't set the prefix for patch
submission. Fix that (even thought hopefully real soon igt will move
to its own list).
v2: Review from Petri.
Cc: Petri Latvala <petri.latvala@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Fixes: 865a47ca ("overlay: parse tracepoints from sysfs to figure out fields' location")
Signed-off-by: Rhys Kidd <rhyskidd@gmail.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
|
|
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96620
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
|
|
Commit 98c64b33a793 ("lib/igt_kms: Drop all stale events on first
commit.") added a use of poll() to igt_kms.c, but that file only
includes poll.h when HAVE_UDEV is defined. Move the include outside
the UDEV conditional.
Fixes: 98c64b33a793 ("lib/igt_kms: Drop all stale events on first commit.")
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Rhys Kidd <rhyskidd@gmail.com>
|
|
Cannonlake port clock programming tests and verifies DPLL legal dividers
P, Q, and K. This tests adds two reference clocks 19.2MHz and 24MHz to
test algorithm's capability to find P, Q, and K dividers as well as DCO
frequency for different symbol clock rates.
The test compares two algorithms, the reference with double precision and
i915 implementation with fixed point precision. In case of a difference in
computation the difference on dividers is printed out to the screen.
Signed-off-by: Mika Kahola <mika.kahola@intel.com>
Acked-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
|
|
A couple of small optimizations which altogether bring around 30%
improvement in my testing.
1. Do less string processing on tracepoints names and push more of the
check into the if-ladder.
2. Pull out common db key and ctx processing and cache common values in
local vars.
3. Key value pair parsing is faster with a regexp.
4. Avoid sorting the db hash multiple times if possible.
v2:
* Use faster key-value splitting method. (John Harrison)
v3:
* Fix floating-point to int time conversion.
v4:
* Fix refactoring and logic fails. (John Harrison)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: John Harrison <John.C.Harrison@intel.com>
Reviewed-by: John Harrison <John.C.Harrison@Intel.com>
|
|
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104260
Signed-off-by: Marta Lofstedt <marta.lofstedt@intel.com>
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
|
|
warning() was only added to the meson interpreter in 0.44 which is
currently the last version. Let's use message() as we are currently
requiring meson > 0.40. Otherwise we get the following error:
Meson encountered an error in file overlay/meson.build, line 62, column 1:
Unknown function "warning".
Fixes: 865a47ca ("overlay: parse tracepoints from sysfs to figure out fields' location")
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
Cc: Rhys Kidd <rhyskidd@gmail.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Petri Latvala <petri.latvala@intel.com>
Reviewed-by: Rhys Kidd <rhyskidd@gmail.com>
|
|
When we require GEM, reset the global seqno. This gives each test a
clean slate to work with, and avoids left-over state from previous tests
impacting on the next. In particular, somes tests may be setting up long
sequence of stalling batches not expecting to hit a seqno wraparound
(leftover from, for example, gem_exec_whisper), causing long GPU hangs
and incompletes in CI if they do.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
Each call to igt_spin_batch_new_fence will do a stalling check to verify
that GEM is functional before submitting the spinning batch. In a loop,
this means that we may end up waiting for our earlier spinning
batches...
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
igt_spin_batch_new() includes a throttling check that GEM works, which
breaks trying to create multiple spin batches, use
__igt_spin_batch_new() instead, after verifying GEM works.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
Since igt_spin_batch_new() will do a stalling GEM check, it is not
advisable to use it within loops. Perform the igt_require_gem() upfront
and then use __igt_spin_batch_new() inside the test loop.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
This weas a workaround to gracefully skip on i915 before nonblocking
modeset support was added, but this is no longer needed. Remove the
code, since it's safe to always assume such support is enabled.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104471
Reported-by: Marta Lofstedt <marta.lofstedt@intel.com>
Reviewed-by: Marta Lofstedt <marta.lofstedt@intel.com>
|
|
Using the fancy new DRM_CAP_CRTC_IN_VBLANK_EVENT cap I can finally
make this test the work I originally intended to.
For the !modeset case that means performing a pageflip on both crtc's,
then requeueing as soon as the event is delivered and then check the
vblank counter against the original value, it should be advanced by 1.
The modeset case is slightly more complicated, ideally it's handled
the same, but if we can't perform a modeset and pageflip at the same
time, fall back to queueing both in a single commit, in which case
we can say nothing about the vblank counter.
There is a small race between flip_done and hw_done, so make
flip_nonblocking retry for a second when encountering -EBUSY.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101634
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
Instead of assuming each subtest cleans up after itself, assume it
fails and doesn't. Now that igt_kms can clean up stale events, we
can just force each subtest to only clean up its framebuffers,
which isn't harmful if it failed.
The nonblocking modeset test is removed, this was a workaround only
needed for intel because it supported nonblocking commit only for the
!modeset case, this has been fixed.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
I've been trying to make kms_cursor_legacy work when subtests fail.
Other subtests will start failing too because of expired events or
stale pipe crc. The latter can be resolved in the test, but the former
could affect other tests
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
[mlankhorst: Change return status to int, so callers can see how many events are swallowed.]
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Similar to how we are now importing the drm uapi directly into igt, we
also would like to have a copy of auxiliary uAPI such as sync_file.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
Ensure that the terminating write into WC-memory is flushed before we
might trigger a wait for ring space.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
Rather than calibrate and emit nop batches, use a manually signalled chain
of spinners to generate the desired interrupts.
v2: Two flavours of interrupt generation. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
Support creating spin batches which return an output fence using new
__igt_spin_batch_new_fence / igt_spin_batch_new_fence API.
This will be used fromthe perf_pmu@interrupts test to ensure user
interrupt generation from a batch with controlled duration.
v2: Support out fence with multiple engines as well. (Chris Wilson)
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> (v1)
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|