@@ -116,6 +116,7 @@ static void set_encoder_for_connector(struct intel_connector *connector,
116116
117117static void reset_encoder_connector_state (struct intel_encoder * encoder )
118118{
119+ struct intel_display * display = to_intel_display (encoder );
119120 struct drm_i915_private * i915 = to_i915 (encoder -> base .dev );
120121 struct intel_pmdemand_state * pmdemand_state =
121122 to_intel_pmdemand_state (i915 -> display .pmdemand .obj .state );
@@ -128,7 +129,7 @@ static void reset_encoder_connector_state(struct intel_encoder *encoder)
128129 continue ;
129130
130131 /* Clear the corresponding bit in pmdemand active phys mask */
131- intel_pmdemand_update_phys_mask (i915 , encoder ,
132+ intel_pmdemand_update_phys_mask (display , encoder ,
132133 pmdemand_state , false);
133134
134135 set_encoder_for_connector (connector , NULL );
@@ -152,6 +153,7 @@ static void reset_crtc_encoder_state(struct intel_crtc *crtc)
152153
153154static void intel_crtc_disable_noatomic_complete (struct intel_crtc * crtc )
154155{
156+ struct intel_display * display = to_intel_display (crtc );
155157 struct drm_i915_private * i915 = to_i915 (crtc -> base .dev );
156158 struct intel_bw_state * bw_state =
157159 to_intel_bw_state (i915 -> display .bw .obj .state );
@@ -185,7 +187,7 @@ static void intel_crtc_disable_noatomic_complete(struct intel_crtc *crtc)
185187 bw_state -> data_rate [pipe ] = 0 ;
186188 bw_state -> num_active_planes [pipe ] = 0 ;
187189
188- intel_pmdemand_update_port_clock (i915 , pmdemand_state , pipe , 0 );
190+ intel_pmdemand_update_port_clock (display , pmdemand_state , pipe , 0 );
189191}
190192
191193/*
@@ -582,6 +584,7 @@ static bool has_bogus_dpll_config(const struct intel_crtc_state *crtc_state)
582584
583585static void intel_sanitize_encoder (struct intel_encoder * encoder )
584586{
587+ struct intel_display * display = to_intel_display (encoder );
585588 struct drm_i915_private * i915 = to_i915 (encoder -> base .dev );
586589 struct intel_connector * connector ;
587590 struct intel_crtc * crtc = to_intel_crtc (encoder -> base .crtc );
@@ -613,7 +616,7 @@ static void intel_sanitize_encoder(struct intel_encoder *encoder)
613616 encoder -> base .name );
614617
615618 /* Clear the corresponding bit in pmdemand active phys mask */
616- intel_pmdemand_update_phys_mask (i915 , encoder ,
619+ intel_pmdemand_update_phys_mask (display , encoder ,
617620 pmdemand_state , false);
618621
619622 /*
@@ -770,11 +773,11 @@ static void intel_modeset_readout_hw_state(struct drm_i915_private *i915)
770773 }
771774 }
772775
773- intel_pmdemand_update_phys_mask (i915 , encoder ,
776+ intel_pmdemand_update_phys_mask (display , encoder ,
774777 pmdemand_state ,
775778 true);
776779 } else {
777- intel_pmdemand_update_phys_mask (i915 , encoder ,
780+ intel_pmdemand_update_phys_mask (display , encoder ,
778781 pmdemand_state ,
779782 false);
780783
@@ -899,13 +902,13 @@ static void intel_modeset_readout_hw_state(struct drm_i915_private *i915)
899902 cdclk_state -> min_voltage_level [crtc -> pipe ] =
900903 crtc_state -> min_voltage_level ;
901904
902- intel_pmdemand_update_port_clock (i915 , pmdemand_state , pipe ,
905+ intel_pmdemand_update_port_clock (display , pmdemand_state , pipe ,
903906 crtc_state -> port_clock );
904907
905908 intel_bw_crtc_update (bw_state , crtc_state );
906909 }
907910
908- intel_pmdemand_init_pmdemand_params (i915 , pmdemand_state );
911+ intel_pmdemand_init_pmdemand_params (display , pmdemand_state );
909912}
910913
911914static void
0 commit comments