Skip to content

Commit

Permalink
drm/i915/selftests: Check for an already completed timeslice
Browse files Browse the repository at this point in the history
With timeslice yielding on a semaphore, we may complete timeslices much
faster than we were expecting and already have yielded the stuck
request. Before complaining that timeslicing is not enabled, check that
we haven't already applied the switch.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Andi Shyti <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
  • Loading branch information
ickle committed Apr 10, 2020
1 parent 538c329 commit c1b5ea9
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/gpu/drm/i915/gt/selftest_lrc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1252,6 +1252,7 @@ static int live_timeslice_queue(void *arg)
} while (READ_ONCE(engine->execlists.pending[0]));

if (!READ_ONCE(engine->execlists.timer.expires) &&
execlists_active(&engine->execlists) == rq &&
!i915_request_completed(rq)) {
struct drm_printer p =
drm_info_printer(gt->i915->drm.dev);
Expand Down

0 comments on commit c1b5ea9

Please sign in to comment.