summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-08-08tests/pm_rpm: add wait_for_suspended() calls to test_one_planePaulo Zanoni
Make sure we do all operations while really runtime suspended, so we can actually test things. Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-07tests/pm_rpm: add subtests for fencesPaulo Zanoni
Daniel thought fences were not surviving runtime PM on DPMS, so we wrote this test to check. The good news is that the test passed, so there's no need for a Kernel patch, at least on the Kernel I tested. Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-07igt_kms: add kmstest_unset_all_crtcs()Paulo Zanoni
Both pm_rpm.c and pm_lpsp.c call it "disable_all_screens", but let's give it a name that better describes what the implementation does. v2: Rename to kmstest_unset_all_crtcs (Daniel). Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-07tests/pm_rpm: use kmstest_get_property()Paulo Zanoni
So we can reduce the code size. v2: Rebase after the rename to kmstest_get_property. Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-07igt_kms: document and export kmstest_get_property()Paulo Zanoni
So we can use it on pm_rpm.c. v2: Rename to kmstest_get_property (Daniel) Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-07igt_kms: optionally return the property from get_propertyPaulo Zanoni
So we can use this function on places that also need the property pointer, without having to call drmModeGetProperty() again with the returned id. Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-07igt_kms: pass drm_fd instead of igt_display_t on some functionsPaulo Zanoni
Since these functions only really use the drm_fd. The goal is to be able to reuse these functions on programs that don't use the igt_display_t structure. Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-07igt_kms: don't get drmModeRes just to free it laterPaulo Zanoni
Stress testing malloc is not our goal :) Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-07tests/pm_rpm: add subtests for planes and cursorsPaulo Zanoni
These tests should trigger WARNs on Kernels that don't have the most recent fixes. v2: - Merge both the cursor and planes patches into one so it's easier to update them. - Extend the tests a little bit to exercise fences. - Fix bug found by Matt to enable the test to run on older Kernels Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2014-08-06lib/chv: CHV media pipeline command sequenceSean V Kelley
Enable gem_media_fill test for CHV platform. In addition to differences in media IP blocks from Broadwell, the command sequence also differs for programming the media pipeline, e.g., should not send a MEDIA_STATE_FLUSH right before the MI_BATCH_BUFFER_END of batch buffers using MEDIA_OBJECT. Uses explicit IS_BROADWELL / IS_CHERRYVIEW to distinguish in gen8 media fill handling. Signed-off-by: Sean V Kelley <sean.v.kelley@intel.com> Reviewed-by: Xiang, Haihao <haihao.xiang@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-08-01intel_bios_reader: Add support to dump MIPI Sequence block #53Gaurav K Singh
Signed-off-by: Gaurav K Singh <gaurav.k.singh@intel.com> Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-08-01intel_bios_reader: Add support to dump MIPI Configuration Block #52Gaurav K Singh
Signed-off-by: Gaurav K Singh <gaurav.k.singh@intel.com> Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-07-31testdisplay: ignore invalid subtest optionsThomas Wood
testdisplay does not have any subtests and should therefore exit with the appropriate exit code if the --list-subtests or --run-subtest options are used. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-30core: Add all kernel log levelsChris Wilson
And notice that INFO is 6 not 5. This is because I had intended to use KERN_NOTICE anyway... Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-30Update .gitignore filesThomas Wood
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-30lib: don't abort if forcing the connector state failsThomas Wood
Ensure tests using igt_enable_connectors can still run even if the relevant debugfs files are not available. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-30lib: check test options for conflictsThomas Wood
Check any test specific options for conflicts with the standard set of options. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-30lib: avoid getopt value conflicts with testsThomas Wood
Most tests use a printable character as the value for getopt to return, so avoid conflicts by using non-printing values for the standard options. v2: fix "-h" short option Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-30testdisplay: set a non-zero exit code if getopt detected an errorThomas Wood
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-29lib: Add ndebug to the headersBen Widawsky
If you don't do this, it is excluded from the tarball generated by make distcheck. 1.6 and 1.7 both are not buildable as a result. Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2014-07-29tests/gem_ringfill: add interruptible modeDaniel Vetter
Should be useful to test intel_ring_begin restart behaviour a bit. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-07-29testdisplay: Destroy the cairo context once the fb is paintedDamien Lespiau
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-07-29lib: Don't take a reference to the surface in get_cairo_surface()Damien Lespiau
We don't need to keep a reference to the surface, the cairo context will keep a reference to it until we destroy it. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-07-29lib: NULLify ->cairo_surface once unmappedDamien Lespiau
Just a matter of not leaving dangling pointers around. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-07-29lib: Split the GTT mapping out of get_cairo_surface()Damien Lespiau
This is preparation work for when we need a different way to get a linear buffer we can use with cairo. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-07-29lib: Remove unused field from struct igt_fbDamien Lespiau
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-07-27igt/pm_rps: Fix assertion in load_helper_stopChris Wilson
The load_helper isn't killed by the signal, but it exits gracefully. So update the assertion to check for the successful exit. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-25drmtest: First check that driver is i915Chris Wilson
Before issuing any i915 specific ioctls, check the driver is i915 otherwise we make other drivers emit nasty errors at the start of every test. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-25quick_dump: fix distcheckThomas Wood
version.h is now generated in the libs directory, so make sure it is correctly included in the compiler flags. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-25intel-gpu-tools: fix version.h creation in androidTim Gore
commit 743dc7997aa9f5210055896940d87c88983dcda6 breaks the build under Android because version.h is not created. This happens because the android make executes from the ANDROID_BUILD_TOP directory rather than from the directory containing the source files, so we need to differentiate between Android and linux builds. This is V2 of this patch based on Thomas Wood's suggestion. Signed-off-by: Tim Gore <tim.gore@intel.com> [Thomas: Fix distcheck issues] Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-25testdisplay: only set terminal attributes when in foreground process groupThomas Wood
The Piglit test runner for intel-gpu-tools creates a new process group for the test processes, so attempting to set terminal attributes causes the process to receive SIGTTOU and be stopped. Since the test is not run interactively in this case, the issue can be avoided by not setting terminal attributes if the process is not in the foreground process group. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-25core: Inject program name into dmesgChris Wilson
Write the program name if !list_only so that we associate oops with simple tests. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-25core: Improve phrasing for test requirementsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-25intel-gpu-tools: add sys/wait.h to pm_rps.cTim Gore
commit 745945546f7366a413a3a51a37f90caa3a227b1d breaks the build under Android because some of the macros used in pm_rps.c are defined in sys/wait.h which is not included. Signed-off-by: Tim Gore <tim.gore@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-07-25NEWS: Don't forget new universal plane commit for igt_kmsDaniel Vetter
Suggest by Matt Roper. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-07-24core: Inject subtest message into dmesgChris Wilson
One of the side-effects we test for are kernel oops and knowing the guilty subtest can help speed up debugging. We can write to /dev/kmsg to inject messages into dmesg, so let's do so before the start of every test. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-24igt_core: Read manpages more carefully for WNOHANGChris Wilson
/me hides I thought it said it would not return for a signal and stopped thinking. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-24igt_core: Refactor igt_stop_helper() to use igt_wait_helper()Chris Wilson
Reduce code duplication as the igt_stop_helper can reuse igt_wait_helper() to replace its own waiting routine. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-24core: Only use signalsafe functions inside signal handlersChris Wilson
The atexit() and signal() callbacks both need to only use signalsafe functions - that excludes the use of assert. So simplify fork_helper_exit_handler() and children_exit_handler(). __lll_lock_wait_private () at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S:95 0x00007fd630883d2b in _L_lock_13840 () from /lib/x86_64-linux-gnu/libc.so.6 0x00007fd630881df8 in __GI___libc_realloc (oldmem=0xfcb010, bytes=88) at malloc.c:3025 0x00007fd63087111b in _IO_vasprintf (result_ptr=0x7fff35dc4780, format=<optimised out>, args=args@entry=0x7fff35dc4658) at vasprintf.c:84 0x00007fd630852907 in ___asprintf (string_ptr=string_ptr@entry=0x7fff35dc4780, format=format@entry=0x7fd63097f718 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n") at asprintf.c:35 0x00007fd63082dd92 in __assert_fail_base (fmt=0x7fd63097f718 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x40cff5 "ret == 0", file=file@entry=0x4108d1 "igt_core.c", line=line@entry=872, function=function@entry=0x410ea0 <__PRETTY_FUNCTION__.8052> "children_exit_handler") at assert.c:57 0x00007fd63082dee2 in __GI___assert_fail (assertion=assertion@entry=0x40cff5 "ret == 0", file=file@entry=0x4108d1 "igt_core.c", line=line@entry=872, function=function@entry=0x410ea0 <__PRETTY_FUNCTION__.8052> "children_exit_handler") at assert.c:101 0x000000000040b03f in children_exit_handler (sig=<optimised out>) at igt_core.c:872 0x000000000040b089 in call_exit_handlers (sig=2) at igt_core.c:1029 fatal_sig_handler (sig=2) at igt_core.c:1053 <signal handler called> 0x00007fd6308bfe63 in __libc_fork () at ../nptl/sysdeps/unix/sysv/linux/x86_64/../fork.c:130 0x00007fd630bd6045 in __fork () at ../nptl/sysdeps/unix/sysv/linux/pt-fork.c:25 0x000000000040c51a in __igt_fork () at igt_core.c:900 0x00000000004036c2 in forking_evictions (ops=0x614360 <fault_ops>, surface_size=1048576, flags=5, trash_surfaces=<optimised out>, working_surfaces=338, fd=4) at eviction_common.c:203 test_forking_evictions (size=1048576, flags=5, count=338, fd=4) at gem_userptr_blits.c:1086 main (argc=1, argv=0x7fff35dc5328) at gem_userptr_blits.c:1478 Reported-by: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-24igt/gem_userptr_blits: Fix multi-threaded mm stress testerTvrtko Ursulin
Two parts to the fix: 1. Do not use pthread_cancel since not available on Android. 2. Do not assert in the thread since that does not get propagated to the process. Rather pass out any failures so we know test did not work as expected. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Tim Gore <tim.gore@intel.com> Reviewed-by: Tim Gore <tim.gore@intel.com>
2014-07-24igt/gem_userptr_blits: Fix forked access testTvrtko Ursulin
copy() blit helper assumes a certain object size much larger than a page size. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-23NEWS: UpdatesDaniel Vetter
2014-07-23tests/pm_rpm: Convert to new optparsingDaniel Vetter
Thomas missed the add-hoc parameter parsing in here, which did break things for Paulo since the core now fails for unknown options. Convert them over to the new infrastructure, which has the nice upside that we can remove the comments and put them into the usage available with --help. Cc: Thomas Wood <thomas.wood@intel.com> Cc: Paulo Zanoni <paulo.r.zanoni@intel.com> Tested-by: Paulo Zanoni <paulo.r.zanoni@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-07-23lib/drm_lib.sh: Bare-bones long option parsingDaniel Vetter
Just enough to stay compatible with simple subtests. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-07-23tests: Move root check to lib/drm_lib.shDaniel Vetter
All tests want that anyway. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-07-23linux: placate drop_caches and pass it a '\n'Chris Wilson
Apparently it doesn't have much effect without the newline. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-07-23build: improve version.h generationThomas Wood
Move version.h generation into lib/Makefile.sources so that it can be shared between the Autotools and Android build systems. Also make sure the "updating version.h" message is only displayed when version.h actually changes and remove unnecessary includes of version.h. This also includes changes from Tvrtko Ursulin to prevent a build from within the git repository failing when git is not available. Signed-off-by: Thomas Wood <thomas.wood@intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
2014-07-23lib: add an exit code to use when invalid options are specifiedThomas Wood
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-23lib: add a command line option to enable debug output in testsThomas Wood
Add --debug as a common command line option for all tests to enable debug output. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-07-23lib: always warn about unknown optionsThomas Wood
All tests can now register extra options, so there should not be any unknown options. Signed-off-by: Thomas Wood <thomas.wood@intel.com>