drm/i915/pps: rename intel_edp_panel_* to intel_pps_*
authorJani Nikula <jani.nikula@intel.com>
Fri, 8 Jan 2021 17:44:12 +0000 (19:44 +0200)
committerJani Nikula <jani.nikula@intel.com>
Thu, 14 Jan 2021 08:23:02 +0000 (10:23 +0200)
Follow the usual naming pattern for functions. We don't need to repeat
"panel" here. No functional changes.

v2: Fix comment (Anshuman)

Reviewed-by: Anshuman Gupta <anshuman.gupta@intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/b858271bd4d9c4a2ce15a13301d7bd9f7d121eb5.1610127741.git.jani.nikula@intel.com
drivers/gpu/drm/i915/display/intel_ddi.c
drivers/gpu/drm/i915/display/intel_dp.c
drivers/gpu/drm/i915/display/intel_pps.c
drivers/gpu/drm/i915/display/intel_pps.h

index 5364bf4..d714e8b 100644 (file)
@@ -3626,7 +3626,7 @@ static void tgl_ddi_pre_enable_dp(struct intel_atomic_state *state,
         */
 
        /* 2. Enable Panel Power if PPS is required */
-       intel_edp_panel_on(intel_dp);
+       intel_pps_on(intel_dp);
 
        /*
         * 3. For non-TBT Type-C ports, set FIA lane count
@@ -3769,7 +3769,7 @@ static void hsw_ddi_pre_enable_dp(struct intel_atomic_state *state,
                                 crtc_state->port_clock,
                                 crtc_state->lane_count);
 
-       intel_edp_panel_on(intel_dp);
+       intel_pps_on(intel_dp);
 
        intel_ddi_clk_select(encoder, crtc_state);
 
@@ -4011,8 +4011,8 @@ static void intel_ddi_post_disable_dp(struct intel_atomic_state *state,
        if (INTEL_GEN(dev_priv) >= 12)
                intel_ddi_disable_pipe_clock(old_crtc_state);
 
-       intel_edp_panel_vdd_on(intel_dp);
-       intel_edp_panel_off(intel_dp);
+       intel_pps_vdd_on(intel_dp);
+       intel_pps_off(intel_dp);
 
        if (!intel_phy_is_tc(dev_priv, phy) ||
            dig_port->tc_mode != TC_PORT_TBT_ALT)
index a3a98b3..1b538da 100644 (file)
@@ -3058,10 +3058,10 @@ static void intel_disable_dp(struct intel_atomic_state *state,
 
        /* Make sure the panel is off before trying to change the mode. But also
         * ensure that we have vdd while we switch off the panel. */
-       intel_edp_panel_vdd_on(intel_dp);
+       intel_pps_vdd_on(intel_dp);
        intel_edp_backlight_off(old_conn_state);
        intel_dp_set_power(intel_dp, DP_SET_POWER_D3);
-       intel_edp_panel_off(intel_dp);
+       intel_pps_off(intel_dp);
        intel_dp->frl.is_trained = false;
        intel_dp->frl.trained_rate_gbps = 0;
 }
@@ -6390,7 +6390,7 @@ void intel_dp_encoder_reset(struct drm_encoder *encoder)
                         * something nasty with it.
                         */
                        intel_dp_pps_init(intel_dp);
-                       intel_edp_panel_vdd_sanitize(intel_dp);
+                       intel_pps_vdd_sanitize(intel_dp);
                }
        }
 }
@@ -6564,7 +6564,7 @@ intel_dp_hpd_pulse(struct intel_digital_port *dig_port, bool long_hpd)
        struct intel_dp *intel_dp = &dig_port->dp;
 
        if (dig_port->base.type == INTEL_OUTPUT_EDP &&
-           (long_hpd || !intel_edp_have_power(intel_dp))) {
+           (long_hpd || !intel_pps_have_power(intel_dp))) {
                /*
                 * vdd off can generate a long/short pulse on eDP which
                 * would require vdd on to handle it, and thus we
@@ -7122,7 +7122,7 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,
        with_intel_pps_lock(intel_dp, wakeref) {
                intel_dp_init_panel_power_timestamps(intel_dp);
                intel_dp_pps_init(intel_dp);
-               intel_edp_panel_vdd_sanitize(intel_dp);
+               intel_pps_vdd_sanitize(intel_dp);
        }
 
        /* Cache DPCD and EDID for edp. */
index 36d8782..59215cf 100644 (file)
@@ -558,7 +558,7 @@ static  u32 ilk_get_pp_control(struct intel_dp *intel_dp)
 /*
  * Must be paired with edp_panel_vdd_off().
  * Must hold pps_mutex around the whole on/off sequence.
- * Can be nested with intel_edp_panel_vdd_{on,off}() calls.
+ * Can be nested with intel_pps_vdd_{on,off}() calls.
  */
 bool edp_panel_vdd_on(struct intel_dp *intel_dp)
 {
@@ -616,13 +616,12 @@ bool edp_panel_vdd_on(struct intel_dp *intel_dp)
 }
 
 /*
- * Must be paired with intel_edp_panel_vdd_off() or
- * intel_edp_panel_off().
+ * Must be paired with intel_pps_off().
  * Nested calls to these functions are not allowed since
  * we drop the lock. Caller must use some higher level
  * locking to prevent nested calls from other threads.
  */
-void intel_edp_panel_vdd_on(struct intel_dp *intel_dp)
+void intel_pps_vdd_on(struct intel_dp *intel_dp)
 {
        intel_wakeref_t wakeref;
        bool vdd;
@@ -708,7 +707,7 @@ static void edp_panel_vdd_schedule_off(struct intel_dp *intel_dp)
 /*
  * Must be paired with edp_panel_vdd_on().
  * Must hold pps_mutex around the whole on/off sequence.
- * Can be nested with intel_edp_panel_vdd_{on,off}() calls.
+ * Can be nested with intel_pps_vdd_{on,off}() calls.
  */
 void edp_panel_vdd_off(struct intel_dp *intel_dp, bool sync)
 {
@@ -780,7 +779,7 @@ void edp_panel_on(struct intel_dp *intel_dp)
        }
 }
 
-void intel_edp_panel_on(struct intel_dp *intel_dp)
+void intel_pps_on(struct intel_dp *intel_dp)
 {
        intel_wakeref_t wakeref;
 
@@ -832,7 +831,7 @@ void edp_panel_off(struct intel_dp *intel_dp)
                                fetch_and_zero(&intel_dp->vdd_wakeref));
 }
 
-void intel_edp_panel_off(struct intel_dp *intel_dp)
+void intel_pps_off(struct intel_dp *intel_dp)
 {
        intel_wakeref_t wakeref;
 
@@ -1025,7 +1024,7 @@ void vlv_init_panel_power_sequencer(struct intel_encoder *encoder,
        intel_dp_init_panel_power_sequencer_registers(intel_dp, true);
 }
 
-void intel_edp_panel_vdd_sanitize(struct intel_dp *intel_dp)
+void intel_pps_vdd_sanitize(struct intel_dp *intel_dp)
 {
        struct drm_i915_private *dev_priv = dp_to_i915(intel_dp);
        struct intel_digital_port *dig_port = dp_to_dig_port(intel_dp);
@@ -1050,7 +1049,7 @@ void intel_edp_panel_vdd_sanitize(struct intel_dp *intel_dp)
        edp_panel_vdd_schedule_off(intel_dp);
 }
 
-bool intel_edp_have_power(struct intel_dp *intel_dp)
+bool intel_pps_have_power(struct intel_dp *intel_dp)
 {
        intel_wakeref_t wakeref;
        bool have_power = false;
index 81e4e9f..69f6706 100644 (file)
@@ -34,12 +34,11 @@ void edp_panel_on(struct intel_dp *intel_dp);
 void edp_panel_off(struct intel_dp *intel_dp);
 void edp_panel_vdd_work(struct work_struct *__work);
 
-void intel_edp_panel_vdd_on(struct intel_dp *intel_dp);
-void intel_edp_panel_on(struct intel_dp *intel_dp);
-void intel_edp_panel_off(struct intel_dp *intel_dp);
-bool intel_edp_have_power(struct intel_dp *intel_dp);
-
-void intel_edp_panel_vdd_sanitize(struct intel_dp *intel_dp);
+void intel_pps_vdd_sanitize(struct intel_dp *intel_dp);
+void intel_pps_vdd_on(struct intel_dp *intel_dp);
+void intel_pps_on(struct intel_dp *intel_dp);
+void intel_pps_off(struct intel_dp *intel_dp);
+bool intel_pps_have_power(struct intel_dp *intel_dp);
 
 void wait_panel_power_cycle(struct intel_dp *intel_dp);