[PATCH 3/3] a hack
Andi Shyti
andi.shyti at linux.intel.com
Fri Nov 26 21:23:13 UTC 2021
From: Andi Shyti <andi at etezian.org>
---
drivers/gpu/drm/i915/gt/intel_gt.c | 8 ++++++--
drivers/gpu/drm/i915/i915_driver.c | 1 +
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/i915/gt/intel_gt.c b/drivers/gpu/drm/i915/gt/intel_gt.c
index f2422d48be32..ea7ab071a48a 100644
--- a/drivers/gpu/drm/i915/gt/intel_gt.c
+++ b/drivers/gpu/drm/i915/gt/intel_gt.c
@@ -27,8 +27,12 @@
void intel_gt_init_early(struct intel_gt *gt, struct drm_i915_private *i915)
{
- gt->i915 = i915;
- gt->uncore = &i915->uncore;
+ if (!gt->i915 || !gt->uncore) {
+ gt->i915 = i915;
+ gt->uncore = &i915->uncore;
+
+ return;
+ }
spin_lock_init(>->irq_lock);
diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
index 4ac7b84eaf12..8db7413eaebe 100644
--- a/drivers/gpu/drm/i915/i915_driver.c
+++ b/drivers/gpu/drm/i915/i915_driver.c
@@ -315,6 +315,7 @@ static int i915_driver_early_probe(struct drm_i915_private *dev_priv)
intel_device_info_subplatform_init(dev_priv);
intel_step_init(dev_priv);
+ intel_gt_init_early(to_root_gt(dev_priv), dev_priv);
intel_uncore_mmio_debug_init_early(&dev_priv->mmio_debug);
intel_uncore_init_early(&dev_priv->uncore, to_root_gt(dev_priv));
--
2.34.0
More information about the Intel-gfx-trybot
mailing list