summaryrefslogtreecommitdiff
path: root/tests
AgeCommit message (Collapse)Author
2021-02-01i915/sysfs_clients: Bump the number of recycle search retriesChris Wilson
A small bump to try again in the face of delayed appearance of directory entries. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
2021-02-01tests/kms_universal_plane:Added subtest descriptionArundhati Hagaragi
Added description for all subtests Signed-off-by: Arundhati Hagaragi <arundhati.hagaragi@intel.com> Cc: Joshi, Kunal1 <kunal1.joshi@intel.com> v2: removed extra bracket and semicolon. Reviewed-by: Kunal Joshi <kunal1.joshi@intel.com>
2021-02-01tests/kms_rotation_crc: reduce execution timeJeevan B
Restricting the execution to 2 pipes with this change we see 50% improvement in time efficiency. v2: Updated commit message v3: Updated check condition Signed-off-by: Jeevan B <jeevan.b@intel.com> Reviewed-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com> Reviewed-by: Uma Shankar <uma.shankar@intel.com>
2021-01-30meson: Turn on -WerrorAshutosh Dixit
We can choose which compile warnings to enable, but once they are enabled treat all warnings as error. This enforces stricter checks against compile warnings creeping in. v2: Fix redefinition warning errors from i915/gem_userptr_blits v3: Fix the even more pedantic clang compilation v4: Do not alter whitespace in lib/tests/igt_describe! Note: clang does not build assembler/ Signed-off-by: Ashutosh Dixit <ashutosh.dixit@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2021-01-29i915/sysfs_clients: Check that client ids are cyclicChris Wilson
The client id used is a cyclic allocator as that reduces the likelihood of userspace seeing the same id used again (and so confusing the new client as the old). Verify that each new client has an id greater than the last. v2: Use (int)(b - a) > 0 to handle wraparound 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>
2021-01-29i915/gem_ctx_persistence: Wait for spinner before resetingChris Wilson
Just reset the spinner once before launching and killing many non-persistent contexts. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-28debugfs_test: Protect against disappearing directoriesChris Wilson
With the introduction of sysfs/clients, we have dynamic directories that may disappear underneath the fswalker. Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/3017 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-28tests: Do not use pread on userptr in gem_exec_parallel.Maarten Lankhorst
It's even silly to use pread, directly read from the pointer instead by executing gem_wait first. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> #irc
2021-01-28tests/gem_userptr_blits: Rework userptr tests to cope with changesMaarten Lankhorst
Userptr semantics are changed to no longer allow forked processes to obtain pages, it will fail with -EFAULT. We also no longer allow unsynchronized access, so has_userptr needs to check with the notifier installed. The only way to make forked tests work would be to do use a fork without clone_vm set, which we have no igt infrastructure for, and can't work like the current igt_fork(). Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> #irc
2021-01-28tests/kms_plane_cursor:added subtest descriptionArundhati Hagaragi
Added description for all subtests Signed-off-by: Arundhati Hagaragi <arundhati.hagaragi@intel.com> Cc: Gupta, Nidhi1 <nidhi1.gupta@intel.com> Cc: B S, Karthik <Karthik.B.S@intel.com> Reviewed-by: Kunal Joshi <kunal1.joshi@intel.com>
2021-01-27i915/sysfs_client: Ignore clients being closed as we read their sysfsChris Wilson
An earlier client from an old test may still be lingering and disappear as we scan the sysfs. Be graceful and let it go without tripping over it. Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/3008 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
2021-01-27tests/kms_setmode: Handle conflicting encodersBhanuprakash Modem
When conflicting encoders are found, driver will disable other connectors, instead of failing with -EINVAL. So we endup with test failures. This patch will update the logic to expect the failure for the combinations where all connectors are on the same crtc only. Cc: Imre Deak <imre.deak@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Signed-off-by: Bhanuprakash Modem <bhanuprakash.modem@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com>
2021-01-26tests/kms_flip_scaled_crc: try to set mode to 1080p during testJuha-Pekka Heikkila
Different default resolutions will affect test execution, try to normalize situation by always going to 1080p resolution. If this test will run on connector which doesn't have 1080p resolution, default resolution will be used. On gen<11 will be used 480p v2 (Stan): Use igt functions for modesetting. Change igt_warn to igt_debug because there's one ICL in intel CI with eDP that would show up warnings randomly depending which machine run which test. Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com> Reviewed-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>
2021-01-25i915/sysfs_clients: Replace usleep(0) with sched_yield()Chris Wilson
To kick RCU, we go to sleep and hope the system finishes a RCU grace period before returning. Use sched_yield() in place of usleep(0) to encourage a pass through schedule(). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-24i915/sysfs_clients: Use the centre-point of read_runtime()Chris Wilson
Compare the runtime against the centre of the read_runtime, to try and compensate for scheduling delays. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-24i915/sysfs_client: Reject split clients if CPU side too slowChris Wilson
If even the CPU is too slow to submit at the require rate to generate the workload, skip the test. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-24i915/sysfs_clients: Avoid skips inside forksChris Wilson
Handle the unusable engines on Sandybridge by avoiding the dynamic engine subtests that require them. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-24i915/sysfs_clients: Repeat checks on idling monotocityChris Wilson
Do a few more executions to make sure idle <-> transitions are monotonic. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-24i915/sysfs_clients: Tare the execution overheadChris Wilson
CI is not nearly as instantaneous as we would ideally like, and so we need to compensate for the delays in execution. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-24i915/sysfs_clients: Only compare relative runtimesChris Wilson
In the split clients, focus on comparing the relative runtimes of the two clients match our expectations. Under CI debug conditions the overhead of each switch is too large to make accurate estimates. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-24i915/sysfs_clients: Correct timeslicing switchChris Wilson
We only expect to timeslice if there are more than one client available to run on a single engine. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-23i915/sysfs_clients: Restore initialisation of 'old' in busy_oneChris Wilson
Set old to 0 before using it for the first time. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-23i915/sysfs_client: Increase leniency at smaller splitsChris Wilson
For the smaller splits, an absolute error is a much greater relative error so increase the relative tolerance. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
2021-01-23i915/gem_exec_fair: Verify CTX_TIMESTAMP before useChris Wilson
Make it more clear when CTX_TIMESTAMP is not functional rather than sit inside an infinite loop. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: CQ Tang <cq.tang@intel.com> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-23i915/gem_userptr_blits: Quick verification of set-cache-level APIChris Wilson
Mesa uses set-cache-level on userptr, so verify it doesn't arbitrary fail. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-23i915/gem_userptr_blits: Check set-domain on userptr for validationChris Wilson
We use set-domain on userptr to validate that get-user-pages is applicable to the address range in mesa & ddx. Let's perform a very basic test to exercise this combination. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-23i915/gem_ctx_persistence: Check for accidental banningChris Wilson
Check that closing many contexts does not cause a ban. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-23i915: Exercise sysfs client propertiesChris Wilson
We store every client name, pid and runtime under sysfs. Better check that matches with the actual client. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
2021-01-22tests/kms_async_flips: Skip the Y<->X tile test on pre-sklVille Syrjälä
Pre-skl display engine does not support Y-tiling so the addfb will fail. Skip the test on such platforms. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
2021-01-21tests/core_hotunplug: Reduce debug noise on stdoutJanusz Krzysztofik
Since igt_fixture sections are processed unconditionally regardless of which subtest has been requested, they can now emit a lot of unrelated debug messages which can make the picture less clear. Avoid emitting those messages from outside igt_subtest sections. Move device close status prerequisite checks from igt_fixture sections into subtest execution paths. For simplicity, pass any device close errors, including those from health checks, to next sections via a single .fd.drm data structure field. Moreover, postpone initial device health check until first actually selected subtest is started. In order to let that subtest skip on unsuccessful initial health check, not fail, move the decision whether to fail or skip on error from the health check helper to its users. Signed-off-by: Janusz Krzysztofik <janusz.krzysztofik@linux.intel.com> Reviewed-by: Marcin Bernatowicz <marcin.bernatowicz@linux.intel.com>
2021-01-20i915/gem_create: Exercise an impossible allocationChris Wilson
The largest processor in the works can support 57b of address space, far more memory than we can afford to use in CI! It is safe to assume that we will not have 64b processors for some time, so we can use the top bit to exercise our oversized object detection. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Matthew Auld <matthew.auld@intel.com>
2021-01-20i915/gem_create: Check wrap condition for -1Chris Wilson
Check that we correctly reject an object size that will intentionally wrap upon aligning to a page. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Matthew Auld <matthew.auld@intel.com>
2021-01-17i915/gem_exec_schedule: Tighten estimate for nreqChris Wilson
Each bundle is 3 requests, so trim the workload estimate accordingly. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-14i915/gem_ppgtt: Migrate memory check out of render blitsZbigniew Kempczyński
Running memory cache flush when bcs is doing blits leads to serializing bcs and rcs part. So we move memory check before blitting giving chance to parallel the execution. Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com> Cc: Dominik Grzegorzek <dominik.grzegorzek@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>
2021-01-14i915/gem_softpin: Fix object leak in softpin testZbigniew Kempczyński
Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@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>
2021-01-12tests/kms_rotation_crc: fix crc buffer overflow for slow platformsJuha-Pekka Heikkila
on bad tiling tests there was nothing reading running crcs which could fill up crc ringbuffer. Fix this by draining crc buffer per round. Also unify all platforms execution path by taking reference crcs per pipe. Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com> Reviewed-by: Mika Kahola <mika.kahola@intel.com>
2021-01-12i915/gem_softpin: Set size=4096 before calling __gem_createChris Wilson
Upon converting to __gem_create(), we now need to set the size in the caller. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-11lib/i915: Replace size to pointer to size in __gem_create()Zbigniew Kempczyński
Sometimes we're interested how much memory as allocated within the i915 driver so we have to change function prototype/implementation to the pointer to the size. As __gem_create() has few users change is simple and non-intrusive. Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com> Cc: Andrzej Turko <andrzej.turko@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2021-01-11lib/i915: Split gem_create.c from ioctl_wrappers.cAndrzej Turko
In preparation for a variation on the exisiting GEM_CREATE API, split the ioctl from out of the large ioctl_wrappers.c Signed-off-by: Andrzej Turko <andrzej.turko@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2021-01-09i915/gem_spin_batch: Fix clearing engine flagsChris Wilson
A silly typo during patch cleanup, inverted ~0x3f. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-08i915/gem_exec_scheduler: Check dependency chains around enginesChris Wilson
Verify that we do not run a later request before its dependency on the same engine, even if the linkage is looped around all the other engines. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-08i915/gem_spin_batch: Remove redundant outer context for resumbitChris Wilson
Allow resubmit to run on contextless platforms. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
2021-01-08tests/kms_cursor_edge_walk:Add subtest descriptionArundhati Hagaragi
Added description for all subtests v2: modified subtests description (Sai) Signed-off-by: Arundhati Hagaragi <arundhati.hagaragi@intel.com> Cc: Gupta, Nidhi1 <nidhi1.gupta@intel.com> Cc: B S, Karthik <Karthik.B.S@intel.com> Cc: Patnana, Venkata Sai <Venkata.Sai.Patnana@intel.com> Reviewed-by: Patnana Venkata Sai <Venkata.Sai.Patnana@intel.com>
2021-01-08tests/kms_plane: Added test descriptionArundhati Hagaragi
Added test description for test case v2: modified subtests description to be more specific. (Karthik) v3: added and modified description for subtests to be more specific. (Karthik) v4: modified description for subtests v5: replaced few keywords to be more specific. (Karthik) Cc: Gupta, Nidhi1 <nidhi1.gupta@intel.com> Cc: B S, Karthik <Karthik.B.S@intel.com> Signed-off-by: Arundhati Hagaragi <arundhati.hagaragi@intel.com> Reviewed-by: Karthik B S <karthik.b.s@intel.com>
2021-01-08tests: Add new PSR2 selective fetch testPankaj Bharadiya
Selective fetch reduces display engine use of memory bandwidth by only fetching (reading from memory) the updated regions of the frame buffer and sending those updated regions to a panel with a PSR2 capability. The FB_DAMAGE_CLIPS plane property provides user-space a way inform kernel about the updated regions. Add new test to verify selective fetch by using FB_DAMAGE_CLIPS property to send updated regions. changes since v1: * alloc enough clips for all tests in stack and reuse (Jose) * set damage clip along with draw, refactor code, rename variables, etc (Jose) Signed-off-by: Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com> Reviewed-by: Gwan-gyeong Mun <gwan-gyeong.mun@intel.com>
2021-01-08tests/kms_rotation_crc: avoid recalculating refecence crcsJuha-Pekka Heikkila
Get those reference crcs only once since they stay the same. v2: Need to make exception for HSW, there crcs seem to vary across rendering pipes. This reduces generic rotation tests execution time on my ICL from 26s to 14s Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com> Reviewed-by: Karthik B S <karthik.b.s@intel.com>
2021-01-08tests/kms_plane_scaling: reduce repetitive work per roundJuha-Pekka Heikkila
create needed planes only when needed and not destroying them in between. This reduces execution time for clipping clamping dynamic tests on my ICL from 75s to 29s Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com> Reviewed-by: Karthik B S <karthik.b.s@intel.com>
2021-01-07i915/gem_ctx_param: Add subtests descriptionApoorva Singh
Add description for all subtests of this test v2: Modified few descriptions to be more specific Signed-off-by: Apoorva Singh <apoorva1.singh@intel.com> Cc: Melkaveri, Arjun <arjun.melkaveri@intel.com> Reviewed-by: Dec, Katarzyna <katarzyna.dec@intel.com>
2021-01-07tests/core_auth: Added test description for test casePriyanka Dandamudi
Added test description to all the available subtests. v2:Modified detailed test descriptions to brief one. Cc: Katarzyna Dec <katarzyna.dec@intel.com> Cc: Melkaveri, Arjun <arjun.melkaveri@intel.com> Signed-off-by: Priyanka Dandamudi <priyanka.dandamudi@intel.com>
2021-01-06i915/gem_ctx_engines: Skip store-dword testing on unusable enginesChris Wilson
If the engine does not support MI_STORE_DWORD, we cannot use IGT_SPIN_POLL_RUN. For simplicity, skip testing that engine, slightly better than skipping the entire test at least. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>