drm/i915: Mark up vGPU support for full-ppgtt
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 14 Mar 2019 22:38:35 +0000 (22:38 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 15 Mar 2019 09:04:54 +0000 (09:04 +0000)
For compatibility reasons, we only care if the vGPU host provides
support for full-ppgtt. This is independent of the addressable memory
size, so remove the conflation of 48b from the capability name.

Based on a patch by Bob Paauwe.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Bob Paauwe <bob.j.paauwe@intel.com>
Cc: Zhenyu Wang <zhenyuw@linux.intel.com>
Cc: Zhi Wang <zhi.a.wang@intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Reviewed-by: Zhenyu Wang <zhenyuw@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190314223839.28258-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gvt/vgpu.c
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/i915_pvinfo.h
drivers/gpu/drm/i915/i915_vgpu.c
drivers/gpu/drm/i915/i915_vgpu.h

index 720e2b10adaa10f8ccc4c7472da4e300eb4b296f..314e40121e47e0d770fc0a6039bd8bcf4947baae 100644 (file)
@@ -44,7 +44,7 @@ void populate_pvinfo_page(struct intel_vgpu *vgpu)
        vgpu_vreg_t(vgpu, vgtif_reg(display_ready)) = 0;
        vgpu_vreg_t(vgpu, vgtif_reg(vgt_id)) = vgpu->id;
 
-       vgpu_vreg_t(vgpu, vgtif_reg(vgt_caps)) = VGT_CAPS_FULL_48BIT_PPGTT;
+       vgpu_vreg_t(vgpu, vgtif_reg(vgt_caps)) = VGT_CAPS_FULL_PPGTT;
        vgpu_vreg_t(vgpu, vgtif_reg(vgt_caps)) |= VGT_CAPS_HWSP_EMULATION;
        vgpu_vreg_t(vgpu, vgtif_reg(vgt_caps)) |= VGT_CAPS_HUGE_GTT;
 
index a74fdec7137c68b0c2fc184552722a24660f4f9e..df2a939eab5e2853f2293ade0a899699486c8470 100644 (file)
@@ -1527,7 +1527,7 @@ static int i915_driver_init_hw(struct drm_i915_private *dev_priv)
 
        if (HAS_PPGTT(dev_priv)) {
                if (intel_vgpu_active(dev_priv) &&
-                   !intel_vgpu_has_full_48bit_ppgtt(dev_priv)) {
+                   !intel_vgpu_has_full_ppgtt(dev_priv)) {
                        i915_report_error(dev_priv,
                                          "incompatible vGPU found, support for isolated ppGTT required\n");
                        return -ENXIO;
index eeaa3d506d95dc357ec5f317252c7d4bd11a3ed7..969e514916abec2b5a272e459550e6cd120a0558 100644 (file)
@@ -52,7 +52,7 @@ enum vgt_g2v_type {
 /*
  * VGT capabilities type
  */
-#define VGT_CAPS_FULL_48BIT_PPGTT      BIT(2)
+#define VGT_CAPS_FULL_PPGTT            BIT(2)
 #define VGT_CAPS_HWSP_EMULATION                BIT(3)
 #define VGT_CAPS_HUGE_GTT              BIT(4)
 
index 869cf4a3b6de75fee593c0f66c953cc1035434a6..3b2d83f704e30778aff104df58eee026f8b7364a 100644 (file)
@@ -81,9 +81,9 @@ void i915_check_vgpu(struct drm_i915_private *dev_priv)
        DRM_INFO("Virtual GPU for Intel GVT-g detected.\n");
 }
 
-bool intel_vgpu_has_full_48bit_ppgtt(struct drm_i915_private *dev_priv)
+bool intel_vgpu_has_full_ppgtt(struct drm_i915_private *dev_priv)
 {
-       return dev_priv->vgpu.caps & VGT_CAPS_FULL_48BIT_PPGTT;
+       return dev_priv->vgpu.caps & VGT_CAPS_FULL_PPGTT;
 }
 
 struct _balloon_info_ {
index 551acc3900464bb7d4aee586ba7792155631bef5..ebe1b7bced980707040b74eee88e2c9693f8f38f 100644 (file)
@@ -28,7 +28,7 @@
 
 void i915_check_vgpu(struct drm_i915_private *dev_priv);
 
-bool intel_vgpu_has_full_48bit_ppgtt(struct drm_i915_private *dev_priv);
+bool intel_vgpu_has_full_ppgtt(struct drm_i915_private *dev_priv);
 
 static inline bool
 intel_vgpu_has_hwsp_emulation(struct drm_i915_private *dev_priv)