mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-05 10:04:12 +08:00
drm/i915/pps: rename pps_{,un}lock -> intel_pps_{,un}lock
Start following the usual naming pattern for functions. No functional changes. Reviewed-by: Anshuman Gupta <anshuman.gupta@intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/e37623750c592c08720f3b340cf85862d0f0ca12.1610127741.git.jani.nikula@intel.com
This commit is contained in:
parent
abad6805ee
commit
7191d9d21b
@ -1060,7 +1060,7 @@ intel_dp_aux_xfer(struct intel_dp *intel_dp,
|
||||
aux_domain = intel_aux_power_domain(dig_port);
|
||||
|
||||
aux_wakeref = intel_display_power_get(i915, aux_domain);
|
||||
pps_wakeref = pps_lock(intel_dp);
|
||||
pps_wakeref = intel_pps_lock(intel_dp);
|
||||
|
||||
/*
|
||||
* We will be called with VDD already enabled for dpcd/edid/oui reads.
|
||||
@ -1212,7 +1212,7 @@ out:
|
||||
if (vdd)
|
||||
edp_panel_vdd_off(intel_dp, false);
|
||||
|
||||
pps_unlock(intel_dp, pps_wakeref);
|
||||
intel_pps_unlock(intel_dp, pps_wakeref);
|
||||
intel_display_power_put_async(i915, aux_domain, aux_wakeref);
|
||||
|
||||
if (is_tc_port)
|
||||
@ -3571,7 +3571,7 @@ static void intel_enable_dp(struct intel_atomic_state *state,
|
||||
if (drm_WARN_ON(&dev_priv->drm, dp_reg & DP_PORT_EN))
|
||||
return;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref) {
|
||||
with_intel_pps_lock(intel_dp, wakeref) {
|
||||
if (IS_VALLEYVIEW(dev_priv) || IS_CHERRYVIEW(dev_priv))
|
||||
vlv_init_panel_power_sequencer(encoder, pipe_config);
|
||||
|
||||
@ -4121,7 +4121,7 @@ intel_dp_link_down(struct intel_encoder *encoder,
|
||||
if (IS_VALLEYVIEW(dev_priv) || IS_CHERRYVIEW(dev_priv)) {
|
||||
intel_wakeref_t wakeref;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
intel_dp->active_pipe = INVALID_PIPE;
|
||||
}
|
||||
}
|
||||
@ -6308,7 +6308,7 @@ void intel_dp_encoder_flush_work(struct drm_encoder *encoder)
|
||||
* vdd might still be enabled do to the delayed vdd off.
|
||||
* Make sure vdd is actually turned off here.
|
||||
*/
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
edp_panel_vdd_off_sync(intel_dp);
|
||||
}
|
||||
|
||||
@ -6336,7 +6336,7 @@ void intel_dp_encoder_suspend(struct intel_encoder *intel_encoder)
|
||||
* Make sure vdd is actually turned off here.
|
||||
*/
|
||||
cancel_delayed_work_sync(&intel_dp->panel_vdd_work);
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
edp_panel_vdd_off_sync(intel_dp);
|
||||
}
|
||||
|
||||
@ -6348,7 +6348,7 @@ void intel_dp_encoder_shutdown(struct intel_encoder *intel_encoder)
|
||||
if (!intel_dp_is_edp(intel_dp))
|
||||
return;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
wait_panel_power_cycle(intel_dp);
|
||||
}
|
||||
|
||||
@ -6380,7 +6380,7 @@ void intel_dp_encoder_reset(struct drm_encoder *encoder)
|
||||
!intel_dp_is_edp(intel_dp))
|
||||
return;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref) {
|
||||
with_intel_pps_lock(intel_dp, wakeref) {
|
||||
if (IS_VALLEYVIEW(dev_priv) || IS_CHERRYVIEW(dev_priv))
|
||||
intel_dp->active_pipe = vlv_active_pipe(intel_dp);
|
||||
|
||||
@ -7119,7 +7119,7 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,
|
||||
return false;
|
||||
}
|
||||
|
||||
with_pps_lock(intel_dp, wakeref) {
|
||||
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);
|
||||
@ -7196,7 +7196,7 @@ out_vdd_off:
|
||||
* vdd might still be enabled do to the delayed vdd off.
|
||||
* Make sure vdd is actually turned off here.
|
||||
*/
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
edp_panel_vdd_off_sync(intel_dp);
|
||||
|
||||
return false;
|
||||
|
@ -16,7 +16,7 @@ static void
|
||||
intel_dp_init_panel_power_sequencer_registers(struct intel_dp *intel_dp,
|
||||
bool force_disable_vdd);
|
||||
|
||||
intel_wakeref_t pps_lock(struct intel_dp *intel_dp)
|
||||
intel_wakeref_t intel_pps_lock(struct intel_dp *intel_dp)
|
||||
{
|
||||
struct drm_i915_private *dev_priv = dp_to_i915(intel_dp);
|
||||
intel_wakeref_t wakeref;
|
||||
@ -31,7 +31,8 @@ intel_wakeref_t pps_lock(struct intel_dp *intel_dp)
|
||||
return wakeref;
|
||||
}
|
||||
|
||||
intel_wakeref_t pps_unlock(struct intel_dp *intel_dp, intel_wakeref_t wakeref)
|
||||
intel_wakeref_t intel_pps_unlock(struct intel_dp *intel_dp,
|
||||
intel_wakeref_t wakeref)
|
||||
{
|
||||
struct drm_i915_private *dev_priv = dp_to_i915(intel_dp);
|
||||
|
||||
@ -630,7 +631,7 @@ void intel_edp_panel_vdd_on(struct intel_dp *intel_dp)
|
||||
return;
|
||||
|
||||
vdd = false;
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
vdd = edp_panel_vdd_on(intel_dp);
|
||||
I915_STATE_WARN(!vdd, "[ENCODER:%d:%s] VDD already requested on\n",
|
||||
dp_to_dig_port(intel_dp)->base.base.base.id,
|
||||
@ -685,7 +686,7 @@ void edp_panel_vdd_work(struct work_struct *__work)
|
||||
struct intel_dp, panel_vdd_work);
|
||||
intel_wakeref_t wakeref;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref) {
|
||||
with_intel_pps_lock(intel_dp, wakeref) {
|
||||
if (!intel_dp->want_panel_vdd)
|
||||
edp_panel_vdd_off_sync(intel_dp);
|
||||
}
|
||||
@ -786,7 +787,7 @@ void intel_edp_panel_on(struct intel_dp *intel_dp)
|
||||
if (!intel_dp_is_edp(intel_dp))
|
||||
return;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
edp_panel_on(intel_dp);
|
||||
}
|
||||
|
||||
@ -838,7 +839,7 @@ void intel_edp_panel_off(struct intel_dp *intel_dp)
|
||||
if (!intel_dp_is_edp(intel_dp))
|
||||
return;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
edp_panel_off(intel_dp);
|
||||
}
|
||||
|
||||
@ -856,7 +857,7 @@ void _intel_edp_backlight_on(struct intel_dp *intel_dp)
|
||||
*/
|
||||
wait_backlight_on(intel_dp);
|
||||
|
||||
with_pps_lock(intel_dp, wakeref) {
|
||||
with_intel_pps_lock(intel_dp, wakeref) {
|
||||
i915_reg_t pp_ctrl_reg = _pp_ctrl_reg(intel_dp);
|
||||
u32 pp;
|
||||
|
||||
@ -877,7 +878,7 @@ void _intel_edp_backlight_off(struct intel_dp *intel_dp)
|
||||
if (!intel_dp_is_edp(intel_dp))
|
||||
return;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref) {
|
||||
with_intel_pps_lock(intel_dp, wakeref) {
|
||||
i915_reg_t pp_ctrl_reg = _pp_ctrl_reg(intel_dp);
|
||||
u32 pp;
|
||||
|
||||
@ -904,7 +905,7 @@ void intel_edp_backlight_power(struct intel_connector *connector, bool enable)
|
||||
bool is_enabled;
|
||||
|
||||
is_enabled = false;
|
||||
with_pps_lock(intel_dp, wakeref)
|
||||
with_intel_pps_lock(intel_dp, wakeref)
|
||||
is_enabled = ilk_get_pp_control(intel_dp) & EDP_BLC_ENABLE;
|
||||
if (is_enabled == enable)
|
||||
return;
|
||||
@ -1054,7 +1055,7 @@ bool intel_edp_have_power(struct intel_dp *intel_dp)
|
||||
intel_wakeref_t wakeref;
|
||||
bool have_power = false;
|
||||
|
||||
with_pps_lock(intel_dp, wakeref) {
|
||||
with_intel_pps_lock(intel_dp, wakeref) {
|
||||
have_power = edp_have_panel_power(intel_dp) &&
|
||||
edp_have_panel_vdd(intel_dp);
|
||||
}
|
||||
|
@ -16,11 +16,11 @@ struct intel_crtc_state;
|
||||
struct intel_dp;
|
||||
struct intel_encoder;
|
||||
|
||||
intel_wakeref_t pps_lock(struct intel_dp *intel_dp);
|
||||
intel_wakeref_t pps_unlock(struct intel_dp *intel_dp, intel_wakeref_t wakeref);
|
||||
intel_wakeref_t intel_pps_lock(struct intel_dp *intel_dp);
|
||||
intel_wakeref_t intel_pps_unlock(struct intel_dp *intel_dp, intel_wakeref_t wakeref);
|
||||
|
||||
#define with_pps_lock(dp, wf) \
|
||||
for ((wf) = pps_lock(dp); (wf); (wf) = pps_unlock((dp), (wf)))
|
||||
#define with_intel_pps_lock(dp, wf) \
|
||||
for ((wf) = intel_pps_lock(dp); (wf); (wf) = intel_pps_unlock((dp), (wf)))
|
||||
|
||||
void intel_dp_check_edp(struct intel_dp *intel_dp);
|
||||
void _intel_edp_backlight_on(struct intel_dp *intel_dp);
|
||||
|
Loading…
Reference in New Issue
Block a user