AgeCommit message (Collapse)AuthorFilesLines
2020-10-15i915/gem_userptr_blits: Tighten has_userptr()Chris Wilson1-6/+6
We use has_userptr() to determine if the different flags are supported, so it helps not to override the flags inside the test. Signed-off-by: Chris Wilson <> Reviewed-by: Tvrtko Ursulin <>
2020-10-15tests/core_hotunplug: Take care of closing fences before failingJanusz Krzysztofik1-11/+35
The test was designed to keep track of open device file descriptors for safe driver unbind on recovery from a failed subtest. In that context, fences introduced by commit 1fbd127bd4e1 ("core_hotplug: Teach the healthcheck how to check execution status") can affect device recovery as much as an open device file if not closed before unbind. Moreover, forced GPU reset which used to be applied on recovery from a failed i915 GPU health check is no longer reachable since a GPU hang hopefully detected by the new health check algorithm can now break the whole recovery procedure prematurely. Refactor local_i915_healthcheck() so it takes care of closing fences and returns a result to its caller instead of long jumping on failures believed to be recoverable. While avoiding use of igt_assert() and friends, report actual source and error code of failures via igt_warn_on_f(). Signed-off-by: Janusz Krzysztofik <> Cc: Chris Wilson <>
2020-10-15i915/gem_exec_param: Sync after an active failChris Wilson1-0/+2
As we submit a failing sequence of batches, flush the failures before continuing. Signed-off-by: Chris Wilson <> Acked-by: Mika Kuoppala <>
2020-10-15tests/core_hotunplug: Restore i915 debugfs health checkJanusz Krzysztofik1-6/+62
Removal of igt_fork_hang_detector() from local_i915_healthcheck() by commit 1fbd127bd4e1 ("core_hotplug: Teach the healthcheck how to check execution status") resulted in unintentional removal of an important though implicit test feature of detecting, reporting as failures and recovering from potential misses of debugfs subdirs of hot rebound i915 devices. As a consequence, unexpected failures or skips of other unrelated but subsequently run tests have been observed on CI. On the other hand, removal of the debugfs issue detection and subtest failures from right after hot rebinding the driver enabled the better version of the i915 GPU health check fixed by the same commit to detect and report other issues potentially triggered by device late close. Restore the missing test feature by introducing an explicit sysfs health check, not limited to i915, that verifies existence of device sysfs and debugfs areas. Also, split hotrebind/hotreplug scenarios into a pair of each, one that performs the health check right after hot rebind/replug and delegates the device late close step to a follow up recovery phase, while the other one checks device health only after late closing it. v2: Give GPU health check a better chance to detect issues - run it before sysfs health checks. v3: Run sysfs health check on any hardware, not only i915. Signed-off-by: Janusz Krzysztofik <> Cc: Chris Wilson <> Reviewed-by: Marcin Bernatowicz <>
2020-10-15i915/gem_exec_params: test overly large batchMatthew Auld1-1/+34
See if can make something explode with too large batch (1ULL << 32), while also making the batch_len implicit. We should also try each engine since batch_len seems to have different interactions related to that. Signed-off-by: Matthew Auld <> Reviewed-by: Chris Wilson <> Signed-off-by: Chris Wilson <>
2020-10-15tests/i915: Treat gen as unsigned for forward compatibilityChris Wilson31-56/+56
We want to recognise future devices (gen = -1u) and treat them as an extension of the latest known device, which is typically true. Signed-off-by: Chris Wilson <> Acked-by: Zbigniew Kempczyński <>
2020-10-15lib: Use unsigned gen for forward compatible testsChris Wilson2-9/+11
Unknown, so future, gen are marked as -1 which we want to treat as -1u so that always pass >= gen checks. Closes: Signed-off-by: Chris Wilson <> Cc: Zbigniew Kempczyński <> Acked-by: Zbigniew Kempczyński <>
2020-10-15i915/gen9_exec_parse: Check oversized batch with length==0Chris Wilson1-0/+5
Include the implicit eb.batch_len=0 into the mix of various offsets and lengths. Signed-off-by: Chris Wilson <> Cc: Matthew Auld <> Reviewed-by: Matthew Auld <>
2020-10-14i915/perf_pmu: Fix perf fd leakTvrtko Ursulin1-52/+78
As it turns out opening the perf fd in group mode still produces separate file descriptors for all members of the group, which in turn need to be closed manually to avoid leaking them. v2: * Fix array sizing unload. Signed-off-by: Tvrtko Ursulin <> Reviewed-by: Chris Wilson <>
2020-10-14tests/kms_vrr: Add new subtest to validate Flipline modeBhanuprakash Modem1-31/+82
Check flipline mode by making sure that flips happen at flipline decision boundary. Example: if monitor vrr range is 40 - 60Hz and * flip at refresh_rate > 60Hz: Flip should happen at the flipline boundary & returned refresh rate would be 60Hz. * flip at refresh_rate == 50Hz: Flip should happen right away so returned refresh rate is 50Hz. * flip at refresh_rate < 40Hz: Flip should happen at the vmax so the returned refresh rate would be 40Hz. v2: * s/*vblank_ns/*event_ns/ (Manasi) * Reset vrr_enabled state before enabling it (Manasi) Cc: Harry Wentland <> Cc: Nicholas Kazlauskas <> Cc: Manasi Navare <> Signed-off-by: Bhanuprakash Modem <> Reviewed-by: Nicholas Kazlauskas <> Reviewed-by: Manasi Navare <>
2020-10-14tests/kms_vrr: Use atomic API for page flipBhanuprakash Modem1-37/+39
We should avoid using drmModePageFlip as it'll only be used for legacy drivers, instead, use igt_display_commit_atomic() API to page flip for atomic display code path. v2: * Look for the page flip event not for the vblank event (Nicholas) * Fix to flip with different FBs (Bhanu) v3: * s/get_vblank_event_ns/get_kernel_event_ns/ (Manasi) * Add a comment to capture the flip event (Manasi) * Make sure we are reading valid event (Bhanu) * Test clean-up (Bhanu) v4: * s/*vblank_ns/*event_ns/ (Manasi) Cc: Harry Wentland <> Cc: Nicholas Kazlauskas <> Cc: Manasi Navare <> Signed-off-by: Bhanuprakash Modem <> Reviewed-by: Nicholas Kazlauskas <> Reviewed-by: Manasi Navare <>
2020-10-13tests/kms_addfb_basic: Renaming tests as legacy tilingSwati Sharma2-14/+14
Tests require legacy get_tiling/set_tiling API's. Renaming the subtest names to make it obvious that these are legacy-only tests. v2: Made test name consistent (Matt) v3: Changed test names in fastfeedback (Petri) Suggested-by: Matt Roper <> Signed-off-by: Swati Sharma <> Acked-by: Matt Roper <> Reviewed-by: Petri Latvala <>
2020-10-12lib/igt_device_scan: Return true from igt_device_find_first_i915_discrete_card()Lyude Paul3-9/+14
So that we can also print a relevant error message when failing to find any devices in intel_gpu_top. Signed-off-by: Lyude Paul <> Cc: Zbigniew Kempczyński <> Reviewed-by: Zbigniew Kempczyński <>
2020-10-12lib/igt_device_scan: init card in igt_device_find_first_i915_discrete_card()Lyude Paul1-0/+2
Because we never initialize the card pointer passed to igt_device_find_first_i915_discrete_card() if we don't match any cards, we make the mistake of checking the contents of card in main() in intel_gpu_top.c before they've actually been initialized, which can lead to a segfault in some scenarios: # intel_gpu_top intel_gpu_top: ../tools/intel_gpu_top.c:1297: tr_pmu_name: Assertion `ret == (bufsize-1)' failed. abort--core dumped So, fix it by making sure to initialize card in igt_device_find_first_i915_discrete_card() like we do in igt_device_card_match(). Signed-off-by: Lyude Paul <> Reported-by: Chris Siebenmann <> Cc: Zbigniew Kempczyński <> Fedora bugzilla:
2020-10-12lib: Initialise 'wedged' in case of debugfs failChris Wilson1-0/+1
If the debugfs dir cannot be found, the read/write of wedged status will fail and leave the local variable unset. Give it a value to ensure a consistent result. Signed-off-by: Chris Wilson <> Reviewed-by: Mika Kuoppala <>
2020-10-12lib: Don't fail debugfs lookup on an expected absent drm deviceChris Wilson1-1/+1
When looking up the /dev/dri/card0 for a render device, skip over holes in the minor index. Signed-off-by: Chris Wilson <> Reviewed-by: Mika Kuoppala <>
2020-10-11i915/gem_exec_capture: Check for preempt-reset for rescheduling captureChris Wilson1-0/+1
The async capture is implemented as a side-effect of preempt-reset, restricting it's availablity to the more recent machines. In theory it can be made to work with gen8, we just need to keep on breaking up the global reset into smaller chunks that are free to be rearranged. Signed-off-by: Chris Wilson <> Acked-by: Mika Kuoppala <>
2020-10-11i915/gem_exec_reloc: Fix MI_STORE_DWORD_IMM invocation for gen5Chris Wilson1-7/+13
gen5 not only needs the MI_USE_GGTT flag, but also I915_EXEC_SECURE. Signed-off-by: Chris Wilson <> Acked-by: Mika Kuoppala <>
2020-10-10i915/gem_ctx_persistence: Verify userptr vs context cleanupChris Wilson1-0/+47
Verify that the wait for userptr cleanup is after we have cancelled the non-persistent hanging context. Signed-off-by: Chris Wilson <> Cc: Jon Bloomfield <> Acked-by: Mika Kuoppala <>
2020-10-09lib: Launch spinners from inside userptrChris Wilson3-43/+80
Add support for dummyload to be userptr, the variation in object type may be useful in some tests and to ensure complete coverage of some dark corners. Signed-off-by: Chris Wilson <> Reviewed-by: Mika Kuoppala <>
2020-10-09i915/gem_exec_schedule: Set preempt_timeout_ms for fast hang testsChris Wilson1-11/+26
Reduce the preemption timeout to 150ms (from infinity for tgl! tsk, tsk) so that the preemption hang tests run quicker. Signed-off-by: Chris Wilson <> Acked-by: Mika Kuoppala <>
2020-10-09prime_vgem: Check that we wrap the vgem mmap with userptrChris Wilson2-0/+48
This came up in a discussion about importing virtio dma-buf, which are themselves plain shmemfs objects and so not only backed by struct pages, but wrappable by userptr. vgem share the same properties and so should serve as a useful proxy for testing. Signed-off-by: Chris Wilson <> Cc: "Graunke, Kenneth W" <>, Cc: "Lahtinen, Joonas" <> Cc: "Kondapally, Kalyan" <> Reviewed-by: Tvrtko Ursulin <>
2020-10-08i915/gem_exec_capture: Set preempt-timeout to speed up hangcheckChris Wilson1-2/+5
We set a goal for hangcheck to remove the hung request, and this in part depends on hangcheck being able to make reasonable progress. Signed-off-by: Chris Wilson <> Acked-by: Mika Kuoppala <>
2020-10-07i915/gem_exec_capture: Check the capture runs in isolationChris Wilson1-2/+64
Capturing the error state for one context should not impede progress of other contexts across the system. That is we reset the engine, remove the context from the execution queue, then capture it. Once the hanging request has been removed, we can execute any other context instead. Signed-off-by: Chris Wilson <> Cc: Mika Kuoppala <> Reviewed-by: Mika Kuoppala <>
2020-10-07tests: Remove kms_crtc_background_color testPankaj Bharadiya5-191/+1
BACKGROUND_COLOR property is not supported in kernel as of now. Following patch attempted to add support but never got merged due to lack of userspace support. This test case is always skipped, as it does not find the BACKGROUND_COLOR prop support hence remove it. Signed-off-by: Pankaj Bharadiya <> Acked-by: Martin Peres <> Acked-by: Matt Roper <>
2020-10-06lib/igt_chamelium: Use curl timeout for xmlrpc callsPetri Latvala1-1/+12
Use of timeouts everywhere is meaningless if xmlrpc calls are allowed to be blocking forever. v2: Use milliseconds correctly (Juha-Pekka) Signed-off-by: Petri Latvala <> Cc: Kunal Joshi <> Cc: Arkadiusz Hiler <> Cc: Juha-Pekka Heikkila <> Reviewed-by: Juha-Pekka Heikkila <>
2020-10-06core_hotplug: Teach the healthcheck how to check execution statusChris Wilson1-26/+25
Closes: Signed-off-by: Chris Wilson <> Acked-by: Mika Kuoppala <>
2020-10-05i915/gem_mmap_wc: Align subtests with correct function callsApoorva Singh1-3/+3
- Fix the name of subtest "write-gtt-read-gtt" - Fix subtests "write-wc-read-gtt" and "write-gtt-read-gtt" to call correct fucntions Cc: Chris Wilson <> Cc: Melkaveri, Arjun <> Signed-off-by: Apoorva Singh <> Reviewed-by: Ashutosh Dixit <> Signed-off-by: Chris Wilson <>
2020-10-04tests/kms_chamelium: Test HPD for connector with all valid pipesMohammed Khajapasha1-0/+54
Test hpd test for a connector with all valid pipes set in it's valid crtc mask. v1: Added hpd test for a connector with all it's pipes for DP & HDMI v2: Added hdp test case for VGA <Joshi, Kunal1> Signed-off-by: Mohammed Khajapasha <>
2020-10-02lib/igt_core: Reinitialize print mutex in child processZbigniew Kempczyński1-2/+3
IGT are prone to deadlock in igt_log() in following scenario: 1. Parent process creates additional thread which for example is doing endless loop. 2. Thread sometimes is logging to console using igt_info(). This locks and unlocks print_mutex. 3. If in the meantime parent process will spawn child process it can be created having print_mutex locked (thread entered igt_vlog() function and entered critical section). When child will try to log it will deadlock. We should reinitialize print_mutex in child process to avoid use inherited value. Signed-off-by: Zbigniew Kempczyński <> Cc: Petri Latvala <> Reviewed-by: Petri Latvala <>
2020-10-01lib/intel_batchbuffer: Prepare batch to use in allocator infrastructureZbigniew Kempczyński31-264/+253
With upcoming of allocator code we need to ensure batch will execute with appropriate context. If mismatch between allocator data and batch could lead to strange or wrong results. All functions which could change context in execbuf called from intel_bb were removed. As an allocator requires size (which was not previously required in intel_bb) adding object to intel_bb is now mandatory. Signed-off-by: Zbigniew Kempczyński <> Cc: Dominik Grzegorzek <> Cc: Chris Wilson <> Reviewed-by: Chris Wilson <> Signed-off-by: Chris Wilson <>
2020-09-30drm-uapi: Re-synchronize drm_fourcc.h with kernelMatt Roper1-17/+315
drm_fourcc.h should generally be a direct copy of the kernel's header file. There have recently been a couple IGT commits that added not-yet-upstream framebuffer modifiers to IGT's copy of this header which isn't the standard procedure for handling pre-upstream changes like this. We've already ensured that the IGT tests and libraries that use those pre-upstream IDs has switched to pulling their values from a different local IGT header instead, so let's re-synchronize the drm_fourcc.h header with the latest copy from drm-tip now. This aligns IGT's drm_fourcc.h to the latest kernel commit da3a9e9a6aa9 ("drm/fourcc: fix Amlogic Video Framebuffer Compression macro") v2: Split handling of non-upstream CCS_CC modifier into separate patch from the drm_fourcc.h resync. (Lucas) Cc: Mika Kahola <> Cc: Lucas De Marchi <> Fixes: 37bc7b51024b ("drm-uapi/drm_fourcc: Format modifier for GEN12 render engine with Color Clear") Signed-off-by: Matt Roper <> Reviewed-by: Lucas De Marchi <>
2020-09-30lib/igt_fb: Use local definition of GEN12_RC_CCS_CC fb modifierMatt Roper1-4/+4
Support for CCS compression with Clear Color has not landed in the kernel yet, but tests for it already exist in IGT. Until kernel support lands, we should use a local copy of the fb modifier ID from lib/ioctl_wrappers.h; the ID that was manually added to drm_fourcc.h UAPI header will be removed the next time we re-synchronize that header with the kernel. v2: Split igt_fb modifier usage into separate patch from the drm_fourcc.h resync. (Lucas) Signed-off-by: Matt Roper <> Reviewed-by: Lucas De Marchi <>
2020-09-30tests: Add nouveau-crc testsLyude Paul5-1/+428
We're finally getting CRC support in nouveau, so let's start testing this in igt as well! While the normal CRC capture tests are nice, there's a number of Nvidia-specific hardware characteristics that we need to test as well. The most important one is known as a "notifier context flip". Basically, Nvidia GPUs store generated CRCs in an allocated memory region, referred to as the notifier context, that the driver programs itself. Strangely, this region can only hold a limited number of CRC entries, and once it runs out of available entries the hardware simply sets an overrun bit and stops writing any new CRC entries. Since igt-gpu-tools doesn't really have an expectation of only being able to grab a limited number of CRCs, we work around this in nouveau by allocating two separate CRC notifier regions each time we start capturing CRCs, and then flip between them whenever we get close to filling our currently programmed notifier context. While this keeps the number of CRC entries we lose to an absolute minimum, we are guaranteed to lose exactly one CRC entry between context flips. Thus, we add some tests to ensure that nouveau handles these flips correctly (pipe-[A-F]-ctx-flip-detection), and that igt itself is also able to handle them correctly (pipe-[A-F]-ctx-flip-skip-current-frame). Since these tests use a debugfs interface to manually control the notifier context flip threshold, we also add one test to ensure that any flip thresholds we set are cleared after a single CRC capture (ctx-flip-threshold-reset-after-capture). In addition, we also add some simple tests to test Nvidia-specific CRC sources. Changes since v5: * Fix typo Changes since v4: * Don't clear the currently set display pipe at the end of each iteration of pipe tests, otherwise we'll accidentally leave ourselves with no configured CRTCs when the test exits. Instead clear it at the start of each iteration of pipe tests but only if we just finished testing a different pipe. * Get rid of outdated comment about test_ctx_flip_detection() being limited to a single pipe * Clarify comments describing guarding against CRC collisions in test_ctx_flip_detection() * Make a small doc blurb for test_ctx_flip_detection(), it's a rather unusual and nvidia-specific behavior * Mention in test_ctx_flip_detection() that we also explicitly check that we've skipped -exactly- one frame. tl;dr more then one frame is too slow, less then one frame means a context flip just didn't happen when it should have. * Also check that the flip threshold we set in test_ctx_flip_threshold_reset_after_capture() isn't ignored by the driver * s/(create|destroy)_colors()/\1_crc_colors/g Changes since v3: * Update .gitlab-ci.yml to make nouveau exempt from the test-list-diff test, since all the cool kids are doing it and we don't care about autotools for nouveau Changes since v2: * Fix missing include in tests/nouveau_crc.c, this should fix builds for aarch64 Changes since v1: * Fix copyright year in nouveau_crc.c Reviewed-by: Jeremy Cline <> Signed-off-by: Lyude Paul <>
2020-09-30lib/igt_kms: Hook up connector dithering propLyude Paul2-0/+6
Nvidia display hardware provides a set of flexible dithering options for CRTCs. This dithering is actually noticeable in the CRC output for all available tap points, and can be seen as CRC values for identical frames cycling between either 2 or 4 values repeatedly (each one of these values is a different dithering phase applied to the source output). Of course, this is very likely to break tests using CRC readback since we don't expect the CRC to change if the source content hasn't changed. So, hook up support for configuring the dithering property and reset it to off from igt_display_reset() when applicable. Reviewed-by: Jeremy Cline <> Signed-off-by: Lyude Paul <>
2020-09-30lib/igt_debugfs: Add igt_debugfs_pipe_dir()Lyude Paul2-0/+22
Like igt_debugfs_connector_dir(), but for pipes instead. Changes since v4: * Make igt_debugfs_pipe_dir() much smaller - jcline * Fixup docs - jcline Reviewed-by: Jeremy Cline <> Signed-off-by: Lyude Paul <>
2020-09-30lib/igt_core: Add igt_require_fd()Lyude Paul1-0/+12
Like igt_assert_fd(), but using igt_require() instead Changes since v1: * Fix documentation error in igt_require_fd() - Petri Latvala Reviewed-by: Jeremy Cline <> Signed-off-by: Lyude Paul <>
2020-09-30lib/igt_core: Fix igt_assert_fd() documentationLyude Paul1-2/+2
As Petri Latvala pointed out, some of the documentation in this macro is mistakenly copied from the other igt_assert*() macros. Let's fix that. Reviewed-by: Jeremy Cline <> Signed-off-by: Lyude Paul <>
2020-09-30lib/intel_bufops: Avoid overallocate x-tiling and linear surfacesZbigniew Kempczyński1-1/+3
Height alignment was not properly set to 32 which was to big for x-tiling and linear surfaces and leads to overallocation. Linear surfaces currently don't require any height alignment (just 1), for x-tiling we use 8. Closes: Signed-off-by: Zbigniew Kempczyński <> Cc: Dominik Grzegorzek <> Cc: Chris Wilson <> Reviewed-by: Chris Wilson <>
2020-09-29i915/gem_ctx_persistence: Fix legacy engine selectionChris Wilson1-4/+4
For the legacy execbuf engine selection, we have to be careful in handling vcs if there is more than one engine, and specify which one we actually want. Signed-off-by: Chris Wilson <> Acked-by: Joonas Lahtinen <>
2020-09-29i915/gen9_exec_parse: Check parsing of large objectsChris Wilson1-0/+80
Simply check that we support parsing of batches as large as the uAPI allows. Signed-off-by: Chris Wilson <> Cc: Mika Kuoppala <> Reviewed-by: Mika Kuoppala <>
2020-09-29i915/gem_exec_parallel: Add basic userptr thrashingChris Wilson1-2/+29
Mix in a modicum of generic userptr thrashing for a quick (1s) BAT pass, as we have currently no coverage of userptr at all in BAT. Signed-off-by: Chris Wilson <> Reviewed-by: Joonas Lahtinen <>
2020-09-28i915/gem_ctx_persistence: Exercise cleanup after disabling heartbeatsChris Wilson1-0/+146
We expose the heartbeat interval on each engine, allowing the sysadmin to disable them if they prefer avoiding any interruption for their GPU tasks. A caveat to allowing the contexts to run without checks is that we require such contexts to be non-persistent and so cleaned up on closure (including abnormal process termination). However, we also need to flush any persistent contexts that are still inflight at that time, lest they continue to run unchecked. Signed-off-by: Chris Wilson <> Acked-by: Joonas Lahtinen <>
2020-09-25tests/kms_async_flips: Add test to validate asynchronous flipsKarthik B S3-0/+427
Asynchronous flips are issued using the page flip IOCTL. The test consists of two subtests. The first subtest waits for the page flip event to be received before giving the next flip, and the second subtest doesn't wait for page flip events. The test passes if the IOCTL is successful. v2: -Add authors in the test file. (Paulo) -Reduce the run time and timeouts to suit IGT needs. (Paulo) -Replace igt_debug's with igt_assert's to catch slow flips. (Paulo) -Follow IGT coding style regarding spaces. (Paulo) -Make set up code part of igt_fixture. (Paulo) -Skip the test if async flips are not supported. (Paulo) -Replace suggested-by. (Paulo) -Added description for test and subtests. v3: -Rename the test to kms_async_flips. (Paulo) -Modify the TODO comment. (Paulo) -Remove igt_debug in flip_handler. (Paulo) -Use drmIoctl() in has_async function. (Paulo) -Add more details in igt_assert in flip_handler. (Paulo) -Remove flag variable in flip_handler. (Paulo) -Call igt_assert in flip_handler after the warm up time. v4: -Calculate the time stamp in flip_handler from userspace, as the kernel will return vbl timestamps and this cannot be used for async flips. -Add a new subtest to verify that the async flip time stamp lies in between the previous and next vblank time stamp. (Daniel) v5: -Add test that alternates between sync and async flips. (Ville) -Add test to verify invalid async flips. (Ville) -Remove the subtest async-flip-without-page-flip-events. (Michel) -Remove the intel gpu restriction and make the test generic. (Michel) v6: -Change the THRESHOLD from 10 to 8 as failures are seen on CI on platforms <= gen10. -In older platforms(<= gen10), async address update bit in plane ctl is double buffered. Made changes in subtests to accomodate this. -Moved the igt_assert from flip_handler to individual subtest as we now have four subtests and adding conditions for the assert in flip handler is messy. v7: -Change flip_interval from int to float for more precision. -Remove the fb height change case in 'invalid' subtest as per the feedback received on the kernel patches. -Add subtest to verify legacy cursor IOCTL. (Ville) v8: -Add a cursor flip before async flip in cursor test. (Ville) -Make flip_interval double for more precision as failures are seen on older platforms on CI. v9: -Replace BUFS macro. (Ville) -Query cursor resolution from the kernel. (Ville) -Rename THRESHOLD to MIN_FLIPS_PER_FRAME. (Ville) -Use XRGB8888 instead of ARGB8888. (Ville) -Rename has_monotonic_timestamp to require_monotonic_timestamp. (Ville) -Make logic in alternate_sync_async subtest more readable. (Ville) -Rename get_vbl_timestamp_us() function. (Ville) -Rename has_async() to has_async_flip. (Ville) -Make data_t static. (Ville) -Fix leaking fb and res pointers. (Ville) -Remove async_capable variable. (Ville) -Move initialization to a function. (Ville) -Have a generic has_drm_cap() helper. (Ville) -Warm up logic removed. -Added TODO's for follow up work. v10: -Move flip timestamps inside data_t. (Ville) -Remove the redundant first flip in invalid subtest. (Ville) v11: -Pass cap ID to the igt_has_drm_cap helper instead of the whole structure. (Ville) -Fix the patch ordering. (Ville) Signed-off-by: Paulo Zanoni <> Signed-off-by: Karthik B S <> [vsyrjala: Fix integer vs. pointer mismatch] Signed-off-by: Ville Syrjälä <>
2020-09-25lib/igt_ioctl_wrappers: Add igt_has_drm_cap ioctl wrapperKarthik B S2-0/+19
Add a generic helper for DRM_IOCTL_GET_CAP ioctl. v10: -No changes. v11: -Pass cap ID instead of the whole structure. (Ville) -Fix the patch ordering. (Ville) Signed-off-by: Karthik B S <> [vsyrjala: make the docs and code match] Signed-off-by: Ville Syrjälä <>
2020-09-25i915/gem_ppgtt: Require contexts for context testsChris Wilson1-0/+14
Using the libdrm interface, failure to allocate a context upon demand was ignored. Switching to libigt, such failures are reported. Unfortunately, some machines lack context support and now fail instead of skipping a test they cannot perform. Closes: Signed-off-by: Chris Wilson <> Acked-by: Zbigniew Kempczyński <>
2020-09-16i915/gem_mmap: Modified offset in subtest "bad-size"Apoorva Singh2-19/+32
Subtest "bad-size" should keep valid/good offset corresponding to buffer object being mapped. Currently, subtest will pass for any value of size provided as the offset value itself will not allow to map any size of memory which defies the purpose of this subtest. The subtest should not pass due to bad offset value while it should pass only due to bad size provided. v2: Added new offset. Updated the same changes in "bad-size" subtest of gem_mmap_wc too. Signed-off-by: Apoorva Singh <> Cc: Melkaveri, Arjun <> Cc: Chris Wilson <> Cc: Priyanka Dandamudi <> Reviewed-by: Chris Wilson <> Signed-off-by: Chris Wilson <>
2020-09-16tools/intel_residency: adopt intel_residency to use bufopsZbigniew Kempczyński1-6/+4
IGT draw functions remove libdrm dependency so migrate to new API. Signed-off-by: Zbigniew Kempczyński <> Cc: Dominik Grzegorzek <> Cc: Chris Wilson <> Reviewed-by: Chris Wilson <> Signed-off-by: Chris Wilson <>
2020-09-16tests/perf: remove libdrm dependency for rendercopyZbigniew Kempczyński1-382/+293
Rendercopy now uses no-drm version so all users has to migrate to new interface. vx: it seems we've problem with GEM_MMAP_OFFSET mapping so for !llc platforms device mapping is used. Signed-off-by: Zbigniew Kempczyński <> Cc: Lionel Landwerlin <> Cc: Dominik Grzegorzek <> Cc: Chris Wilson <> Reviewed-by: Lionel Landwerlin <> Reviewed-by: Chris Wilson <> Signed-off-by: Chris Wilson <>
2020-09-16lib/rendercopy_bufmgr: remove rendercopy_bufmgrZbigniew Kempczyński4-202/+0
Remove transitional rendercopy_bufmgr, we don't need it anymore. Signed-off-by: Zbigniew Kempczyński <> Cc: Dominik Grzegorzek <> Cc: Chris Wilson <> Reviewed-by: Chris Wilson <> Signed-off-by: Chris Wilson <>