Age | Commit message (Collapse) | Author |
|
If you have gtkdoc installed, then autogen.sh stopped working ever
since:
commit ad821d1dc5d0eea4ac3a0e8e29c56c7f66191108
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date: Thu Dec 13 13:43:55 2018 +0100
autoconf: Drop gtkdoc support
Acked-by: Petri Latvala <petri.latvala@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Emil has another auth test which could use the check_auth function, so
best to merge them all.
We need a subtest group and put the tests which need to fully control
who's master and how many open drm fd there are first.
Cc: Emil Velikov <emil.l.velikov@gmail.com>
Acked-by: Emil Velikov <emil.velikov@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
There are 3 tests for basic variable refresh rate functionality.
The tests measure flipping at the average between the current mode
refresh rate and the minimum supported variable refresh rate.
It tests that VRR is enabled and that the difference between flip
timestamps converges to the requested rate. It also tests this under
both S3 and DPMS.
Potential ideas for future tests:
- Test behavior inside VRR range with a stepping test
- Test behavior outside of VRR range
- Multi-monitor (limited by no async pageflips in DRM atomic API)
Cc: Harry Wentland <harry.wentland@amd.com>
Cc: Leo Li <sunpeng.li@amd.com>
Cc: Manasi Navare <manasi.d.navare@intel.com>
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
|
|
x86_features_to_string() uses a repeatable pattern that increments a
pointer for each feature string, leaving a dead assignment for the
last one. Add a (void)line to the end just to silence static analysis.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
If we first find n amount of ':' in a string, the amount is still n
when we walk through it the second time.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Imre Deak <imre.deak@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
If the properties for gamma tables exist, their sizes must be
non-zero.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
The code assumes (correctly) that perf_event_header's size is
non-zero. Write that out so static analysis also knows it.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
In 2013 we prevented changing the tiling of an active framebuffer:
commit 80075d492f8773209e26d11d6bb13ba624ef95a4
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date: Wed Oct 9 21:23:52 2013 +0200
drm/i915: prevent tiling changes on framebuffer backing storage
After this we no longer have any use for the bad-tiling subtest, and
only have to make sure changing tiling on a fb is not allowed.
Remove the original bad-tiling subtest, and add a i915_fb_tiling
subtest for this case.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
[mlankhorst: Fix build system changes]
Reviewed-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
|
|
Make certain viewports are divisible by four due to intel
hw workarounds for NV12.
Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
This patch adds one test to evaluate suspend/resume operations using kms_flip.
v2: Reduce test time to 10 (Daniel)
Signed-off-by: Shayenne Moura <shayenneluzmoura@gmail.com>
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com>
Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com>
|
|
Performing a GPU reset clobbers the fence registers, affecting which
addresses the tiled GTT mmap access. If the driver does not take
precautions across a GPU reset, a client may read the wrong values (but
only within their own buffer as the fence will only be degraded to
I915_TILING_NONE, reducing the access area). However, as this requires
performing a read using the indirect GTT at exactly the same time as the
reset occurs, it can be quite difficult to catch, so repeat the test
many times and across all cores simultaneously.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
If the device has error capturing disabled, we still allow previous
error state to be cleared by a write to sysfs/error. To actually confirm
that we can capture a fresh error state, we have to perform a read().
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Katarzyna Dec <katarzyna.dec@intel.com>
|
|
We are trying to set reset parameter earlier than checking IGT env.
Let's move it after checking IGT env to avoid setting reset parameter
when hang injection is disabled.
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Katarzyna Dec <katarzyna.dec@intel.com>
|
|
As we stopped using them in 70749c70926f ("tests: drop openssl
dependency in favor of glib sha1 implementation"), stop using them in gitlab.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Since we trust fb->size as either calculated by calc_fb_size() or the
supplied by the user, it invariably isn't page aligned. The mmap
routines and ioctls only deal in pages...
Not sure if fb->size should be page aligned, but that may break
some other drawing tests, so opt to just fix up the mmap requests.
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 already depend on glib which has sha1, so we don't really need
openssl just for sha1.
The opensll dependency was added in commit caea9c5b3aa1
("igt/gem_userptr: Check read-only mappings").
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
|
|
The main tests for PSR1 check if hardware tracking is detecting
changes in planes when modifing it in different ways and now
those tests will also run for PSR2 if supported by source and sink.
v4: Dynamic generating PSR1 and PSR2 tests instead of copy and paste
tests twice.
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Acked-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
When the PSR2 tests were added it will be necessary switch between
PSR versions, so lets add test_setup() and make it call
setup_test_plane() and assert if PSR is active as it is the base for
every test.
Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
Add the mode parameter to psr_enable() and psr_sink_support() so PSR1
and PSR2 can be tested separated.
For now all PSR tests will run only with PSR1 and the tests for PSR2
will come in the future.
Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
This way we can test both PSR version separated.
v4: Dropping psr_state_check() to psr_active_check()
Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
This is a initial preparation for PSR2 test support, as in PSR2 a
update to screen could mean that PSR is still active and the screen
will be update by a selective update this renamed is necessary.
Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
To check if PSR is active it search for SRDENT for PSR1 and it was
searching for SLEEP for PSR2 but it should really seach for
DEEP_SLEEP as in this state display block is actualy saving a
substancial amount of power.
Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
The kernel patch 'drm/i915: Refactor PSR status debugfs' changed the
output of i915_edp_psr_status, so adding support to the new output
here while keeping the support to the old one for a while.
In psr_active() we were overdoing, we just need to check the source
state to know if PSR is active and doing that we keep compability to
old and new i915_edp_psr_status output.
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
Knowing how much we tried to allocate would be useful if one should need
to debug why it failed.
References: https://bugs.freedesktop.org/show_bug.cgi?id=109439
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
Actually implement --dry-run to not execute tests. With dry-run
active, attempting to execute will figure out the list of things to
execute, serialize them along with settings, and stop. This will be
useful for CI that wants to post-mortem on failed test rounds to
generate a list of tests that should have been executed and produce
json result files (full of 'notrun') for proper statistics.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Andi Shyti <andi.shyti@intel.com>
Cc: Martin Peres <martin.peres@linux.intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Cc: Tomi Sarvela <tomi.p.sarvela@intel.com>
Reviewed-by: Martin Peres <martin.peres@linux.intel.com>
|
|
No point in sleeping 5 seconds between each modeset when running in ci.
So let's just make the default sleep interval 0 seconds and leave it up
to the user to bump it via -s when running interactively.
On a KBL + LSPCON + a 4k HDMI display with 36 modes listed:
time ./tests/testdisplay
- real 3m12,026s
- user 0m1,920s
- sys 0m1,241s
+ real 0m14,681s
+ user 0m3,135s
+ sys 0m1,340s
Cc: Martin Peres <martin.peres@linux.intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
The only caller so far never passes NULL so no effects today.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com>
|
|
This avoids calling close() with uninitialized ints if some dup()
calls succeed and others don't.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Abdiel Janulgue <abdiel.janulgue@linux.intel.com>
Reviewed-by: Abdiel Janulgue <abdiel.janulgue@linux.intel.com>
|
|
Parse error is not the only way to fail loading the file. A common
other error is the file not existing. Handle all failures to read
.igtrc by releasing the key store immediately.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
|
|
If getopt_long is told an argument is required, it will give it.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
It's not clear to the static analyzer that freq is assigned when
handling the previous frame and then used in the next. In fact, it
wasn't clear to me either before staring at the code for some
minutes. Initializing it to something makes both of us happier.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Reviewed-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
|
|
The execution can only reach the end (goto complete) or the new
unconditional assignment a few lines below before the value is read
again. Either it's really a dead assignment, or there's a bug with the
execution flow. Leaning on the former.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Reviewed-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
|
|
if (p) free(p) does a useless check, free(NULL) is a valid call. Also
assign NULL so we don't end up double-freeing memory if anyone
reorders nr_bos to have a 0 after other values.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Mika Kahola <mika.kahola@intel.com>
Cc: Robert Foss <robert.foss@collabora.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
Not only will the following calloc call end up allocating 0 bytes
(undefined behaviour), but last_plane becomes (uint8_t)-1.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Robert Foss <robert.foss@collabora.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Robert Foss <robert.foss@collabora.com>
|
|
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
The behaviour of memcpying 0 bytes from NULL is semantically sound,
but still undefined behaviour.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
|
|
No actual difference, size of a pointer is the same as
pointer-to-pointer.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Mika Kahola <mika.kahola@intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
|
|
The type mismatch was char vs. unsigned char, both being size 1 so
this didn't cause any actual issues other than noise in static
analysis that doesn't believe 1 is equal to another type of 1.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Abdiel Janulgue <abdiel.janulgue@linux.intel.com>
Reviewed-by: Abdiel Janulgue <abdiel.janulgue@linux.intel.com>
|
|
If an ioctl fails, errno is set to non-zero, and static analysis
doesn't quite get it. Add igt_assume()s where applicable.
v2: Braces on both branches of an if (Chris)
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Michał Winiarski <michal.winiarski@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
If an igt_ioctl fails, errno is set to non-zero, and static analysis
doesn't quite get it. Add an igt_assume() to help.
v2: Braces on both branches of an if (Chris)
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Michał Winiarski <michal.winiarski@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
BUILD_BUG_ON_INVALID() is a macro that, like the kernel counterpart,
expands to an expression that generates no code. Useful for making
sure an expression is valid code while producing no side effects.
igt_assume() is an assert-like macro that is used to give hints to
static analysis of code. If static analysis is not used (as detected
by STATIC_ANALYSIS_BUILD), igt_assume() expands to a
BUILD_BUG_ON_INVALID, otherwise expands to an assert().
v2: Make sure the expression in igt_assume is still parsed without
static analysis. (Chris)
v3: Also introduce BUILD_BUG_ON_INVALID as standalone
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Michał Winiarski <michal.winiarski@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
The size of the UV plane is not calculated correctly - height is not tile
aligned. Make use of the stride and offset values intitialized in the
previous patch to calculate plane size. The next step would be to rewrite
the test to make use of library functions, but for now this should fix
NV12.
Cc: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Signed-off-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Reviewed-by: José Roberto de Souza <jose.souza@intel.com>
|
|
The test does not initialize data->fb, initializing stride and offset is
necessary to fill NV12 planes correctly. We should ideally be using
library functions in place of handrolled code in this test, but let's start
by fixing the failures.
Cc: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Signed-off-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Reviewed-by: José Roberto de Souza <jose.souza@intel.com>
|
|
Not clearing the pipe results in a test failure when the same pipe is
assigned to the next output.
Cc: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Reviewed-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Suggested-by: James Ausmus <james.ausmus@intel.com>
Signed-off-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
|
|
For one shot crc collection, let's use the same helper function as we
use for continuous crc collection. With this patch, we first drain the
pipe from queued crc values and read the fresh crc.
v2: We don't need to drain the pipe right after we start
collecting crc's (Dhinakaran)
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: Mika Kahola <mika.kahola@intel.com>
|
|
Add NV12 support for testing where available.
Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
rendered test image had off-by-one error in size calculation
which was failing some tests on certain resolutions and plane
sizes.
Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|