529 Commits

Author SHA1 Message Date
Chris Wilson
fb7bc2e8d1 tests/gem_lut_handle: Limit testing LUT interface to recent kernels
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-01-17 15:10:29 +00:00
Chris Wilson
d5517a1301 tests/gem_lut_handle: Expand negative testing
Pass in lots of execs and relocs trying to trick the kernel into making
a mistake.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-01-17 15:05:20 +00:00
Chris Wilson
230d77f1d0 tests: Benchmark new API for using a LUT with the execbuffer
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-01-17 14:31:01 +00:00
Chris Wilson
ec2eac6d7b tests: Exercise new API for using a LUT with the execbuffer
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-01-17 14:30:43 +00:00
Yi Sun
cdd352df95 tests/testdisplay.c: Fix the issue which don't display anything until '-o' given.
Signed-off-by: Yi Sun <yi.sun@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-01-14 15:31:52 +01:00
Mika Kuoppala
c612481a19 tests/gem_seqno_wrap: skip if debugfs entry is not there
Return error code 77 to skip test if debugfs entry is not
available.

Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=59116
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-01-08 12:20:44 +01:00
Chris Wilson
2d0a8e8545 tests: Add basic testing of gem_pin
Including exercising races versus interrupts.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-01-07 12:32:56 +00:00
Yi Sun
05bfbf4227 tests/testdisplay: Specify the display.
It can specify the display by the connector id which list as the first column of ./testdisplay -i.
E.g. command "./testdiplay -o 1,4" means setting number 4 mode line on the display with connector id 1.

v2. Specify the display by id which can be got from option '-i'

Signed-off-by: Yi Sun <yi.sun@intel.com>
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2012-12-27 14:38:55 +08:00
Mika Kuoppala
33f09f6954 tests/gem_seqno_wrap: adapt to new next_seqno debugfs interface
- adapt to use debugfs interface that can set seqno to arbitrary value
- fix dynamic buffer allocation

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-21 20:49:22 +01:00
Daniel Vetter
5825cf807e tests/prime_nv_pcopy: guard output for subtest listing 2012-12-20 23:30:33 +01:00
Dave Airlie
71ba0038db intel/udl tests;
basic test to share a BO, add as a udl framebuffer, and call the dirty
ioctl on it so we cause the vmapping to happen

[danvet: Snatched up from Dave's prime branch, ocd name and bikeshed
whitespace a bit.]
2012-12-20 23:31:32 +01:00
Daniel Vetter
d798ab9c2a tests: add testcase to check igt runtime enviroment
Now that we've abandonded the autohell testrunner, need to port this
over. Easiest is to just add another testcase ...

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-20 11:02:19 +01:00
Ville Syrjälä
f0546374a0 kms_flip: Add -lrt back
kms_flip doesn't build due to missing -lrt.

The build was broken due to a typo in this commit:

commit acdf7171264a5139caabb78127c9eef5080c0682
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Sat Dec 15 00:48:47 2012 +0100

    tests: s/flip_test/kms_flip

    OCD wins!

    Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>

For some reason libudev.pc brings in -lrt as well, which probably
caused the typo to go unnoticed.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-18 16:04:25 +01:00
Daniel Vetter
cef68158dd tests/kms_flip: don't die on stdin input
Seems to be a leftover from fliptest ...

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-18 10:25:55 +01:00
Daniel Vetter
0af2b184ad lib: extract kmstest_get_pipe_from_crtc_id 2012-12-17 15:30:54 +01:00
Daniel Vetter
573d59dd14 tests/gem_flink: enable flink lifetime subtest
Somehow fumbled this.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-17 15:30:53 +01:00
Daniel Vetter
acdf717126 tests: s/flip_test/kms_flip
OCD wins!

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-17 15:30:53 +01:00
Daniel Vetter
f56384c2c0 tests/flip_test: add flip vs. rmfb testcase
To check that the kernel doesn't fall over when tearing down a life
fb. Confirmed that it exercises the right codepath with printk.

Also fix an issue Imre introduced in

commit fe7fea0be3b5f418b76dc7834e73b31827484429
Author: Imre Deak <imre.deak@intel.com>
Date:   Tue Oct 16 04:09:43 2012 +0300

    flip_test: add event sequence number tracking

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-17 15:30:53 +01:00
Daniel Vetter
df41e1a6bb flip_test: recreate fb
... to test the latency of rmfb, getfb and addfb. Since if those still
can cause spikes, we have a problem.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-17 15:30:53 +01:00
Daniel Vetter
8ed0112f88 tests/flip_test: split out timestamp checks into subtest
This way we can still test basic pageflips on kernels with broken
locking while still failing when the timestamps/framecounts are wrong.

Also disable the delay check on analog tv, timings on those ports are
truely screwed-up

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-17 15:30:53 +01:00
Alan Coopersmith
f185699a4b tests/gem_seqno_wrap.c: include <signal.h> for definition of kill()
Fixes build failure on Solaris:
gem_seqno_wrap.c: In function ‘run_cmd’:
gem_seqno_wrap.c:328:3: error: implicit declaration of function ‘kill’ [-Werror=implicit-function-declaration]

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-16 19:45:57 +01:00
Daniel Vetter
c2e05af353 tests/prime_nv_pcopy: convert to subtests
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-15 15:57:20 +01:00
Daniel Vetter
cc4eeb990f tests/prime_nv_tests: convert to subtests
And properly fail the failing ones - bloody hate it when the tests lie
to me ...
2012-12-15 15:30:19 +01:00
Mika Kuoppala
a2452d68a0 tests/gem_seqno_wrap: dont sync when crossing half of seqno space
For seqno comparison to work they have to be less than UINT32_MAX/2
apart. So when crossing the half way of seqno space, be careful not
to sync anything as this causes gpu hangs. Do real test with
syncing only when we are about to wrap.

v2: Don't spam if no rendercopy was found, only warn once
2012-12-13 12:52:26 +01:00
Imre Deak
7ab837b214 flip_test: fix link error due to missing -lrt
Needed by clock_gettime(). This isn't a problem if libudev is used,
as that pulles librt with it.

Signed-off-by: Imre Deak <imre.deak@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-13 12:52:26 +01:00
Chris Wilson
e0ce231bf3 tests/gem_*_tiled_blits: Use the vma limiter to present address space exhaustion
References: https://bugs.freedesktop.org/show_bug.cgi?id=58113
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-12-12 14:33:59 +00:00
Chris Wilson
de9621b4f5 tests/gem_tiled_pread_pwrite: Allow the kernel to reap the GTT address space
Otherwise we can not run this test on 32-bit systems.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-12-12 14:33:59 +00:00
Chris Wilson
b1ee03c540 tests/gem_tiled_swapping: Don't needless crash on 32-bit systems
Only 32-bit of mmap address space, but with PAE we may be trying to
allocate more than 4 GiB of memory.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-12-12 14:33:59 +00:00
Maarten Lankhorst
4cd21795d2 tests/prime_nv_pcopy.c: fail if nouveau_pushbuf_kick fails rather than spinning 2012-12-10 13:51:57 +01:00
Daniel Vetter
3084263782 tests: disable gem_exec_bad_domains/conflicting-write-domain
Kernel checks have been eased in

commit c1f093e09c4ceb583b04d11e767bb3201812e4d2
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Mon Dec 3 11:49:07 2012 +0000

    drm/i915: Remove check for conflicting relocation write-domains
2012-12-07 23:34:23 +01:00
Chris Wilson
c0dbf04b05 tests: Add a basic test for tiled render copies
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-12-06 20:35:28 +00:00
Chris Wilson
3ad92902e1 tests: Add basic test for render blits
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-12-06 19:51:54 +00:00
Daniel Vetter
51f08301ab tests/gem_exec_nop: implemented correct SKIP reporting
I think I need a testsuite for test writing.
2012-12-05 19:29:11 +01:00
Daniel Vetter
53e184b228 tests/gem_dummy_reloc_loop: some updates
- convert to subtests
- shut up stderr output for successful runs

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-05 10:18:03 +01:00
Daniel Vetter
ad5919617c tests: fixup gem_exec_nop subtests
Note to self: No more pushing after 12 o'clock midnight. Not a good
idea, too embarassing.
2012-12-05 07:54:08 +01:00
Daniel Vetter
d9d9578f3b tests: run no-op batches on all rings
For Ben ...
2012-12-04 17:13:05 +01:00
Mika Kuoppala
796fd58a17 tests: add gem_seqno_wrap
This test uses debugfs entry to set next_seqno close
to a wrapping point and then creates a load with dependant
buffer objects or with specified command to induce the wrap.

v2: Use new get_rendercpy_func as suggested by Daniel Vetter.

Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-04 23:03:54 +01:00
Daniel Vetter
175fc656eb tests/Makefile.am: Add a comment about the subtest infrastructure 2012-12-04 10:37:55 +01:00
Daniel Vetter
6daae8bcb6 tests/gem_flink: check flink lifetime rules
flink names may not be destroyed while there's still a userspace
handle around. Test this by
- exporting an flink name from fd2
- open a gem bo from that name in fd
- close fd2, then open a new drm file (so that the original handle
  disappears)
- check whether the same flink name still works
2012-12-01 13:07:45 +01:00
Daniel Vetter
d8df90dc6b tests/gem_exec_bad_domains: add more bad domains
- mulitple write domains
- conflicting write domains
- not-yet-defined gpu domains

Also convert to subtests while at it.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-01 00:58:14 +01:00
Daniel Vetter
0d7139af58 tests/gem_stress: prevent segfault in getopt parsing
Needs a terminal element in the long option array.
2012-11-29 15:01:09 +01:00
Daniel Vetter
64f669f7a9 lib: extract get_render_copyfunc
Otherwise we won't update all the tests if we add new render
copyfuncs.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-11-29 14:59:57 +01:00
Daniel Vetter
d79414f64a tests: disable gem_non_secure_batch
Seems to cause hangs on some of my old gen2/3 machines, but not all of
them.
2012-11-29 11:27:32 +01:00
Daniel Vetter
df11a6f31d tests/gem_tiled_partial_pwrite_pread: convert to subtest infrastructure 2012-11-28 13:25:12 +01:00
Daniel Vetter
b0066d3659 tests/gem_tiled_partial_pwrite_pread: refactor subtests into functions 2012-11-28 13:22:39 +01:00
Daniel Vetter
129d201337 tests/gem_set_tiling_vs_blt: convert to subtest infrastructure 2012-11-28 13:10:26 +01:00
Daniel Vetter
ca2851f827 tests/gem_ringfill: convert to subtest infrastructure 2012-11-28 13:08:20 +01:00
Daniel Vetter
046b149b18 tests/gem_partial_pwrite_pread: convert to subtest infrastructure 2012-11-28 13:08:07 +01:00
Daniel Vetter
1a55ca753e tests/gem_partial_pwrite_pread: refactor subtests into functions
This was a too big mess.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-11-28 12:47:26 +01:00
Daniel Vetter
af228d4edc tests/gem_mmap_gtt: convert to subtest infrastructure 2012-11-28 12:40:23 +01:00