17 Commits

Author SHA1 Message Date
Ville Syrjälä
7ef537231a tests/gem_ctx_exec: Add reset-pin-leak subtest
Add a subtest to make sure the kernel doesn't leak the vma
pin_count for the last context on reset.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2014-06-23 12:57:11 +03:00
Daniel Vetter
e624fa8a2e tests: sprinkle igt logging
All the cases that simply dump some debug information and couldn't be
converted to some of the fancier macros.

Some information output removed when it's redundant with the subtest
status.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-05-14 00:36:04 +02:00
Daniel Vetter
f5daeec724 lib: extract igt_aux.[hc]
And shovel all the various helpers in there.

Also move igt_set_vt_graphics_mode to igt_kms.h since the function is
implemented in igt_kms.c. And it fits better. I kinda missed this in
the prep work.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-23 13:47:09 +01:00
Daniel Vetter
e49ceb8690 lib: unnecessary header removal for drmtest.h, part 1
Brought a few missing headers to light in ioctl_wrappers.h, too.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22 21:07:37 +01:00
Daniel Vetter
7775fca2df tests/gem_ctx_exec: fix ram requirement fumble
We need to half available ram, not double it ...

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=72557
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-01-08 20:25:26 +01:00
Daniel Vetter
40b586188c tests/gem_ctx_exec: Add eviction test
It didn't pan out at all since atm we don't evict context objects. But
maybe it's useful for when that happens.

v2: Actually test eviction. Took a while to figure that one out.

And indeed the testcase now fails because we don't evict the previous
context as we should.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-12-05 15:50:43 +01:00
Damien Lespiau
020600b77d tests: Convert the ctx test to use render nodes when possible
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-10-28 11:00:07 +00:00
Daniel Vetter
225a91bc54 lib/drmtest: include sys/mman.h from drmtest.h
We need it for mmapping to get at PROT_READ|WRITE anyway.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-09-03 10:38:29 +02:00
Daniel Vetter
9ad062d0b3 lib/drmtest: extract gem_create_context
libdrm requirements are now up to it.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-08-19 10:55:28 +02:00
Daniel Vetter
b30d95f33c tests: s/exit(77)/igt_skip()/
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-08-13 15:07:44 +02:00
Daniel Vetter
c9d0378281 tests: s/exit(EXIT_SUCCESS)/igt_success()/
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-08-13 15:07:44 +02:00
Daniel Vetter
83440953e5 tests: s/assert/igt_assert
Just a wholesale rollout for now, we can refine later on.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-08-13 15:07:44 +02:00
Daniel Vetter
1caaf0a6b6 s/drmtest_/igt_/
Requested-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-08-12 12:20:22 +02:00
Daniel Vetter
7847ea2965 tests: use drmtest_skip to check for rings
To simplify things add a set of gem_check_<ring> functions which take
care of this. Since I've opted for static inlines drmtest.h grew a few
more header includes which was a neat opportunity to dump a few redundant
#defines.

This kills all the skipped_all hand-rolled logic we have.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-08-12 11:17:58 +02:00
Damien Lespiau
5fa15f79d0 tests: Black list tests we don't want to run on simulation
Let's start by a small set of tests, to eventually consider running
more.

The current list should then be:

gem_mmap
gem_pread_after_blit
gem_ring_sync_loop
gem_ctx_basic
gem_pipe_control_store_loop
gem_storedw_loop_render
gem_storedw_loop_blt
gem_storedw_loop_bsd
gem_render_linear_blits
gem_tiled_blits
gem_cpu_reloc

gem_exec_nop
gem_mmap_gtt

v2 add (Daniel Vetter)
gem_exec_bad_domains
gem_exec_faulting_reloc
gem_flink
gem_reg_read
gem_reloc_overflow
gem_tiling_max_stride
prime_*

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-07-18 15:49:02 +01:00
Mika Kuoppala
b8e5965e8f tests/gem_ctx_exec: properly test destroy_ctx ioctl
Call context destroy with proper ioctl number and
add test to verify that we can't post batchbuffers
with destroyed context.

Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-02-05 12:02:37 +01:00
Ben Widawsky
f7e356d9cd context tests not requiring libdrm
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2012-06-18 12:06:45 -07:00