From 06a50913d96ed0f2e9ecd1ee3f224af72b03af6b Mon Sep 17 00:00:00 2001 From: Jani Nikula Date: Wed, 24 Aug 2022 16:15:32 +0300 Subject: [PATCH] drm/i915: move fdi_funcs to display.funcs Move display fdi functions under drm_i915_private display sub-struct. Signed-off-by: Jani Nikula Reviewed-by: Arun R Murthy Reviewed-by: Lucas De Marchi Link: https://patchwork.freedesktop.org/patch/msgid/16ff8df6c08411c0e5aac3356dffe7f5120fcfeb.1661346845.git.jani.nikula@intel.com --- drivers/gpu/drm/i915/display/intel_display_core.h | 4 ++++ drivers/gpu/drm/i915/display/intel_fdi.c | 8 ++++---- drivers/gpu/drm/i915/i915_drv.h | 4 ---- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_display_core.h b/drivers/gpu/drm/i915/display/intel_display_core.h index b829b30..afb1b0a 100644 --- a/drivers/gpu/drm/i915/display/intel_display_core.h +++ b/drivers/gpu/drm/i915/display/intel_display_core.h @@ -14,6 +14,7 @@ struct intel_cdclk_funcs; struct intel_crtc; struct intel_crtc_state; struct intel_dpll_funcs; +struct intel_fdi_funcs; struct intel_hotplug_funcs; struct intel_initial_plane_config; @@ -67,6 +68,9 @@ struct intel_display { /* pm display functions */ const struct intel_wm_funcs *wm; + + /* fdi display functions */ + const struct intel_fdi_funcs *fdi; } funcs; }; diff --git a/drivers/gpu/drm/i915/display/intel_fdi.c b/drivers/gpu/drm/i915/display/intel_fdi.c index 67d2484..03ad5f5 100644 --- a/drivers/gpu/drm/i915/display/intel_fdi.c +++ b/drivers/gpu/drm/i915/display/intel_fdi.c @@ -113,7 +113,7 @@ void intel_fdi_link_train(struct intel_crtc *crtc, { struct drm_i915_private *dev_priv = to_i915(crtc->base.dev); - dev_priv->fdi_funcs->fdi_link_train(crtc, crtc_state); + dev_priv->display.funcs.fdi->fdi_link_train(crtc, crtc_state); } /* units of 100MHz */ @@ -1066,11 +1066,11 @@ void intel_fdi_init_hook(struct drm_i915_private *dev_priv) { if (IS_IRONLAKE(dev_priv)) { - dev_priv->fdi_funcs = &ilk_funcs; + dev_priv->display.funcs.fdi = &ilk_funcs; } else if (IS_SANDYBRIDGE(dev_priv)) { - dev_priv->fdi_funcs = &gen6_funcs; + dev_priv->display.funcs.fdi = &gen6_funcs; } else if (IS_IVYBRIDGE(dev_priv)) { /* FIXME: detect B0+ stepping and use auto training */ - dev_priv->fdi_funcs = &ivb_funcs; + dev_priv->display.funcs.fdi = &ivb_funcs; } } diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h index 6d1d6c3..44aa6d9 100644 --- a/drivers/gpu/drm/i915/i915_drv.h +++ b/drivers/gpu/drm/i915/i915_drv.h @@ -90,7 +90,6 @@ struct intel_connector; struct intel_dp; struct intel_encoder; struct intel_fbdev; -struct intel_fdi_funcs; struct intel_gmbus; struct intel_limit; struct intel_overlay; @@ -486,9 +485,6 @@ struct drm_i915_private { /* pm private clock gating functions */ const struct drm_i915_clock_gating_funcs *clock_gating_funcs; - /* fdi display functions */ - const struct intel_fdi_funcs *fdi_funcs; - /* Display internal color functions */ const struct intel_color_funcs *color_funcs; -- 2.7.4