aboutsummaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* libdrm: planetest/atomictest: Fix up build issue missed in rebasingJohn Stultz2018-04-303-26/+26
| | | | | | | | | | | | We dropped commit 5a6afa130317 (BACKPORT: libdrm: atomic mode set) when moving forward to upstream libdrm, as it should be redundent. Unfortunately, the API in that commit is slightly different upstream, and thus the planetest and atomictest tests needed some updates to use the upstream API Change-Id: I76cd52f12f6679792a0cedb529973e426932c98c Signed-off-by: John Stultz <john.stultz@linaro.org>
* Merge remote-tracking branch 'freedesktop/master' into aosp/masterJohn Stultz2018-04-1355-906/+4030
|\ | | | | | | | | | | | | This merges the freedesktop/master branch into aosp/master Change-Id: I3104d45924f67d37808154d04c15518394204478 Signed-off-by: John Stultz <john.stultz@linaro.org>
| * meson,configure: include config.h automaticallyEric Engestrom2018-03-2028-112/+0
| | | | | | | | | | | | | | | | | | This will prevent any more missing `#include "config.h"` bug, at the cost of having to recompile some files that didn't need to be when changing build options. Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
| * tests: fix memory leak issueInki Dae2018-03-201-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | Fixed memory leak issue to drmModeRes and drmModePlaneRes objects. These objects were allocated by drmModeGetResources and drmModeGetPlaneResources functions but not freed properly. So this patch frees them by calling drmModeFreeResources drmModeFreePlaneResources functions at failure case. Signed-off-by: Inki Dae <inki.dae@samsung.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
| * tests/exynos: remove dead conditionSeung-Woo Kim2018-03-151-7/+0
| | | | | | | | | | | | | | | | There is already condition checking input values between 2 and 4096 so condition checking 0 is always false. Remove the dead condition. Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
| * tests/amdgpu: Fix misspellings of "suite"Michel Dänzer2018-03-022-12/+12
| | | | | | | | Acked-by: Christian König <christian.koenig@amd.com>
| * test/amdgpu: disable bo eviction test by defaultChunming Zhou2018-03-011-0/+2
| | | | | | | | | | | | | | | | | | | | | | if some system has no swap space and memory is less, than the test could fail. And bo eviction test takes much more time in some system, which effects automation test result and efficiency. So disable it by default now, only be used by developer manually. Signed-off-by: Chunming Zhou <david1.zhou@amd.com> Acked-by: Christian König <christian.koenig@amd.com>
| * drm/tegra: Sanitize format modifiersThierry Reding2018-02-191-14/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The existing format modifier definitions were merged prematurely, and recent work has unveiled that the definitions are suboptimal in several ways: - The format specifiers, except for one, are not Tegra specific, but the names don't reflect that. - The number space is split into two, reserving 32 bits for some "parameter" which most of the modifiers are not going to have. - Symbolic names for the modifiers are not using the standard DRM_FORMAT_MOD_* prefix, which makes them awkward to use. - The vendor prefix NV is somewhat ambiguous. Fortunately, nobody's started using these modifiers, so we can still fix the above issues. Do so by using the standard prefix. Also, remove TEGRA from the name of those modifiers that exist on NVIDIA GPUs as well. In case of the block linear modifiers, make the "parameter" smaller (4 bits, though only 6 values are valid) and don't let that leak into any of the other modifiers. Finally, also use the more canonical NVIDIA instead of the ambiguous NV prefix. This is based on commit 5843f4e02fbe86a59981e35adc6cabebee46fdc0 from Linux v4.16-rc1 and also updates modetest to use the new defines. Acked-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Thierry Reding <treding@nvidia.com>
| * tests/amdgpu: add bo eviction testChunming Zhou2018-02-082-1/+182
| | | | | | | | | | | | | | | | | | | | | | | | | | for(( i=1; i < 100; i++)) do echo "Hello, Welcome $i times " sudo ./amdgpu_test -s 1 -t 5 done with above stricpt, run in two terminals, will reproduce Felix's swap leeking issue. Signed-off-by: Chunming Zhou <david1.zhou@amd.com> Acked-by: Christian König <christian.koenig@amd.com>
| * tests/amdgpu: add missing config.h includeEmil Velikov2018-01-311-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise we'll end up without the macros set during configure stage. And effectively error out in sanity tests such as the mmap static assert. To reproduce, do a multilib build - 32bit build on 64bit machine. Cc: Fabio Pedretti <pedretti.fabio@gmail.com> Cc: Andrey Grodzovsky <Andrey.Grodzovsky@amd.com> Fixes: 33dcc29f7cc ("amdgpu: Add VMID reservation per GPU context test.") Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104819 Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
| * exynos/tests: use #ifdef for never-defined tokenEric Engestrom2018-01-311-2/+2
| | | | | | | | | | | | Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
| * always define HAVE_CAIROEric Engestrom2018-01-291-2/+2
| | | | | | | | | | | | Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
| * tests/etnaviv: drop unused `return 0`Eric Engestrom2018-01-291-3/+1
| | | | | | | | | | Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
| * tests/util: drop unused parametersEric Engestrom2018-01-291-3/+3
| | | | | | | | | | Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
| * tests/util: fix signed/unsigned comparisonsEric Engestrom2018-01-291-3/+2
| | | | | | | | | | Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
| * tests/amdgpu: drop unused variablesEric Engestrom2018-01-297-14/+7
| | | | | | | | | | Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
| * tests/amdgpu: add parentheses to make operation priority explicitEric Engestrom2018-01-291-1/+1
| | | | | | | | | | | | | | | | While at it, align with the other half on the next line. Cc: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
| * remove unnecessary double-semicolonEric Engestrom2018-01-292-2/+2
| | | | | | | | | | | | Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
| * amdgpu: Disable VM test suite by default for SI ASICsMichel Dänzer2018-01-263-1/+26
| | | | | | | | | | | | Hangs my Cape Verde. Acked-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Disable deadlock test suite by default for SI ASICsMichel Dänzer2018-01-261-1/+2
| | | | | | | | | | | | Hangs my Cape Verde. Acked-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Fix segfault in deadlock test.Andrey Grodzovsky2018-01-261-2/+2
| | | | | | | | | | | | | | | | If amdgpu_cs_query_fence_status terminates prematurely the BO sometimes is unmapped before helper thread writes a vlaue into it causing a segfault. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
| * amdgpu: Update deadlock test to not assert on ECANCELEDAndrey Grodzovsky2018-01-261-2/+2
| | | | | | | | | | | | | | | | Kernel will abort jobs for guilty (causing GPU hang) context with -ECANCELED don't assert if that the case. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Acked-by: Christian König <christian.koenig@amd.com>
| * modetest: Fix to check return value of asprintf()Seung-Woo Kim2018-01-251-1/+4
| | | | | | | | | | | | | | | | There is warning about ignoring return value of 'asprintf'. Fix to check return value of asprintf(). Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
| * amdgpu: Symlink .editorconfig to tests/amdgpuMichel Dänzer2018-01-181-0/+1
| | | | | | | | | | | | | | In order to use consistent editorconfig settings in both amdgpu directories. Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Don't dereference device_handle after amdgpu_device_deinitializeMichel Dänzer2018-01-161-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes use after free: ==2537== Invalid read of size 4 ==2537== at 0x1162C9: suite_deadlock_tests_enable (deadlock_tests.c:101) ==2537== by 0x10B157: amdgpu_disable_suits (amdgpu_test.c:421) ==2537== by 0x10B157: main (amdgpu_test.c:560) ==2537== Address 0x5e44f24 is 452 bytes inside a block of size 1,016 free'd ==2537== at 0x4C2BE1B: free (vg_replace_malloc.c:530) ==2537== by 0x504CD8B: amdgpu_device_reference (amdgpu_device.c:164) ==2537== by 0x504CD8B: amdgpu_device_deinitialize (amdgpu_device.c:307) ==2537== by 0x1162BB: suite_deadlock_tests_enable (deadlock_tests.c:97) ==2537== by 0x10B157: amdgpu_disable_suits (amdgpu_test.c:421) ==2537== by 0x10B157: main (amdgpu_test.c:560) ==2537== Block was alloc'd at ==2537== at 0x4C2CC05: calloc (vg_replace_malloc.c:711) ==2537== by 0x504CA5E: amdgpu_device_initialize (amdgpu_device.c:212) ==2537== by 0x116298: suite_deadlock_tests_enable (deadlock_tests.c:93) ==2537== by 0x10B157: amdgpu_disable_suits (amdgpu_test.c:421) ==2537== by 0x10B157: main (amdgpu_test.c:560) Reviewed-by: Christian König <christian.koenig@amd.com>
| * Add meson build systemDylan Baker2018-01-1214-0/+524
| | | | | | | | | | | | | | | | | | | | This patch adds a complete meson build system, including tests and install. It has the necessary hooks to allow it be used as a subproject for other meson based builds such as mesa. Signed-off-by: Dylan Baker <dylan.c.baker@intel.com> Reviewed-and-tested-by: Igor Gnatenko <i.gnatenko.brain@gmail.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
| * tests/amdgpu: execute copy linear on all the available ringsHawking Zhang2018-01-121-96/+104
| | | | | | | | | | | | | | Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
| * tests/amdgpu: execute const fill on all the available ringsHawking Zhang2018-01-121-70/+77
| | | | | | | | | | | | | | Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
| * tests/amdgpu: execute write linear on all the available ringsHawking Zhang2018-01-121-53/+58
| | | | | | | | | | | | | | Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
| * test/amdgpu: fix compiler warningsChristian König2018-01-091-4/+4
| | | | | | | | | | | | | | SWAP_32() should mask first and then shift. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
| * tests/amdgpu: Add return CUE_SUCCESS to suite_vcn_tests_clean.Andrey Grodzovsky2017-12-151-0/+2
| | | | | | | | | | | | | | | | fixes: 806d0803600000faecb4025d8e9c7490cb097c25 (amdgpu: Use new suite/test disabling functionality.) bug: https://bugs.freedesktop.org/show_bug.cgi?id=104280 Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Remove dummy CU_ASSERT_EQUAL.Andrey Grodzovsky2017-12-121-2/+0
| | | | | | | | | | | | | | Fixes test failure on rhel. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Qiang Yu <Qiang.Yu@amd.com>
| * amdgpu: Add explicit dependency test.Andrey Grodzovsky2017-11-302-0/+282
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test is as following: 1) Create context A & B 2) Send a command submission using context A which fires up a compute shader. 3) The shader wait a bit and then write a value to a memory location. 4) Send a command submission using context B which writes another value to the same memory location, but having an explicit dependency on the first command submission. 5) Wait with the CPU for both submissions to finish and inspect the written value. Test passes if the value seen in the memory location after both submissions is from command B. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Acked-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Dynamicly disable BO suite "Metadata" test.Andrey Grodzovsky2017-11-292-2/+3
| | | | | | | | | | | | | | Disable the test instead of doing #ifdef 0 Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Switch amdgpu CS tests enabling to the new way.Andrey Grodzovsky2017-11-293-33/+38
| | | | | | | | | | Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Disable deadlock test suite for Vega 10Andrey Grodzovsky2017-11-153-1/+25
| | | | | | | | | | | | | | The test stalls the CP, until RCA is done the test is disabled to not disrupt regression testing. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
| * amdgpu: Add memory over allocation test.Andrey Grodzovsky2017-11-141-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | Allocates 1 TB of memory. Test is disabled by default since it's triggers OOM killer. v2: FIx the test to only alloc the BO and assert if return value not equal to -ENOMEM and remove test disable on start. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Move memory alloc tests in bo suite.Andrey Grodzovsky2017-11-132-49/+49
| | | | | | | | | | Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Use new suite/test disabling functionality.Andrey Grodzovsky2017-11-136-134/+123
| | | | | | | | | | | | | | | | Switch from disabling tests during run to using the new disable API. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Add functions to disable suites and tests.Andrey Grodzovsky2017-11-132-18/+170
| | | | | | | | | | | | | | | | | | | | Suits are diasbled based on hooks they provide (e.g incompatible ASIC or missing blocks). Single tests are diasbled explicitly. Suit or test can be forced to execute even if disabled by adding -f flag after specifying suit [test] ids. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * exynos: change the license to X11/MITInki Dae2017-11-073-24/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change GPL license of Exynos related code to X11/MIT. I'd like to keep a consistent license across all Exynos code because License checker notices two more licenses exist in libdrm. For the license change I need to get your agree - all committers. So please give me Acked-by if you agree with me. Signed-off-by: Inki Dae <inki.dae@samsung.com> Acked-by: Hyungwon Hwang <human.hwang@samsung.com> Acked-by: SooChan Lim <sc1.lim@samsung.com> Acked-by: Sangjin LEE <lsj119@samsung.com> Acked-by: Boram Park <boram1288.park@samsung.com> Acked-by: Seung-Woo Kim <sw0312.kim@samsung.com> Acked-by: Joonyoung Shim <jy0922.shim@samsung.com> Acked-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Acked-by: Jan Vesely <jan.vesely@rutgers.edu>
| * amdgpu: Fix wrappers for AMDGPU_VM IOCTL.Andrey Grodzovsky2017-11-031-2/+2
| | | | | | | | | | | | | | | | | | Rmove amdgpu_context_handle from the interface and use amdgpu_device_handle instead. Uupdate VMID reservation test accordingly. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: Add VMID reservation per GPU context test.Andrey Grodzovsky2017-10-274-1/+175
| | | | | | | | | | | | | | | | | | | | | | The test will Reserve a VMID, submit a command and unreserve the VMID. v2: Wrappers names were changed. Signed-off-by: Andrey Grodzovsky <Andrey.Grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * modetest: Allow full testing of primary planesVille Syrjälä2017-10-191-1/+2
| | | | | | | | | | | | | | | | Allow the user to override the default configuration set by setcrtc for the primary plane. On some hardware primary planes can be freely positioned/sized, and it'd be nice if we can actually test that feature. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
| * modetest: Decode IN_FORMATS plane blob propertyKristian H. Kristensen2017-10-181-0/+86
| | | | | | | | | | | | | | This teaches modetest about the new IN_FORMATS blob and decodes the blob to show supported formats and modifiers. Signed-off-by: Kristian H. Kristensen <hoegsberg@chromium.org>
| * tests/amdgpu: fix uvd enc data corruption issueJames Zhu2017-10-062-3/+5
| | | | | | | | | | | | | | | | | | | | In uvd encode parameter package, parameters input_pic_luma_pitch and input_pic_chroma_pitch should be picture width align with hardware alignment. The hardware alignment is 16 for amdgpu family earlier than AMDGPU_FAMILY_AI, and 256 for later than and including AMDGPU_FAMILY_AI. Signed-off-by: James Zhu <James.Zhu@amd.com> Reviewed-by: Leo Liu <leo.liu@amd.com>
| * tests/amdgpu: add new uvd enc support checkJames Zhu2017-10-061-6/+21
| | | | | | | | | | | | | | | | Query hardware IP information to find out if there are uvd encode rings ready for use in kernel driver. Signed-off-by: James Zhu <James.Zhu@amd.com> Reviewed-by: Leo Liu <leo.liu@amd.com>
| * amdgpu: Add deadlock detection test suit.Andrey Grodzovsky2017-10-044-2/+270
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adding initial tests for locks detection when SW scheduler FIFO is full. The test works by submitting a batch of identical commands which make the CP stall waiting for condition to become true. The condition is later satisfied form a helper thread. Other events that happen during this time might create deadlock situations. One such example is GPU reset triggered by this stall when amdgpu_lockup_timeout != 0. v2: Increase the delay from 2 to 100 ms. Comment out the compute test until it's working. Typos fix. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
| * amdgpu: make userptr unit test more interestingChristian König2017-10-041-0/+8
| | | | | | | | | | | | | | Do a fork() to force some MMU callbacks. Signed-off-by: Christian König <christian.koenig@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com>
| * tests/amdgpu: add missing header to SOURCESAlex Deucher2017-08-311-1/+2
| | | | | | | | | | | | | | | | | | Fixes the tarball generation. fixes: 9d133dd08720d80dfc8ce098bf0972 (tests/amdgpu: add uvd encode unit tests) bug: https://bugs.freedesktop.org/show_bug.cgi?id=102391 Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>