Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 87b8f2d7 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: mdss: hdmi: Handle fast HPD interrupts"

parents 76f80210 afd6df1f
Loading
Loading
Loading
Loading
+14 −4
Original line number Diff line number Diff line
@@ -3425,9 +3425,14 @@ static int hdmi_tx_power_off(struct mdss_panel_data *panel_data)
	hdmi_ctrl->panel_power_on = false;
	mutex_unlock(&hdmi_ctrl->power_mutex);

	mutex_lock(&hdmi_ctrl->mutex);
	if (hdmi_ctrl->hpd_off_pending) {
		hdmi_tx_hpd_off(hdmi_ctrl);
		hdmi_ctrl->hpd_off_pending = false;
		mutex_unlock(&hdmi_ctrl->mutex);
		if (!hdmi_ctrl->hpd_state)
			hdmi_tx_hpd_off(hdmi_ctrl);
	} else {
		mutex_unlock(&hdmi_ctrl->mutex);
	}

	if (hdmi_ctrl->hdmi_tx_hpd_done)
@@ -3656,11 +3661,14 @@ static int hdmi_tx_sysfs_enable_hpd(struct hdmi_tx_ctrl *hdmi_ctrl, int on)
			reinit_completion(&hdmi_ctrl->hpd_off_done);
			timeout = wait_for_completion_timeout(
				&hdmi_ctrl->hpd_off_done, HZ);

			if (!timeout)
			if (!timeout) {
				hdmi_ctrl->hpd_off_pending = false;
				DEV_ERR("%s: hpd off still pending\n",
					__func__);
				return 0;
			}
		}

		rc = hdmi_tx_hpd_on(hdmi_ctrl);
	} else {
		mutex_lock(&hdmi_ctrl->power_mutex);
@@ -4119,7 +4127,9 @@ static int hdmi_tx_panel_event_handler(struct mdss_panel_data *panel_data,
			hdmi_tx_power_off(panel_data);
			panel_data->panel_info.cont_splash_enabled = false;
		} else {
			if (hdmi_ctrl->hpd_feature_on)
			if (hdmi_ctrl->hpd_feature_on &&
				hdmi_ctrl->hpd_initialized &&
				!hdmi_ctrl->hpd_state)
				hdmi_tx_hpd_polarity_setup(hdmi_ctrl,
					HPD_CONNECT_POLARITY);
		}