[PATCH 1/2] drm/i915/display: pass display to intel_crtc_for_pipe()

Ville Syrjälä ville.syrjala at linux.intel.com
Wed Sep 4 13:43:19 UTC 2024


On Wed, Sep 04, 2024 at 04:06:32PM +0300, Jani Nikula wrote:
> Convert the intel_crtc_for_pipe() struct drm_i915_private parameter to
> struct intel_display.
> 
> Signed-off-by: Jani Nikula <jani.nikula at intel.com>
> ---
>  drivers/gpu/drm/i915/display/i9xx_wm.c          | 15 ++++++++++-----
>  .../gpu/drm/i915/display/intel_atomic_plane.c   |  4 ++--
>  drivers/gpu/drm/i915/display/intel_cdclk.c      |  6 ++++--
>  drivers/gpu/drm/i915/display/intel_crt.c        |  3 ++-
>  drivers/gpu/drm/i915/display/intel_crtc.c       |  8 +++++---
>  drivers/gpu/drm/i915/display/intel_crtc.h       |  3 ++-
>  drivers/gpu/drm/i915/display/intel_display.c    | 17 ++++++++++-------
>  .../gpu/drm/i915/display/intel_display_driver.c |  3 ++-
>  .../gpu/drm/i915/display/intel_display_irq.c    |  9 ++++++---
>  .../gpu/drm/i915/display/intel_display_trace.h  | 15 ++++++++++-----
>  drivers/gpu/drm/i915/display/intel_dpll.c       |  3 ++-
>  drivers/gpu/drm/i915/display/intel_dsb.c        |  2 +-
>  drivers/gpu/drm/i915/display/intel_fbc.c        |  3 +--
>  drivers/gpu/drm/i915/display/intel_fdi.c        | 10 ++++++----
>  .../gpu/drm/i915/display/intel_fifo_underrun.c  | 15 ++++++++++-----
>  drivers/gpu/drm/i915/display/intel_link_bw.c    |  3 +--
>  .../gpu/drm/i915/display/intel_modeset_setup.c  | 12 ++++++++----
>  .../gpu/drm/i915/display/intel_sprite_uapi.c    |  3 ++-
>  drivers/gpu/drm/i915/display/skl_watermark.c    |  7 ++++---
>  19 files changed, 88 insertions(+), 53 deletions(-)
> 
<snip>
> diff --git a/drivers/gpu/drm/i915/display/intel_crtc.c b/drivers/gpu/drm/i915/display/intel_crtc.c
> index 1b578cad2813..32e0f2907899 100644
> --- a/drivers/gpu/drm/i915/display/intel_crtc.c
> +++ b/drivers/gpu/drm/i915/display/intel_crtc.c
> @@ -48,12 +48,12 @@ struct intel_crtc *intel_first_crtc(struct drm_i915_private *i915)
>  	return to_intel_crtc(drm_crtc_from_index(&i915->drm, 0));
>  }
>  
> -struct intel_crtc *intel_crtc_for_pipe(struct drm_i915_private *i915,
> +struct intel_crtc *intel_crtc_for_pipe(struct intel_display *display,
>  				       enum pipe pipe)
>  {
>  	struct intel_crtc *crtc;
>  
> -	for_each_intel_crtc(&i915->drm, crtc) {
> +	for_each_intel_crtc(display->drm, crtc) {
>  		if (crtc->pipe == pipe)
>  			return crtc;
>  	}
> @@ -69,7 +69,9 @@ void intel_crtc_wait_for_next_vblank(struct intel_crtc *crtc)
>  void intel_wait_for_vblank_if_active(struct drm_i915_private *i915,
>  				     enum pipe pipe)
>  {
> -	struct intel_crtc *crtc = intel_crtc_for_pipe(i915, pipe);
> +	struct intel_display *display = &i915->display;
> +

Stray newline.

Series is
Reviewed-by: Ville Syrjälä <ville.syrjala at linux.intel.com>

> +	struct intel_crtc *crtc = intel_crtc_for_pipe(display, pipe);
>  
>  	if (crtc->active)
>  		intel_crtc_wait_for_next_vblank(crtc);

-- 
Ville Syrjälä
Intel


More information about the Intel-gfx mailing list