@@ -223,6 +223,7 @@ static void intel_detect_pch(struct drm_i915_private *dev_priv)
PCI_SUBVENDOR_ID_REDHAT_QUMRANET &&
pch->subsystem_device ==
PCI_SUBDEVICE_ID_QEMU)) {
+ dev_priv->run_on_qemu = true;
dev_priv->pch_type =
intel_virt_detect_pch(dev_priv);
} else
@@ -2145,6 +2145,7 @@ struct drm_i915_private {
struct intel_uncore uncore;
struct i915_virtual_gpu vgpu;
+ bool run_on_qemu;
struct intel_gvt *gvt;
@@ -409,8 +409,8 @@ int i915_gem_init_stolen(struct drm_i915_private *dev_priv)
mutex_init(&dev_priv->mm.stolen_lock);
- if (intel_vgpu_active(dev_priv)) {
- DRM_INFO("iGVT-g active, disabling use of stolen memory\n");
+ if (dev_priv->run_on_qemu || intel_vgpu_active(dev_priv)) {
+ DRM_INFO("Running in guest, disabling use of stolen memory\n");
return 0;
}