diff options
author | Jani Nikula <jani.nikula@intel.com> | 2017-04-03 18:14:06 +0300 |
---|---|---|
committer | Jani Nikula <jani.nikula@intel.com> | 2017-04-03 18:18:34 +0300 |
commit | cf082a4a264d5e0bb79f0055be02d255438836a4 (patch) | |
tree | e1b4b204f53804d2be63c2c481ee0cfc239fd074 /drivers/gpu/drm/i915/gvt/kvmgt.c | |
parent | ecf8e89917d600fe846ebda911a9e690c6babfd0 (diff) | |
parent | aa4ce4493c88dc324911152d1ccd25469366dba3 (diff) | |
download | linux-cf082a4a264d5e0bb79f0055be02d255438836a4.tar.xz |
Merge tag 'gvt-fixes-2017-04-01' of https://github.com/01org/gvt-linux into drm-intel-fixes
gvt-fixes-2017-04-01
- Fix cfg space in failsafe (Changbin)
- Fix a race for irq inject with vgpu release (Zhi)
- Fix golden state firmware load (Zhi)
Link: http://patchwork.freedesktop.org/patch/msgid/20170401080650.6cvqon7nsbziwnyc@zhen-hp.sh.intel.com
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/gvt/kvmgt.c')
-rw-r--r-- | drivers/gpu/drm/i915/gvt/kvmgt.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/gvt/kvmgt.c b/drivers/gpu/drm/i915/gvt/kvmgt.c index 2d92119b488c..e466259034e2 100644 --- a/drivers/gpu/drm/i915/gvt/kvmgt.c +++ b/drivers/gpu/drm/i915/gvt/kvmgt.c @@ -544,6 +544,8 @@ static int intel_vgpu_open(struct mdev_device *mdev) if (ret) goto undo_group; + intel_gvt_ops->vgpu_activate(vgpu); + atomic_set(&vgpu->vdev.released, 0); return ret; @@ -569,6 +571,8 @@ static void __intel_vgpu_release(struct intel_vgpu *vgpu) if (atomic_cmpxchg(&vgpu->vdev.released, 0, 1)) return; + intel_gvt_ops->vgpu_deactivate(vgpu); + ret = vfio_unregister_notifier(mdev_dev(vgpu->vdev.mdev), VFIO_IOMMU_NOTIFY, &vgpu->vdev.iommu_notifier); WARN(ret, "vfio_unregister_notifier for iommu failed: %d\n", ret); |