diff options
author | Andrzej Hajda <andrzej.hajda@intel.com> | 2023-12-05 14:09:37 +0100 |
---|---|---|
committer | Andrzej Hajda <andrzej.hajda@intel.com> | 2023-12-08 12:19:26 +0100 |
commit | 34880b18733efff60b68d074ff74d018ffc309a7 (patch) | |
tree | a51a06f51e612bbccce98ec31f1925b0521f32ea | |
parent | cf9cb028ac56696ff879af1154c4b2f0b12701fd (diff) |
drm/i915/selftests: wait for active idle event in i915_active_unlock_wait
After i915_active_unlock_wait i915_active can be still non-idle due
to barrier async handling in signal_irq_work. As a result one can observe
following errors:
bcs0: heartbeat pulse did not flush idle tasks
*ERROR* pulse active pulse_active [i915]:pulse_retire [i915]
*ERROR* pulse count: 0
*ERROR* pulse preallocated barriers? no
To prevent it let's wait explicitly for idleness.
v2: wait only in live_idle tests
Signed-off-by: Andrzej Hajda <andrzej.hajda@intel.com>
Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20231205-selftest_wait_for_active_idle_event-v2-1-1437d0bf9829@intel.com
-rw-r--r-- | drivers/gpu/drm/i915/gt/selftest_engine_heartbeat.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/gt/selftest_engine_heartbeat.c b/drivers/gpu/drm/i915/gt/selftest_engine_heartbeat.c index 273d440a53e3..bc441ce7b380 100644 --- a/drivers/gpu/drm/i915/gt/selftest_engine_heartbeat.c +++ b/drivers/gpu/drm/i915/gt/selftest_engine_heartbeat.c @@ -84,7 +84,7 @@ static struct pulse *pulse_create(void) static void pulse_unlock_wait(struct pulse *p) { - i915_active_unlock_wait(&p->active); + wait_var_event_timeout(&p->active, i915_active_is_idle(&p->active), HZ); } static int __live_idle_pulse(struct intel_engine_cs *engine, |