Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t] i915/gem_busy: Use a non-preemptible hanging batch
@ 2018-12-31  9:22 Chris Wilson
  2019-01-02 13:03 ` Mika Kuoppala
  0 siblings, 1 reply; 2+ messages in thread
From: Chris Wilson @ 2018-12-31  9:22 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev

Ensure that the hangcheck notices the hanging batch by using a
non-preemptible spin batch, as some future versions of hangcheck may
allow a preemptible GPU hog to survive.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 tests/i915/gem_busy.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/tests/i915/gem_busy.c b/tests/i915/gem_busy.c
index 76b44a5d4..eb3d3ef2b 100644
--- a/tests/i915/gem_busy.c
+++ b/tests/i915/gem_busy.c
@@ -427,7 +427,10 @@ static bool has_extended_busy_ioctl(int fd)
 
 static void basic(int fd, unsigned ring, unsigned flags)
 {
-	igt_spin_t *spin = igt_spin_batch_new(fd, .engine = ring);
+	igt_spin_t *spin =
+		igt_spin_batch_new(fd,
+				   .engine = ring,
+				   .flags = IGT_SPIN_NO_PREEMPTION);
 	struct timespec tv;
 	int timeout;
 	bool busy;
-- 
2.20.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH i-g-t] i915/gem_busy: Use a non-preemptible hanging batch
  2018-12-31  9:22 [PATCH i-g-t] i915/gem_busy: Use a non-preemptible hanging batch Chris Wilson
@ 2019-01-02 13:03 ` Mika Kuoppala
  0 siblings, 0 replies; 2+ messages in thread
From: Mika Kuoppala @ 2019-01-02 13:03 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx; +Cc: igt-dev

Chris Wilson <chris@chris-wilson.co.uk> writes:

> Ensure that the hangcheck notices the hanging batch by using a
> non-preemptible spin batch, as some future versions of hangcheck may
> allow a preemptible GPU hog to survive.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>

> ---
>  tests/i915/gem_busy.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/tests/i915/gem_busy.c b/tests/i915/gem_busy.c
> index 76b44a5d4..eb3d3ef2b 100644
> --- a/tests/i915/gem_busy.c
> +++ b/tests/i915/gem_busy.c
> @@ -427,7 +427,10 @@ static bool has_extended_busy_ioctl(int fd)
>  
>  static void basic(int fd, unsigned ring, unsigned flags)
>  {
> -	igt_spin_t *spin = igt_spin_batch_new(fd, .engine = ring);
> +	igt_spin_t *spin =
> +		igt_spin_batch_new(fd,
> +				   .engine = ring,
> +				   .flags = IGT_SPIN_NO_PREEMPTION);
>  	struct timespec tv;
>  	int timeout;
>  	bool busy;
> -- 
> 2.20.1
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-01-02 13:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-12-31  9:22 [PATCH i-g-t] i915/gem_busy: Use a non-preemptible hanging batch Chris Wilson
2019-01-02 13:03 ` Mika Kuoppala

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox