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

Commit 061744eb authored by Jayaprakash Madisetty's avatar Jayaprakash Madisetty
Browse files

disp: msm: sde: increase kickoff timeout for doze usecase



This change increases the kickoff timeout in doze and
doze suspend usecases. This avoids false timeouts seen
in doze due to rscc static wakeup configured at a different
fps from actual panel TE.

Change-Id: I11c94eb40d4dbbc3d95b8268b007580599ee90fd
Signed-off-by: default avatarJayaprakash Madisetty <jmadiset@codeaurora.org>
parent 7c7bd0d4
Loading
Loading
Loading
Loading
+11 −4
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0-only
/*
 * Copyright (c) 2015-2020, The Linux Foundation. All rights reserved.
 * Copyright (c) 2015-2021, The Linux Foundation. All rights reserved.
 */

#define pr_fmt(fmt)	"[drm:%s:%d] " fmt, __func__, __LINE__
@@ -1509,20 +1509,27 @@ static int _sde_encoder_phys_cmd_wait_for_wr_ptr(
	struct sde_encoder_phys_cmd *cmd_enc =
			to_sde_encoder_phys_cmd(phys_enc);
	struct sde_encoder_wait_info wait_info = {0};
	int ret;
	struct sde_connector *c_conn;
	bool frame_pending = true;
	struct sde_hw_ctl *ctl;
	unsigned long lock_flags;
	int ret, timeout_ms;

	if (!phys_enc || !phys_enc->hw_ctl) {
	if (!phys_enc || !phys_enc->hw_ctl || !phys_enc->connector) {
		SDE_ERROR("invalid argument(s)\n");
		return -EINVAL;
	}
	ctl = phys_enc->hw_ctl;
	c_conn = to_sde_connector(phys_enc->connector);
	timeout_ms = KICKOFF_TIMEOUT_MS;

	if (c_conn->lp_mode == SDE_MODE_DPMS_LP1 ||
		c_conn->lp_mode == SDE_MODE_DPMS_LP2)
		timeout_ms = (KICKOFF_TIMEOUT_MS) * 2;

	wait_info.wq = &phys_enc->pending_kickoff_wq;
	wait_info.atomic_cnt = &phys_enc->pending_retire_fence_cnt;
	wait_info.timeout_ms = KICKOFF_TIMEOUT_MS;
	wait_info.timeout_ms = timeout_ms;

	/* slave encoder doesn't enable for ppsplit */
	if (_sde_encoder_phys_is_ppsplit_slave(phys_enc))