drm/i915: make intel_gvt_init() later instead of too early
authorZhenyu Wang <zhenyuw@linux.intel.com>
Fri, 13 Jan 2017 02:46:09 +0000 (10:46 +0800)
committerZhenyu Wang <zhenyuw@linux.intel.com>
Tue, 7 Feb 2017 09:21:06 +0000 (17:21 +0800)
commit26f837e8e1ec9748b55be3af6d7f54b9ad5a43b1
treeb077ef85365a216ec5f28df51a3cf91f8fbfbd89
parent2c88313650f3fb9f04221101901a943bb92059b2
drm/i915: make intel_gvt_init() later instead of too early

Previously intel_gvt_init() was called very early even before
MMIO initialization which had several drawbacks:
- Have to handle MMIO access for initial MMIO state dump if golden
  state firmware is not available
- Hypervisor detection should depend on pvinfo only instead of detecting
  hypervisor status.
- Don't know hw resource size e.g aperture, ggtt size to determine
  for vGPU type, etc.

This trys to move intel_gvt_init() call late after required info
has already been initialized for GVT host.

Acked-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/intel_gvt.c