Age | Commit message (Collapse) | Author |
|
Split the invalid-lut-sizes test into separate gamma and degamma tests.
This way we can report SKIP for the thing we don't have. Also make the
CTM invalid sizes test report a skip too.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Requiring a full color pipeline when we're just testing eg. the gamma
LUT is silly. Make the requirements more sensible.
Also include an igt_require() for the CTM, which was totally missing
before.
v2: Note the added igt_require(CTM) (Daniel)
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
We already compute the lut_size*entry_size so let's reuse those
when allocating the LUTs.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
To make life easier let's wrap the LUTs in a small struct.
v2: igt_assert(gamma) (Daniel)
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
I think we can assume fresh enough headers by now, so remove
the local _drm_color_ctm and _drm_color_lut structs definitions.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
It's a generic testcase, originally for a chv issue, but we can hit
legit bugs with this on any platforms. And we do, which then results
in confused managers.
Let's rename for clarity.
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Cc: "Peres, Martin" <martin.peres@intel.com>
Cc: Ville Syrjala <ville.syrjala@linux.intel.com>
Acked-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Acked-by: "Peres, Martin" <martin.peres@intel.com>
Acked-by: James Ausmus <james.ausmus@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
We may not be able to enable all the planes simultaneously. In that
case just keep going with fewer planes. The test already requires
atomic so let's use TEST_ONLY unconditionally.
Reviewed-by: José Roberto de Souza <jose.souza@intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
These tests intend to test scaling on hardware with overlay planes.
They will incorrectly try to scale the cursor plane or occasionally
crash by trying to access planes that don't exist for hardware that
doesn't expose any overlay planes.
Make plane selection explicit by requesting the plane by type and index
using the igt helper igt_pipe_get_plane_type_index.
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Leo Li <sunpeng.li@amd.com>
|
|
If we caused a fault on a GEM buffer while in the middle of trying to
write/read into that buffer, we could conceivably deadlock (e.g.
recursing on struct_mutex if we are not careful). Exercise these cases
by supplying a fresh mmap to pread/pwrite in both non-overlapping and
overlapping copies.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
|
|
Set the src/dst viewports correctly when trying to crop off the
edges.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110296
Fixes: 80eb61459791 ("tests/kms_plane: Remove the upscaling requirement")
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
We want to use a child in order to detect an uninterruptable sleep (a
potential bug we might hit), but we can use igt_waitchildren_timeout()
to replace our risky self-signaling + nanosleep.
v2: Remove the now redundant signal() setup.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103182
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
ICL has some many planes per pipe that it is causing this test to
skip due bandwidth limitation when combined with 4K displays.
The objective of this test is test the visibility of the planes when
switching between high and low resolution, more information in the
patch that added this test 12e34d8c909a ("tests/kms_plane_lowres:
Plane visibility after atomic modesets").
So it was setting all the planes the tested pipe in the bottom left
of the display using the height of high resolution, checking the
visibility and then switching to the low resolution mode and checking
again the visibility and now it is expected that all planes would be
invisible.
So to overcome ICL bandwidth issues, here it is testing each plane
individually.
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Mika Kahola <mika.kahola@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
Three test were duplicating this 1024x768 mode so lets move it to lib
and share it.
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
get_lowres_mode() was looking for the desired mode over all
connectors what could cause commit to fail due incompatibility.
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Cc: Mika Kahola <mika.kahola@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
This switch allows users to select which dmesg log level is treated as
warning resulting in overriding the test results to
dmesg-fail/dmesg-warn.
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
|
|
To aid testing function parsing metadata.txt is split into outer helper
that operates on dirfd and inner function that operates on FILE*.
This allows us to test the parsing using fmemopen(), limiting the amount
of necessary boilerplate.
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
|
|
Which regexp gets compiled is settings specific, depending whether we
run piglit-style or not.
If it's optimized to be initialized only once and it is a global
variable, it will be "stuck" in the mode we have selected with the first
run, which may break tests.
Let's remove this optimization and initialize it each time, as it takes
less 0.002s on my hardware.
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Simon Ser <simon.ser@intel.com>
|
|
We may use HW semaphores to schedule nearly-ready work such that they
are already spinning on the GPU waiting for the completion on another
engine. However, we don't want for that spinning task to actually block
any real work should it be scheduled.
v2: No typeof autos
v3: Don't cheat, check gen8 as well
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>
|
|
Replace the convoluted raising of SIGALRM from the child with an
interruptible sleep in the parent with the equivalent and far more
natural igt_waitchildren_timeout().
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103182
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
gem-execbuf-stress
Extra 5sec delay does not add any value more than gem-execbuf-stress.
It waits until suspend state after a job is added by gem_execbuf().
There is no need to do more when GPU becomes suspended state.
I confirm this by looking at pm_runtime_force_suspend() which exits
on suspend state.
Signed-off-by: Caz Yokoyama <caz.yokoyama@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
By clean up idle work, gem-execbuf-stress subtest runs 1.2 sec.
I divide "i915_pm_rpm: remove gem-execbuf-stress-extra-wait because
same as gem-execbuf-stress" into 2 patches. This is one of them.
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Caz Yokoyama <caz.yokoyama@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
One significant usecase for intel_reg/etc. is to be able to examine
the hardware state *before* loading the driver. If the tool forces
the driver to load we've totally lost that capability.
This reverts commit 8ae86621d6fff60b6e20c6b0f9b336785c935b0f.
Cc: Michał Winiarski <michal.winiarski@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Acked-by: Jani Nikula <jani.nikula@intel.com>
Acked-by: Michał Winiarski <michal.winiarski@intel.com>
|
|
We may not be able to turn on all the planes (eg. due to memory
bandwidth limitations). Let's accept that fact and simply turn
on as many planes as we can.
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
Instead of just testing each pixel format let's test every
format+modifier combo.
Obviously testing with solid filled fbs isn't the most effective
way to detect tiling problems, but we can't really do much more if
we want to keep comparing YUV vs. RGB results (unless we start to
render the RGB content in a way that matches the YUV subsampling
behaviour of the hardware).
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
Move the pipe/primary plane stuff outside the plane loop so that
we can avoid all that overhead (including a modeset) when switching
from one plane to another.
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
Reduce the plane size further to speed up the test. 64x64 is the
universal i915 minimum cursor size so we'll use that. And since
we chose wisely we'll make cursors use the reduced size as well.
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
No point in requiring upscaling when trying to use a small fb to test
pixel formats.
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
Y410 is packed with compressed a channel and only 32 bpp, like
10 bits RGB formats. Y416 is a packed 16 bits per component format.
Changes since v1:
- Rebase on top of upstream YUV changes.
Changes since v2:
- Discard alpha channel, not used upstream.
Changes since v3:
- Handle the XVYU formats and Y41x formats correctly.
Changes since v4:
- Fix YUV conversion routines. (Ville)
- Use memset64 to clear initial fb. (Ville)
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
[mlankhorst: Add missing ULL (Ville)
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
Those formats are packed like YUYV, but only 16 bits per component.
Changes since v1:
- Rebase on top of upstream YUV changes.
Changes since v2:
- Use drm_fourcc.h from upstream.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
|
|
We not only need to check that userspace is allowed to use the objects
it's changing, but also the objects it's using as property values. The
only ones relevant for leases are the CRTC_ID properties on connectors
and planes.
Current kernels fail this.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
The conversion from idr to xarray will change the errno for already
inserted object ids from ENOSPC to EBUSY. Allow both.
Cc: Matthew Wilcox <willy@infradead.org>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
I dropped a superfluous check for negative object id (the kernel
did a cast to s32, despite that object ids are always unsigned).
Which changes the errno from EINVAL to ENOENT. Allow both.
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Figured I'll only test the SetCursor interface since in the kernel
it's all the same anyway, it's just libdrm that splits it up.
Current kernels fail this.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Again we need to make sure that a lease can't use planes it's not
allowed to through legacy ioctls. SetCrtc is a bit more tricky, since
we should still allow to shut down a CRTC, e.g. when we're allowed to
use other planes on that CRTC.
Current kernels fail this.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
We need to make sure that legacy ioctls don't operate on a lease if
the lesse doesn't have access to the implicitly used primary plane.
Current kernels fail this.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
It's just added to in a loop later without any initialization or
direct assignment.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
The chroma address needs to be 256 byte aligned on amdgpu and the
easiest way to do so is to align the minimum stride for the luma.
v2: added this patch
Cc: Leo Li <sunpeng.li@amd.com>
Cc: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
|
|
A black FB on amdgpu returns a CRC of (0, 0, 0), which IGT considers
suspicious. All our CRC values are also 16-bit so a value of 0xffffffff
can't be obtained.
Drop the suspicious CRC checks on amdgpu by checking the device in
crc_sanity_checks. We need the drm_fd for this so pass in pipe_crc
to the function to get it. It makes more sense to me to do it this
way than to duplicate code and the explanation on both calls to
crc_sanity_checks.
v2: rebase
Cc: Leo Li <sunpeng.li@amd.com>
Cc: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
|
|
These helpers will be used to address amdgpu specific quirks and
features. They're implemented like the i915 and VC4 helpers.
In order for the string comparison to pick up "amdgpu" the buffer size
had to be expanded for __is_device. I've gone ahead and made it 12 bytes
to cover everything that's there right now.
v2: rebase
Cc: Leo Li <sunpeng.li@amd.com>
Cc: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
|
|
Since not everyone is familiar with kernel taints, and it is easy to get
confused and attribute an abort to an innocent TAINT_USER caused by an
unsafe module option, which is usually the first thing people find
greping dmesg for "taint", we should provide more guidance.
This patch extends the abort log by printing the taint names, as found
in the kernel, along with a short explanation, so people know what to
look for in the dmesg.
v2: rebase, reword
Cc: Petri Latvala <petri.latvala@intel.com>
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Even with 128MiB reserved for other use, a single pass of gem_exec_big
runs out of memory. Give in and halve our batch size, that has to be
enough slack! As to why it keeps on failing, is left as an exercise to
the reader -- we have to solve the mm/ mystery one day, as eventually it
will be our only remaining source of bugs!
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
|
|
This function checks whether a port is an analog bridge. Analog
bridges provide their own EDID thus the vendor should be different
from "IGT".
There was a typo that made the function always return true for VGA
ports. The condition was essentially:
thing != 'I' || thing != 'T'
which is always true.
Apparently this didn't cause any harm, but it's probably better to fix
it anyway in case some tests were skipped and shouldn't.
Signed-off-by: Simon Ser <simon.ser@intel.com>
Acked-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
Fix the meson build to not link intel-gpu-top against the whole test
infrastructure; it's a tool not a test!
Reported-by: Eero Tamminen <eero.t.tamminen@intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110249
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>
|
|
Avoid embedding the DRM_IOCTL() macro into the error message as it is
unreadable, and instead always wrap the ioctl with a self-descriptive
helper.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
To make the demonstration of the cheeky preemption more impactful, make
the second context a nop to contrast the first being 1024
MI_STORE_DWORD_IMM. Then if we execute and wait on the second context
before executing the first, the client latency is even more drastically
reduced.
To more clearly show any effect on wait reordering, measure the
alternative path and present both.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
The invalid set/get tests do not serve the purpose of detecting whether
or not invalid parameters are indeed detected correctly -- simply because
the kernel is the arbiter of what is invalid and this test second
guesses that and is wrong.
The intent of this test was to ensure that we didn't include any holes
in the parameter space that may have been used for nefarious undisclosed
purposes, i.e. the maintainer's job backed up by reviewers.
As proving no holes is impossible without fuzzing/exhaustive search and
a whitelist, accept defeat and just check whether the very last
parameter (which should be unused for a long, long time) is invalid.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
CI complains that the exhaustive test of trying every size up to the
limit is too slow, so add a simple test that tries to submit one
extreme batch buffer and check all the relocations land.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105555
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
Check that the GPU even exists before submitting a batch.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109589
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
In order to correctly serialise the order of execution between rings, we
need to flag the scratch address as being written. Make it so.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|
|
Show the total power consumed across all the whispers.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
|