diff options
author | Zhi Wang <zhi.a.wang@intel.com> | 2016-09-02 07:41:29 +0300 |
---|---|---|
committer | Zhenyu Wang <zhenyuw@linux.intel.com> | 2016-10-14 13:11:19 +0300 |
commit | 28a60dee2ce6021fa6b304bc6761b71120635ad8 (patch) | |
tree | e35be207ed7b496322662833269a4f438f3db1be /drivers/gpu/drm/i915/gvt/gvt.c | |
parent | 86e83e35d190a9b553384e0e711091a4e9643998 (diff) | |
download | linux-28a60dee2ce6021fa6b304bc6761b71120635ad8.tar.xz |
drm/i915/gvt: vGPU HW resource management
This patch introduces the GVT-g vGPU HW resource management. Under
GVT-g virtualizaion environment, each vGPU requires portions HW
resources, including aperture, hidden GM space, and fence registers.
When creating a vGPU, GVT-g will request these HW resources from host,
and return them to host after a vGPU is destroyed.
Signed-off-by: Zhi Wang <zhi.a.wang@intel.com>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/gvt/gvt.c')
-rw-r--r-- | drivers/gpu/drm/i915/gvt/gvt.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/gvt/gvt.c b/drivers/gpu/drm/i915/gvt/gvt.c index 927f4579f5b6..6ec5b937af63 100644 --- a/drivers/gpu/drm/i915/gvt/gvt.c +++ b/drivers/gpu/drm/i915/gvt/gvt.c @@ -84,7 +84,7 @@ int intel_gvt_init_host(void) static void init_device_info(struct intel_gvt *gvt) { - if (IS_BROADWELL(gvt->dev_priv)) + if (IS_BROADWELL(gvt->dev_priv) || IS_SKYLAKE(gvt->dev_priv)) gvt->device_info.max_support_vgpus = 8; /* This function will grow large in GVT device model patches. */ } @@ -135,6 +135,9 @@ int intel_gvt_init_device(struct drm_i915_private *dev_priv) gvt_dbg_core("init gvt device\n"); + mutex_init(&gvt->lock); + gvt->dev_priv = dev_priv; + init_device_info(gvt); /* * Other initialization of GVT components will be introduce here. |