diff options
author | Antonio Argenziano <antonio.argenziano@intel.com> | 2018-07-10 16:45:26 -0700 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2018-07-13 19:29:38 +0100 |
commit | 140a67c13aad2595ee6c72e41d14d35a793158b5 (patch) | |
tree | 1b33508f86195317e338c91b7aa45f4cf51ad223 /lib/igt_gt.h | |
parent | caea9c5b3aa1191c0152d7c0f22a94efca4fd048 (diff) |
lib/gt: Make use of dummyload library to create recursive batch
An hanging batch is nothing more than a spinning batch that never gets
stopped, so re-use the routines implemented in dummyload.c.
v2: Let caller decide spin loop size
v3: Only use loose loops for hangs (Chris)
v4: No requires
v5: Free the spinner
v6: Chamelium exists.
Signed-off-by: Antonio Argenziano <antonio.argenziano@intel.com> #v3
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Antonio Argenziano <antonio.argenziano@intel.com>
Diffstat (limited to 'lib/igt_gt.h')
-rw-r--r-- | lib/igt_gt.h | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/lib/igt_gt.h b/lib/igt_gt.h index d44b7552..54e95da9 100644 --- a/lib/igt_gt.h +++ b/lib/igt_gt.h @@ -25,6 +25,7 @@ #define IGT_GT_H #include "igt_debugfs.h" +#include "igt_dummyload.h" #include "igt_core.h" #include "i915_drm.h" @@ -32,7 +33,7 @@ void igt_require_hang_ring(int fd, int ring); typedef struct igt_hang { - unsigned handle; + igt_spin_t *spin; unsigned ctx; unsigned ban; unsigned flags; @@ -43,11 +44,7 @@ void igt_disallow_hang(int fd, igt_hang_t arg); #define HANG_POISON 0xc5c5c5c5 -igt_hang_t igt_hang_ctx(int fd, - uint32_t ctx, - int ring, - unsigned flags, - uint64_t *offset); +igt_hang_t igt_hang_ctx(int fd, uint32_t ctx, int ring, unsigned flags); #define HANG_ALLOW_BAN 1 #define HANG_ALLOW_CAPTURE 2 |