| Age | Commit message (Collapse) | Author |
|
Not all engines are created equal, and our weighting ends up favouring
the many faster xCS rings at the expense of RCS. Our qlen estimation
also failed to factor in the context switch overhead, which is a
significant factor for nop batches. So we oversubscribe the number of
batches submitted to RCS and end up waiting for those to complete at the
end of our subtest timeslice.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Caz Yokoyama <caz.yokoyama@intel.com>
Reviewed-by: Caz Yokoyama <caz.yokoyama@intel.com>
|
|
This introduces a new test for the Chamelium, that sets up planes
with randomized properties such as the format, dimensions, position,
in-framebuffer offsets and stride. The Chamelium capture is checked
against the reference generated by cairo with either a CRC or the
checkerboard-specific comparison method.
This test also includes testing of the VC4-specific T-tiled and
SAND-tiled modes, in all formats supported by the hardware.
Since this test does not share much with previous Chamelium display
tests (especially regarding KMS configuration), most of the code is
not shared with other tests.
This test can be derived with reproducible properties for regression
testing in the future. For now, it serves as a fuzzing test
Signed-off-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Reviewed-by: Maxime Ripard <maxime.ripard@bootlin.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
|
|
Now that the checkerboard frame checking method is available through
the frame match helper, make use of it in YUV tests to increase the
reliability of the results.
The analog test tends to provide false positives, which are properly
detected by the checkerboard method in most instances.
Signed-off-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Reviewed-by: Maxime Ripard <maxime.ripard@bootlin.com>
|
|
In prevision of adding support for another type of frame matching,
rename chamelium_assert_analog_frame_match_or_dump to drop the
analog part and feed it the check type. This way, the bulk of the
helper can apply to other frame matching types.
This requires moving the chamelium_check enum from the test to the
common chamelium header.
Signed-off-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Reviewed-by: Maxime Ripard <maxime.ripard@bootlin.com>
|
|
The modifier is part of how a frame is represented, so add it as an
extra argument so that it can be specified when converting framebuffers.
For now, only a linear modifier is supported.
Signed-off-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Reviewed-by: Maxime Ripard <maxime.ripard@bootlin.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
|
|
Incoming patches for the common library wrappers will try mapping through
the MMAP_OFFSET IOCTL first. Since the tests in gem_mmap_wc are targeted
at the GEM_MMAP IOCTL, add a local wrapper.
Signed-off-by: Antonio Argenziano <antonio.argenziano@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
The test uses gtt mapping to check two BOs have the same content, since
it seems there is no contention on the BOs use cpu mapping to make it
compatible with platforms that do not have a mappable aperture.
v2:
- Need to have an explicit set_domain. (Chris)
Signed-off-by: Antonio Argenziano <antonio.argenziano@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
And make sure we get the LEASE=1 value, indicating a lessee change.
v2: Apparently netlink reading can leak EAGAIN out through
udev_monitor_receive_device. No idea what's going on there, so let's
wrap some duct tape around it.
v3: Lyude reported that we might get a few udev events on startup of
the test. Drain those first.
v4: Use the igt hotplug library functions, they already take care of
all the uevent special cases.
Cc: Lyude Paul <lyude@redhat.com>
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Without universal planes the kernel should auto-add the (in that case
hidden) primary and cursor planes. Check this works and all the error
handling is there for evil userspace.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Check that the 2nd master can only create leases while being active
master, and that leases on the first master don't prevent lease
creation for the 2nd master.
Also check that a disappearing master does also invalidate all its
leases.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
- make sure leases change master status together with lessor
- make sure lease can't change the master status
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Makes sure the possible_crtcs logically match between master and
lease, and that the values are correctly renumbered on the lease side.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Found a few corner cases to validate. Put them into the existing
testcase.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Found a few things in the kernel that looks suspicious, separate
patches on their way.
I also reviewed coverage for list-lesses and get-lease, and coverage
seems complete for these.
v2: Bit of polish to address Lyude's comments.
Cc: Lyude Paul <lyude@redhat.com>
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
It's all kernel code that's being tested here, no reason not to run
in simulated environments ...
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Test gap because we're using universal planes by default. Fix that.
Cc: Keith Packard <keithp@keithp.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Eek, I assumed the 'banned' subtest only applied to context platforms,
it doesn't. The basic test works for all, checking whether a second
context works after the first is banned however only applies to
platforms with contexts!
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
If we tell the machine to reset but they are disallowed, we will leave
the system in a wedged state, preventing the majority of subsequent
tests.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
Not allowed in igt_simple_main, also really doesn't make any sense,
it's all just one big testcase.
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Cc: Petri Latvala <petri.latvala@intel.com>
Reported-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
Acked-by: Radoslaw Szwichtenberg <radoslaw.szwichtenberg@intel.com>
|
|
Lock down the new uABI that DRM_IOCTL_I915_GEM_CONTEXT_CREATE returns
-EIO when wedged.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@intel.com>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
igt_fixture within an igt_simple_test don't really work as advertised.
Minimal fix, the testcase seems fairly questionable already ...
References: https://intel-gfx-ci.01.org/tree/drm-tip/drmtip_222/fi-icl-y/igt@kms_mmap_write_crc.html
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
norecovery intentionally issues a GPU reset, but we should only do so
after confirming with the kernel that this can work.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109691
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
They're causing troubles because this runs all the igt_fixtures, and
doing that on a build machine is at best surprising.
The main aim for this is catching testcases which fail to call
igt_exit. But just enumerating subtests does that too, and we have
library unit tests to make sure that's the case (with igt_no_exit and
igt_no_exit_list_only).
Cc: Petri Latvala <petri.latvala@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
They are i915-specific, so they belong to the directory.
The (now) infix _pm_ is quite informative and worth keeping.
v2: also prefix .c files
Cc: Petri Latvala <petri.latvala@intel.com>
Cc: Ewelina Musial <ewelina.musial@intel.com>
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
|
|
So we do not have to do any rename shenanigans in the build system and
the .c files are easier to find.
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Petri Latvala <petri.latvala@intel.com>
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
|
|
The write hazard lies extend also to the cache-dirty tracking; as we
purposefully do not tell the kernel we are writing to the bo, it fails
to note the CPU cache as dirty and so the gem_read() may not
sufficiently flush the caches prior to reading back from the GPU.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Antonio Argenziano <antonio.argenziano@intel.com>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
In triggering the ban, we only want to observe the local context be banned
and not the fpriv as a whole.
v2: And send an execbuf down the new context.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@intel.com>
Cc: Antonio Argenziano <antonio.argenziano@intel.com>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
When RECOVERABLE is set, the kernel will attempt to automatically recover
a context after a hang. But if it is unset, the kernel will ban the
guilty context on a hang, preventing subsequent execution.
v2: Create a has_recoverable_param()
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@intel.com>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
The kernel must not return stale information back to userspace when they
create a new object. For that purpose, we always clear objects on
creation, so verify that this is so.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Matthew Auld <matthew.auld@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
|
|
use IOCTLs gem_read for reading and, gem_sync to wait on a batch, this
will help testing platforms that might not expose gtt mapping.
v2:
- use a local helper for reading from BOs. (Chris)
- Always sync before reading. (Chris)
v3:
- Better helper naming. (Chris)
- Start read from actual offset. (Chris)
v4:
- Always use byte size in helper. (Chris)
v5:
- Fix byte<->count conversion. (Chris)
Signed-off-by: Antonio Argenziano <antonio.argenziano@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
This test produces an awful, awful lot of redundant output as it tries
to find just the right amount of memory pressure to cause an
out-of-memory event in the middle of suspend. That is always quite a
slow process, taking 90s on a normal machine and 500+s on skl-y.
Furthermore, even when we do achieve the perfect setup, the test
frequently locks up and fails to resume with no indication that it is a
bug in the driver. The shrinker and oomkiller (plus i915) do not make for
a pleasant time!
Enough of Martin's whinging, I see no way of easily making this test
quieter, quicker and more efficacious, relegate it to the masochist only
stable.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Martin Peres <martin.peres@free.fr>
Cc: Petri Latvala <petri.latvala@intel.com>
Reviewed-by: Martin Peres <martin.peres@free.fr>
|
|
Older platforms need to clobber the display around a reset (incl. a
modeset to off, and a modeset back on), which can be much slower than
the reset itself. Give these platforms (gen2-4) some leniency and allow
them a higher limit before declaring them a failure.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
As we have moved to rcu/srcu to serialise the resets, individual resets
are subject to small variations in system grace periods. Allow for this
by only expecting the median reset time to be within our target, thereby
excluding noisy outliers from perturbing our results (but keep the
maximum capped to prevent horrid failures!)
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
|
|
We don't need to waste time running perf-only test cases when we are not
manually checking results. ezbench is that away!
References: https://bugs.freedesktop.org/show_bug.cgi?id=109640
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Petri Latvala <petri.latvala@intel.com>
|
|
We're creating our own namespace and then create a copy of the chardev
that anyone can access before dropping root. Should hopefully work on
any system.
This way we're also guaranteed to open the right device again.
v2: mount(2) instead of mount(3).
v3: Drop execute bits from our temporary chardev (Chris).
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Emil Velikov <emil.velikov@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
Spotted by my new "are there any child processes left?" check in
igt_exit - we need to put all the igt_require before we start any real
test logic.
v2: Rebase.
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
My new "are there any child processes left?" check in igt_exit catched
this one.
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
|
|
For better readability, numeric values are replaced with macros.
Signed-off-by: Ramalingam C <ramalingam.c@intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Once the HDCP is enabled, kernel will run the link integrity check(LIC)
atleast once in 2Secs based on the HDCP versions.
So to confirm the link integrity check is passed, we oberve that HDCP
state remains ENABLED for next 4Secs.
v2:
Rebased.
Signed-off-by: Ramalingam C <ramalingam.c@intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
As we have two different patch for commitng the HDCP request
1. DDI_enable (during the modeset)
2. update_pipe (during fastset execution)
Currently our kms_content_protection covers only fastset path.
So this test adds the coverage for the HDCP during the modeset by
performing DPMS off-on and check for HDCP status.
But with respect to HDCP we allow few retries from userspace before
reporting the failure. So only first attempt at kernel will be on
modeset path, next retries will become fastset commiting of HDCP.
v2:
dpms test is added within existing implementation with a flag [Daniel]
v3:
ret declared.
Signed-off-by: Ramalingam C <ramalingam.c@intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
Modularizing the CP test steps for the convenience of reusing it for
other subtests.
Signed-off-by: Ramalingam C <ramalingam.c@intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
This tests checks if hardware is able to do selective update when
screen changes.
PSR2 don't trigger interruptions and the 'PSR2 SU status' register
is not kept loaded all the times, so it is necessary keep polling
PSR status debugfs until those values are loaded.
Also from DEEP_SLEEP state HW will not do a seletive update, as
most of the memory/context is lost in deep sleep state hardware will
need to exit PSR mode then wait a configured number of frames to
activate PSR again to then start doing seletive updates, that is why
just one screen change is not enough to pass this tests.
When a selective update happens and the values are loaded and read
from debugfs it is compared with the expected value of seletive
update blocks, if matches the polling is stopped and the test passed
otherwise it will wait until it reachs a maximum number o screen
changes to fail the test.
v2: Using new SU blocks debugfs output
v3:
- removed the timerfd to fail the test, now failing based in a
maximum number of screen changes
- removing thread to read debugfs, read from main thread is enough
- improved commit message
v4:
- getting cairo context for frontbuffer test in prepare()
- droppoing poll(), using blocking timerfd instead
v5:
- Doing a modeset before trying to enable PSR2
v6:
- doing atomic commits to fix(legacy commit is taking more time in
recent kernels causing us to miss the SU when reading debugfs) and
speedup test
- fixed code to skip test when PSR2 is not possile
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Tested-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
|
|
This fixes a compiler warning treated as an error when building for
32-bit architectures since their pointer size does not match the size
of drm_i915_gem_context_param.value which is 64 bits:
CC i915/gem_ctx_sseu.o
i915/gem_ctx_sseu.c: In function ‘test_ggtt_args’:
i915/gem_ctx_sseu.c:384:9: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
munmap((void *)arg.value, 4096);
It was found while building for arm with gcc 6.3.0 and I suspect the
same problem would arise for i386 or other 32-bit architectures. The
uintptr_t type is by definition an unsigned integer of the same length
as a pointer on a given architecture, so this should fix the problem
for all architectures up to 64 bits.
Signed-off-by: Guillaume Tucker <guillaume.tucker@collabora.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
|
|
This reverts commit 845c9fb45b734aef95e2fb2317d0c02567e06a68.
To unblock GitLab's CI while a proper solution is in the works.
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
As the inline comment says, this test checks that the kernel allows
unauthenticated master with render capable, RENDER_ALLOW ioctls.
The kernel commit has extra details why.
v2:
- drop RUN_AS_ROOT guard
- call check_auth() on the {,un}authenticated device
- check the device is PRIME (import) capable
- check the device has render node
- tweak expectations based on above three
- elaborate why we care only about -EACCES
v3:
- fold into existing core_auth.c
- move igt_assert within the subtest
- make has_prime_import() an igt_require()
- check for BADF before and after, as requested. Not strictly needed.
- swap igt_info+drm_open_driver with comment + __drm_open_driver
Former calls igt_skip() which is problematic with igt_fork().
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> (irc)
|
|
Seeming copy/paste from another test. None of the includes are required.
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|
|
The first dispatch incurs the cost of waking up the device, so also
measure after issuing a spinner to keep the device awake as we submit.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
Present the latency results in nanoseconds not RCS cycles.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
|
|
`ninja test` invokes igt_command_line.sh for each test binary to check
the behavior of some of the switches. One of the verified things is that
the test exists with non-zero status when requesting invalid subtest.
`--run-subtest` results in igt_fixtures being executed - this fiddles
with the device and sysfs knobs.
Let's exit early, if we are root, to save people form unintentional
side-effects and strange failures.
Cc: Petri Latvala <petri.latvala@intel.com>
Cc: Andi Shyti <andi.shyti@intel.com>
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
|