diff mbox

[v1,3/4] drm/i915/gvt: provide full ppgtt capability for guest i915 driver

Message ID 1494469984-3486-4-git-send-email-tina.zhang@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Zhang, Tina May 11, 2017, 2:33 a.m. UTC
This patch is to provide full ppgtt capability for guest i915 driver.

Signed-off-by: Tina Zhang <tina.zhang@intel.com>
---
 drivers/gpu/drm/i915/gvt/vgpu.c    | 1 +
 drivers/gpu/drm/i915/i915_pvinfo.h | 4 ++++
 2 files changed, 5 insertions(+)

Comments

Joonas Lahtinen May 11, 2017, 9:19 a.m. UTC | #1
On to, 2017-05-11 at 10:33 +0800, Tina Zhang wrote:
> This patch is to provide full ppgtt capability for guest i915 driver.
> 
> Signed-off-by: Tina Zhang <tina.zhang@intel.com>

<SNIP>

> @@ -53,6 +53,10 @@ enum vgt_g2v_type {
>  	VGT_G2V_MAX,
>  };
>  
> +enum vgt_caps_type {
> +	VGT_CAPS_FULL_PPGTT = (1 << 2),
> +};

Please separate this change to the previous patch to keep it separate
from the gvt/ folder changes. Also use #define and BIT(2) notation.

Regards, Joonas
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/gvt/vgpu.c b/drivers/gpu/drm/i915/gvt/vgpu.c
index 6e3cbd8..23578c1 100644
--- a/drivers/gpu/drm/i915/gvt/vgpu.c
+++ b/drivers/gpu/drm/i915/gvt/vgpu.c
@@ -43,6 +43,7 @@  void populate_pvinfo_page(struct intel_vgpu *vgpu)
 	vgpu_vreg(vgpu, vgtif_reg(version_minor)) = 0;
 	vgpu_vreg(vgpu, vgtif_reg(display_ready)) = 0;
 	vgpu_vreg(vgpu, vgtif_reg(vgt_id)) = vgpu->id;
+	vgpu_vreg(vgpu, vgtif_reg(vgt_caps)) = VGT_CAPS_FULL_PPGTT;
 	vgpu_vreg(vgpu, vgtif_reg(avail_rs.mappable_gmadr.base)) =
 		vgpu_aperture_gmadr_base(vgpu);
 	vgpu_vreg(vgpu, vgtif_reg(avail_rs.mappable_gmadr.size)) =
diff --git a/drivers/gpu/drm/i915/i915_pvinfo.h b/drivers/gpu/drm/i915/i915_pvinfo.h
index a879478..bbe554c 100644
--- a/drivers/gpu/drm/i915/i915_pvinfo.h
+++ b/drivers/gpu/drm/i915/i915_pvinfo.h
@@ -53,6 +53,10 @@  enum vgt_g2v_type {
 	VGT_G2V_MAX,
 };
 
+enum vgt_caps_type {
+	VGT_CAPS_FULL_PPGTT = (1 << 2),
+};
+
 struct vgt_if {
 	u64 magic;		/* VGT_MAGIC */
 	uint16_t version_major;