diff options
author | fred gao <fred.gao@intel.com> | 2017-09-19 15:11:28 +0800 |
---|---|---|
committer | Zhenyu Wang <zhenyuw@linux.intel.com> | 2017-11-16 11:46:51 +0800 |
commit | e011c6ce2b4fc7c577ade41485d74431a4e6ea1a (patch) | |
tree | faa451deb09b28c1d086f6c44563532f43cc3b4c /drivers/gpu/drm/i915/gvt/scheduler.c | |
parent | 5c56883a9531cd89561fb9a11a33697f2847c82a (diff) | |
download | lwn-e011c6ce2b4fc7c577ade41485d74431a4e6ea1a.tar.gz lwn-e011c6ce2b4fc7c577ade41485d74431a4e6ea1a.zip |
drm/i915/gvt: Add VM healthy check for workload_thread
When a scan error occurs in dispatch_workload, this patch is to
check the healthy state and free all the queued workloads before
the failsafe mode is entered.
Signed-off-by: fred gao <fred.gao@intel.com>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/gvt/scheduler.c')
-rw-r--r-- | drivers/gpu/drm/i915/gvt/scheduler.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/gvt/scheduler.c b/drivers/gpu/drm/i915/gvt/scheduler.c index 0771b715f825..02af14023383 100644 --- a/drivers/gpu/drm/i915/gvt/scheduler.c +++ b/drivers/gpu/drm/i915/gvt/scheduler.c @@ -634,6 +634,13 @@ complete: FORCEWAKE_ALL); intel_runtime_pm_put(gvt->dev_priv); + if (ret && (vgpu_is_vm_unhealthy(ret))) { + mutex_lock(&gvt->lock); + intel_vgpu_clean_execlist(vgpu); + mutex_unlock(&gvt->lock); + enter_failsafe_mode(vgpu, GVT_FAILSAFE_GUEST_ERR); + } + } return 0; } |