]> git.baikalelectronics.ru Git - kernel.git/commitdiff
drm/i915/gvt: Use to_gt() helper
authorMichał Winiarski <michal.winiarski@intel.com>
Tue, 14 Dec 2021 19:33:36 +0000 (21:33 +0200)
committerMatt Roper <matthew.d.roper@intel.com>
Sat, 18 Dec 2021 05:50:41 +0000 (21:50 -0800)
Use to_gt() helper consistently throughout the codebase.
Pure mechanical s/i915->gt/to_gt(i915). No functional changes.

Signed-off-by: Michał Winiarski <michal.winiarski@intel.com>
Signed-off-by: Andi Shyti <andi.shyti@linux.intel.com>
Reviewed-by: Matt Roper <matthew.d.roper@intel.com>
Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20211214193346.21231-7-andi.shyti@linux.intel.com
drivers/gpu/drm/i915/gvt/gvt.c
drivers/gpu/drm/i915/gvt/scheduler.c

index cbac409f6c8a56b84442615f04ae46420106e993..f0b69e4dcb5256597581a5ce76576ece147182eb 100644 (file)
@@ -205,7 +205,7 @@ int intel_gvt_init_device(struct drm_i915_private *i915)
        spin_lock_init(&gvt->scheduler.mmio_context_lock);
        mutex_init(&gvt->lock);
        mutex_init(&gvt->sched_lock);
-       gvt->gt = &i915->gt;
+       gvt->gt = to_gt(i915);
        i915->gvt = gvt;
 
        init_device_info(gvt);
index 6c804102528b1760f9cbe57b5a72e3e6e99d443f..42a0c9ae0a73d929ca29d9f4e33ce3ebfeff44c1 100644 (file)
@@ -1386,7 +1386,7 @@ int intel_vgpu_setup_submission(struct intel_vgpu *vgpu)
        enum intel_engine_id i;
        int ret;
 
-       ppgtt = i915_ppgtt_create(&i915->gt, I915_BO_ALLOC_PM_EARLY);
+       ppgtt = i915_ppgtt_create(to_gt(i915), I915_BO_ALLOC_PM_EARLY);
        if (IS_ERR(ppgtt))
                return PTR_ERR(ppgtt);