2019-03-29 14:12:17 +08:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
2019-02-18 16:28:48 +08:00
|
|
|
From: Zhao Yakui <yakui.zhao@intel.com>
|
|
|
|
Date: Wed, 30 Jan 2019 09:20:16 +0800
|
2019-03-29 14:12:17 +08:00
|
|
|
Subject: [PATCH] drm/i915/gvt: Refine the snapshort range of I915 MCHBAR to
|
|
|
|
optimize gvt-g boot time
|
2019-02-18 16:28:48 +08:00
|
|
|
|
|
|
|
Currently it will take the snapshot of the MCHBAR registers for gvt-g
|
|
|
|
initialization so that it can be used for guest vgpu. And it will cover
|
|
|
|
from 0x140000 to 0x17ffff. In fact based on the HW spec most of them are
|
|
|
|
meanlingless and some time is wasted to read these register.
|
|
|
|
Only the range of 0x144000 to 0x147fff contains the valid definition.
|
|
|
|
So the range of capturing I915 MCHBAR register is refined, which helps
|
|
|
|
to optimize the gvt-g boot time.
|
|
|
|
|
|
|
|
Tracked-On: projectacrn/acrn-hypervisor#2451
|
|
|
|
Tracked-On: PKT-1737
|
|
|
|
Acked-by: Feng Tang <feng.tang@intel.com>
|
|
|
|
Signed-off-by: Zhao Yakui <yakui.zhao@intel.com>
|
|
|
|
---
|
|
|
|
drivers/gpu/drm/i915/gvt/handlers.c | 4 +++-
|
|
|
|
1 file changed, 3 insertions(+), 1 deletion(-)
|
|
|
|
|
|
|
|
diff --git a/drivers/gpu/drm/i915/gvt/handlers.c b/drivers/gpu/drm/i915/gvt/handlers.c
|
2020-10-27 02:14:06 +08:00
|
|
|
index f923ca71ab8e..02c12fbeafd3 100644
|
2019-02-18 16:28:48 +08:00
|
|
|
--- a/drivers/gpu/drm/i915/gvt/handlers.c
|
|
|
|
+++ b/drivers/gpu/drm/i915/gvt/handlers.c
|
|
|
|
@@ -47,6 +47,8 @@
|
|
|
|
#define PCH_PP_OFF_DELAYS _MMIO(0xc720c)
|
|
|
|
#define PCH_PP_DIVISOR _MMIO(0xc7210)
|
|
|
|
|
|
|
|
+#define MCHBAR_MEM_BASE _MMIO(MCHBAR_MIRROR_BASE_SNB + 0x4000)
|
|
|
|
+
|
|
|
|
unsigned long intel_gvt_get_device_type(struct intel_gvt *gvt)
|
|
|
|
{
|
|
|
|
if (IS_BROADWELL(gvt->dev_priv))
|
|
|
|
@@ -3443,7 +3445,7 @@ void intel_gvt_clean_mmio_info(struct intel_gvt *gvt)
|
|
|
|
/* Special MMIO blocks. */
|
|
|
|
static struct gvt_mmio_block mmio_blocks[] = {
|
|
|
|
{D_SKL_PLUS, _MMIO(CSR_MMIO_START_RANGE), 0x3000, NULL, NULL},
|
|
|
|
- {D_ALL, _MMIO(MCHBAR_MIRROR_BASE_SNB), 0x40000, NULL, NULL},
|
|
|
|
+ {D_ALL, MCHBAR_MEM_BASE, 0x4000, NULL, NULL},
|
|
|
|
{D_ALL, _MMIO(VGT_PVINFO_PAGE), VGT_PVINFO_SIZE,
|
|
|
|
pvinfo_mmio_read, pvinfo_mmio_write},
|
|
|
|
{D_ALL, LGC_PALETTE(PIPE_A, 0), 1024, NULL, NULL},
|
|
|
|
--
|
2019-04-08 18:08:36 +08:00
|
|
|
https://clearlinux.org
|
2019-02-18 16:28:48 +08:00
|
|
|
|