summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/gvt/reg.h
diff options
context:
space:
mode:
authorZhi Wang <zhi.a.wang@intel.com>2016-05-01 11:22:47 +0200
committerZhenyu Wang <zhenyuw@linux.intel.com>2016-10-14 12:14:37 +0200
commit28c4c6ca7f794b2d5ac8773d43311e95f6518415 (patch)
treed543a88a6f32b5c29181d62017f064f4cc2c50c7 /drivers/gpu/drm/i915/gvt/reg.h
parentdrm/i915/gvt: vGPU execlist virtualization (diff)
downloadlinux-28c4c6ca7f794b2d5ac8773d43311e95f6518415.tar.xz
linux-28c4c6ca7f794b2d5ac8773d43311e95f6518415.zip
drm/i915/gvt: vGPU workload submission
This patch introduces the vGPU workload submission logics. Under virtualization environment, guest will submit workload through virtual execlist submit port. The submitted workload load will be wrapped into an gvt workload which will be picked by GVT workload scheduler and executed on host i915 later. 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/reg.h')
-rw-r--r--drivers/gpu/drm/i915/gvt/reg.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/gvt/reg.h b/drivers/gpu/drm/i915/gvt/reg.h
index 4842cb97c892..0dfe789d8f02 100644
--- a/drivers/gpu/drm/i915/gvt/reg.h
+++ b/drivers/gpu/drm/i915/gvt/reg.h
@@ -72,4 +72,9 @@
#define FORCEWAKE_ACK_MEDIA_GEN9_REG 0x0D88
#define FORCEWAKE_ACK_HSW_REG 0x130044
+#define RB_HEAD_OFF_MASK ((1U << 21) - (1U << 2))
+#define RB_TAIL_OFF_MASK ((1U << 21) - (1U << 3))
+#define RB_TAIL_SIZE_MASK ((1U << 21) - (1U << 12))
+#define _RING_CTL_BUF_SIZE(ctl) (((ctl) & RB_TAIL_SIZE_MASK) + GTT_PAGE_SIZE)
+
#endif