]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/gvt: free VFIO region space in vgpu detach
authorHang Yuan <hang.yuan@linux.intel.com>
Mon, 14 Jan 2019 10:43:39 +0000 (18:43 +0800)
committerZhenyu Wang <zhenyuw@linux.intel.com>
Tue, 15 Jan 2019 10:28:15 +0000 (18:28 +0800)
commita4a5f7bc35c5e89a3ae42ff846f13ae84e7cbe6a
tree757eede560b44538dfda13a0b0078a8ea948fce3
parent26bc8082e35e746df737d58b9f77a99cb1e222e1
drm/i915/gvt: free VFIO region space in vgpu detach

VFIO region space is allocated when one region is registered for
one vgpu. So free the space when destroy the vgpu.

Also change the parameter of detach_vgpu callback to use vgpu directly.

Fixes: 3c6a8c146fa4508e5923d ("drm/i915/gvt: Add opregion support")
Reviewed-by: Zhenyu Wang <zhenyuw@linux.intel.com>
Signed-off-by: Hang Yuan <hang.yuan@linux.intel.com>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
drivers/gpu/drm/i915/gvt/hypercall.h
drivers/gpu/drm/i915/gvt/kvmgt.c
drivers/gpu/drm/i915/gvt/mpt.h