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

Commit 62c70b32 authored by Tharun Raj Soma's avatar Tharun Raj Soma Committed by Gerrit - the friendly Code Review server
Browse files

drm/msm/sde: Restarting ESD status check after Doze mode



In the current implementation when display enters Doze mode
ESD status check thread is disabled. When it exits from the
Doze mode an unblank call is made to enable ESD status check
but it is not getting enabled so this change fixes the issue.

Change-Id: Ib59d47c42a91172e630225582341ab335ff03ce3
Signed-off-by: default avatarTharun Raj Soma <tsoma@codeaurora.org>
Signed-off-by: default avatarLakshmi Narayana Kalavala <lkalaval@codeaurora.org>
parent 4d5197b3
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -419,6 +419,10 @@ void sde_connector_schedule_status_work(struct drm_connector *connector,
	if (!c_conn)
		return;

	/* Return if there is no change in ESD status check condition */
	if (en == c_conn->esd_status_check)
		return;

	sde_connector_get_info(connector, &info);
	if (c_conn->ops.check_status &&
		(info.capabilities & MSM_DISPLAY_ESD_ENABLED)) {
@@ -435,9 +439,11 @@ void sde_connector_schedule_status_work(struct drm_connector *connector,
			/* Schedule ESD status check */
			schedule_delayed_work(&c_conn->status_work,
				msecs_to_jiffies(interval));
			c_conn->esd_status_check = true;
		} else {
			/* Cancel any pending ESD status check */
			cancel_delayed_work_sync(&c_conn->status_work);
			c_conn->esd_status_check = false;
		}
	}
}
@@ -487,8 +493,12 @@ static int _sde_connector_update_power_locked(struct sde_connector *c_conn)
	}
	c_conn->last_panel_power_mode = mode;

	mutex_unlock(&c_conn->lock);
	if (mode != SDE_MODE_DPMS_ON)
		sde_connector_schedule_status_work(connector, false);
	else
		sde_connector_schedule_status_work(connector, true);
	mutex_lock(&c_conn->lock);

	return rc;
}
+2 −0
Original line number Diff line number Diff line
@@ -404,6 +404,8 @@ struct sde_connector {
	u32 force_panel_dead;
	u32 esd_status_interval;

	bool esd_status_check;

	bool bl_scale_dirty;
	u32 bl_scale;
	u32 bl_scale_ad;