785 Commits

Author SHA1 Message Date
Daniel Vetter
4acaf0004d tests/kms_flip: More leeway for dummy load tests
At least on my old atom i945 they take forever. Also, metric tons of
pipe B underruns while running rcs-flip-vs-panning. No idea why that
happens.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-20 20:37:21 +02:00
Daniel Vetter
45cd89ab3d tests/kms_flip: Unconfuse the framenumber step checking
We run flips and vblank waits in parallel, which means the step
for each is the maximum. If we'd switch to an interleaved scheme
(to be able to check the correlation) we'd need to add them instead.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-20 16:11:57 +02:00
Daniel Vetter
8e11f8778a tests/kms_flip: no absolute vblank wait on the first frame
We don't have a reference value for the vblank counter yet, so
will end up waiting for a long time for the vblank counter to
wrap around again.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-20 16:11:57 +02:00
Daniel Vetter
e313dee22b tets/kms_flip: disable correlation check
It's broken since it doesn't take the order the events arrived into
account and so will fall over for longer seq_step values in the vblank
event: Since the flip completes right away, but the vblank later on
they won't have the same timestamp.

For now just give up, we could resurrect this by strictly alternating
between a flip and a vblank wait.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-20 16:11:57 +02:00
Daniel Vetter
f698984bae tests/debugfs_pipe_crc: new subtest to check CRC frame numbers
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-20 16:11:57 +02:00
Damien Lespiau
09e9f0b216 rendercopy: Add a way to dump an .aub file with the rendercopy bos
v2 (by Ben): Remove libdrm dependency since intel-gpu-tools now requires
a higher version anyway. Remove associated #ifdef ENABLE_AUB_DUMP

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Ben Widawsky <benjamin.widawsky@intel.com>
2013-10-18 09:49:41 -07:00
Damien Lespiau
5e3047ce52 tests/debugfs_pipe_crc: Test the read CRCs are not null
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-10-18 12:27:21 +01:00
Daniel Vetter
43f5384c08 tests/debugfs_pipe_crc: test all connectors
Diff looks a bit ugly, but it's just due to the added indentation.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-17 14:18:35 +02:00
Daniel Vetter
070904bf59 tests/debugfs_pipe_crc: test all pipes
And skip them if there's no suitable connector.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-17 14:10:43 +02:00
Daniel Vetter
e6ad75c1c4 tests/debugfs_pipe_crc: fix fb leak
Also remove the unused connector_t->mode.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-17 14:09:52 +02:00
Daniel Vetter
173a4cf1da tests/debugfs_pipe_crc: fall back to PIPE source
With PLANE1 and PIPE CRC sources the test will work on all currently
shipping (and planed fwiw) platforms.

Also add all the other new sources for non-ivb/hsw chips.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-17 13:35:51 +02:00
Daniel Vetter
1cefd198da tests/ZZ_missed_irq: Fixup SOURCE_PATH handling
Copy the trick from ZZ_hangman of just cd'ing into the old working
directory in a subshell.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=70561
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-17 10:49:45 +02:00
Ben Widawsky
a12d4a7135 gem_ctx_bad_exec: skip vebox when appropriate
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-16 22:01:34 -07:00
Daniel Vetter
0412f32670 tests/debugfs_pipe_crc: correctly skip on unsupported platforms
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-16 14:12:49 +02:00
Damien Lespiau
4ba97ddf96 debugfs_pipe_crc: Let's check CRCs!
Let's add a new test that sets a mode, wait for a few vblanks (3) and
then make sure we read 3 identical CRCs.

Some subtests check for various parsing errors.

In the process, improve the debugfs helpers to deal with CRCs.

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-10-15 19:40:07 +01:00
Daniel Vetter
d3d371fdf6 tests/pc8: Readd verbose error message
I deemed them a bit redundant (assuming that developers are the only
ones that look at them anyway). But Paulo requested that I readd them
for the education of QA.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-14 19:10:56 +02:00
Daniel Vetter
a5d40a9bf2 tests/kms_flip: fix igt_assert
I've blown the conversion in

commit 37e5b318c5dac290611099e2eec21df1e49fa71f
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Fri Oct 4 18:42:26 2013 +0200

    tests/kms_flip: use igt_assert more

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=70332
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-11 20:55:27 +02:00
Daniel Vetter
98a2b5b01f tests/kms_flip: Skip if the kernel doesn't let y-tiled bo slip through
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-11 20:55:27 +02:00
Daniel Vetter
9f3794f5fd tests/kms_flip: exit handler needs a fixture
Since it can fail.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=70332
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-11 20:55:27 +02:00
Thomas Wood
ce5becbb61 testdisplay: Allow getopt to print error messages
By not assigning opterr, getopt will print its own error message that
includes information about whether an option is unknown or just requires
an additional argument.

Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2013-10-11 13:16:07 +01:00
Daniel Vetter
ffdece38e2 tests/gem_suspend: test debugfs/sysfs reads while s/r
Just a very quick hack cobbled together with /bin/sh and exec. We
can't use system since that does stupid things with singals ... Still
we need to whack the child process pretty hard to get rid of it.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-10 14:20:43 +02:00
Daniel Vetter
8a9b275b96 tests/module_reload: fail if the module didn't unload
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=70336
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-10 11:22:09 +02:00
Ben Widawsky
f014878722 gem_pin: Use iterator for blit batch setup
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-09 12:52:09 -07:00
Ben Widawsky
a7934e26ae gem_exec_blt: Use iterator for blit batch setup
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-09 12:52:09 -07:00
Ben Widawsky
637162d0f7 gem_evict_*: Use iterator for blit batch
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-09 12:52:09 -07:00
Ben Widawsky
aa6fbd18d4 gem_linear_blits: Use iterator for blit batch setup
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-09 12:52:09 -07:00
Ben Widawsky
4de3b1765e gem_exec_faulting_reloc: use iterator for batchbuffer
This will help keep the code clean for new platforms which might have
differently sized relocations.

Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-09 12:51:21 -07:00
Daniel Vetter
6f8c30d8ed tests: add kms_addfb
Just a bunch of testcase to check that all the addfb sanity checks
work as they should.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-09 21:20:40 +02:00
Daniel Vetter
590f610140 lib/drmtest: extract rawer __gem_set_tiling
For tests that expect failures. Also apply the existing gem_set_tiling
helper a bit wider.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-09 20:50:50 +02:00
Ben Widawsky
40599b0779 pwrite_pread: Get devid only once
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-08 20:47:28 -07:00
Ben Widawsky
a2925b0989 pwrite_pread: Extract batch building
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-08 20:47:26 -07:00
Ben Widawsky
41ae28e498 pwrite_pread: use execbuf.batch_len for size
This will make an upcoming change easier.

Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-08 20:33:41 -07:00
Ben Widawsky
96f665cabb gem_tiled_blits: Squash bo leak on simulation
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-08 20:32:12 -07:00
Ben Widawsky
f75dec0b41 gem_tiled_blits: Squash memory leak on simulation
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-10-08 18:36:32 -07:00
Daniel Vetter
304c458d54 tests/kms_flip: Skip if no clone configuration could be found
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-07 22:55:14 +02:00
Daniel Vetter
ae599546fa tests/pc8: Fail harder
If the test enviroment isn't properly set up we should fail the
testcase, since otherwise there's no way to make sure a feature
actually works.

To cut down on bug triaging time extract the basic test (which was
previously used to skip all subtests) into a "basic" subtest.

Also fail the test hard if the msr interface isn't available. And
switch all other check in setup_enviroment to igt_require.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=69838
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-04 19:59:03 +02:00
Daniel Vetter
3dc91f3242 tests/pc8+: Only skip i2c subtest if i2c /dev interface is unavailable
Through the magic of igt_skip we only need to fail this subtest, not
the entire thing.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-04 19:58:11 +02:00
Daniel Vetter
37e5b318c5 tests/kms_flip: use igt_assert more
I've left the time delta checks as-is since those are tricky math and
my mind is feeble.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-04 18:42:26 +02:00
Daniel Vetter
54b5f7251a tests/kms_flip: check flip count in both directions
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-04 18:12:39 +02:00
Chris Wilson
b53f22cee7 tests: Simulate missed breadcrumb irqs
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-10-04 09:54:21 +01:00
Daniel Vetter
16b61932bb tests/kms_flip: use igt_assert in the dpms helpers
No need to route the error code around really.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-03 22:45:53 +02:00
Daniel Vetter
0b19cb5dc2 tests/kms_flip: Check the dpms confusion
Some kernels inadvertedly forwarded dpms changes to crtcs connected to
shared encoders even though that specific output wasn't enabled.
Hilarity ensued.

Note that we only have shared encoders on hsw (DP+HDMI) and with sdvo
cards (multi-function encoders).

v2: Do a full OFF->ON->OFF transition to make sure something actually
happens.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-10-03 22:31:11 +02:00
Daniel Vetter
1f0addb689 tests/kms_flip: scale test runtime
On machines with many outputs and many crtcs it takes too long.
So scale the runtime by the number of output combinations we're trying
to light up.

Compensate the test runtime a bit by doubling most subtests' duration.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-09-30 22:55:12 +02:00
Daniel Vetter
3f89d5403e tests/kms_flip: fail harder
At least for pipe A/B we should always fail the test if we can't light
up the preferred mode - the kernel should filter out impossible modes
and for our hw pipe A/B are the least constrained.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-09-30 22:55:12 +02:00
Damien Lespiau
6de613f8e5 testdisplay: Print the stereo mode being tested
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-09-30 18:04:22 +01:00
Damien Lespiau
e836b60d37 testdisplay: Make -o and -3 work together
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-09-30 18:04:22 +01:00
Damien Lespiau
8393bb41a1 testdisplay: Remove mode resetting now that we don't adjust the timings
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-09-30 18:04:22 +01:00
Damien Lespiau
c128b731dc testdisplay: Respect specified_disp_id in the stereo loop
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-09-30 18:04:22 +01:00
Damien Lespiau
28cf66de94 testdisplay: Remove printing out the eyes geometry
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-09-30 18:04:22 +01:00
Damien Lespiau
a7d1937cd7 testdisplay: Use DRM_MODE_FLAG_3D_MASK
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-09-30 18:04:22 +01:00