Quoting Jani Nikula (2023-10-02 05:47:04-03:00) >Since gt0 == i915->gt[0], just drop the former. > >Signed-off-by: Jani Nikula <jani.nikula@xxxxxxxxx> Reviewed-by: Gustavo Sousa <gustavo.sousa@xxxxxxxxx> >--- > drivers/gpu/drm/i915/gt/intel_gt.c | 4 +--- > drivers/gpu/drm/i915/i915_drv.h | 8 +------- > drivers/gpu/drm/i915/selftests/mock_gem_device.c | 1 - > 3 files changed, 2 insertions(+), 11 deletions(-) > >diff --git a/drivers/gpu/drm/i915/gt/intel_gt.c b/drivers/gpu/drm/i915/gt/intel_gt.c >index b293ace6745d..ed32bf5b1546 100644 >--- a/drivers/gpu/drm/i915/gt/intel_gt.c >+++ b/drivers/gpu/drm/i915/gt/intel_gt.c >@@ -68,7 +68,7 @@ int intel_root_gt_init_early(struct drm_i915_private *i915) > if (!gt) > return -ENOMEM; > >- i915->gt0 = gt; >+ i915->gt[0] = gt; > > gt->i915 = i915; > gt->uncore = &i915->uncore; >@@ -928,8 +928,6 @@ int intel_gt_probe_all(struct drm_i915_private *i915) > if (ret) > return ret; > >- i915->gt[0] = gt; >- > if (!HAS_EXTRA_GT_LIST(i915)) > return 0; > >diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h >index a1cb16afa46d..d04a9c32c44f 100644 >--- a/drivers/gpu/drm/i915/i915_drv.h >+++ b/drivers/gpu/drm/i915/i915_drv.h >@@ -317,12 +317,6 @@ struct drm_i915_private { > > struct i915_hwmon *hwmon; > >- /* Abstract the submission mechanism (legacy ringbuffer or execlists) away */ >- struct intel_gt *gt0; >- >- /* >- * i915->gt[0] == i915->gt0 >- */ > struct intel_gt *gt[I915_MAX_GT]; > > struct kobject *sysfs_gt; >@@ -384,7 +378,7 @@ static inline struct drm_i915_private *pdev_to_i915(struct pci_dev *pdev) > > static inline struct intel_gt *to_gt(const struct drm_i915_private *i915) > { >- return i915->gt0; >+ return i915->gt[0]; > } > > /* Simple iterator over all initialised engines */ >diff --git a/drivers/gpu/drm/i915/selftests/mock_gem_device.c b/drivers/gpu/drm/i915/selftests/mock_gem_device.c >index 7de6477803f8..af349fd9abc2 100644 >--- a/drivers/gpu/drm/i915/selftests/mock_gem_device.c >+++ b/drivers/gpu/drm/i915/selftests/mock_gem_device.c >@@ -114,7 +114,6 @@ static struct dev_pm_domain pm_domain = { > > static void mock_gt_probe(struct drm_i915_private *i915) > { >- i915->gt[0] = to_gt(i915); > i915->gt[0]->name = "Mock GT"; > } > >-- >2.39.2 >