1. 24 Jul, 2014 2 commits
    • Chris Wilson's avatar
      igt_core: Refactor igt_stop_helper() to use igt_wait_helper() · 74594554
      Chris Wilson authored
      Reduce code duplication as the igt_stop_helper can reuse
      igt_wait_helper() to replace its own waiting routine.
      Signed-off-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
    • Chris Wilson's avatar
      core: Only use signalsafe functions inside signal handlers · bd3cf81e
      Chris Wilson authored
      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's avatarTvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
      Signed-off-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
  2. 23 Jul, 2014 7 commits
  3. 21 Jul, 2014 1 commit
    • Chris Wilson's avatar
      Use SIGTERM in replace of SIGQUIT · 4f7d4dca
      Chris Wilson authored
      SIGTERM is the normal signal to use when instructing a process to exit.
      The only difference is that an unhandled SIGQUIT is meant to generate a
      coredump, which is not what we want, but in practice I encountered an
      issue where SIGTERM seemed to be deliverable more reliably than SIGQUIT
      (in tests using multiple signal helpers).
      Signed-off-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
  4. 17 Jul, 2014 1 commit
  5. 14 Jul, 2014 1 commit
    • Daniel Vetter's avatar
      lib: Add argc/argv to igt_simple_init · 5a98fe9d
      Daniel Vetter authored
      There's a pile of ideas around to add generally useful options like
      --debug to all igt tests. Or unify the runtime behaviour between
      simple and subtest tests a bit more.
      The first step to get there is to add argc/argv to igt_simple_init so
      that we can get at the argument list.
      Cc: Tim Gore <tim.gore@intel.com>
      Cc: Thomas Wood <thomas.wood@intel.com>
      Signed-off-by: Daniel Vetter's avatarDaniel Vetter <daniel.vetter@ffwll.ch>
  6. 11 Jul, 2014 2 commits
  7. 10 Jul, 2014 3 commits
  8. 12 Jun, 2014 1 commit
  9. 09 Jun, 2014 1 commit
  10. 14 May, 2014 3 commits
  11. 13 May, 2014 2 commits
  12. 26 Mar, 2014 1 commit
  13. 23 Mar, 2014 3 commits
  14. 22 Mar, 2014 5 commits
  15. 17 Mar, 2014 2 commits
  16. 14 Mar, 2014 1 commit
  17. 13 Mar, 2014 1 commit
    • Daniel Vetter's avatar
      lib: add igt_vlog to print varargs · bd53d722
      Daniel Vetter authored
      ... and put it to immediate use in igt_display_log.
      To make this all add up also drop the return value of igt_display_log,
      no one really cared anyway.
      Aside: I've noticed that every time another subtest runs (at least
      with kms_pipe_crc_basic) the log indent level moves one up ...
      Signed-off-by: Daniel Vetter's avatarDaniel Vetter <daniel.vetter@ffwll.ch>
  18. 12 Mar, 2014 3 commits
    • Daniel Vetter's avatar
      lib/igt_core: api documentation · 55e64989
      Daniel Vetter authored
      At most a bit of comment of function declaration movement for more
      polish. One tricky bit is to #ifdef out (only for gtkdoc of course)
      the struct option; forward declaration - gtkdoc needlessly lists it.
      FIXME: The struct documentation for igt_helper_process somehow doesn't
      get picked up ... Same issue seems to be with the igt_log_level enum,
      I've shoveled the relevant documentation into igt_log in free-form for
      Signed-off-by: Daniel Vetter's avatarDaniel Vetter <daniel.vetter@ffwll.ch>
    • Daniel Vetter's avatar
      lib: extract igt_core.c · d63fe151
      Daniel Vetter authored
      Same game as with ioctl_wrappers.c.
      To split was rather clean except for the static function
      oom_adjust_for_doom. But that was a bug, the calls to it in the
      various open helpers should simply be done at init and fork time.
      Which was already the case, except for simple testcase.  So fix it up.
      While at it also start with a small section header for the
      v2: Don't forget to update the xml template ...
      Signed-off-by: Daniel Vetter's avatarDaniel Vetter <daniel.vetter@ffwll.ch>
    • Daniel Vetter's avatar
      lib/ioctl_wrappers: api doc · 556c49f2
      Daniel Vetter authored
      Also some tiny polish to function interface:
      - @caching in gem_set_tiling should be uint32_t to match the ioctl
      - s/size/length/ for gem_write/read.
      - move gem_get_num_rings to the other ring feature helpers.
      v2: Also demote gem_require_ring from static inline and move it, too.
      v3: Also move gem_handle_to_libdrm_bo.
      Signed-off-by: Daniel Vetter's avatarDaniel Vetter <daniel.vetter@ffwll.ch>