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

Commit b029f829 authored by Chris Lew's avatar Chris Lew Committed by Gerrit - the friendly Code Review server
Browse files

soc: qcom: sleepstate: Move delay to suspend path



The previous change removed the delay from the suspend path and reduced
the delay on the resume path. The correct heuristic should be the
opposite. Remove the delay from resume and have a short delay on the
suspend path.

Change-Id: I5e778e10ae9338f9f7ff35cf4be006e3470f32d6
Signed-off-by: default avatarChris Lew <clew@codeaurora.org>
parent 1c7b30fe
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
/* Copyright (c) 2014-2017, The Linux Foundation. All rights reserved.
/* Copyright (c) 2014-2018, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -37,12 +37,12 @@ static int sleepstate_pm_notifier(struct notifier_block *nb,
	switch (event) {
	case PM_SUSPEND_PREPARE:
		gpio_set_value(slst_gpio_base_id + PROC_AWAKE_ID, 0);
		usleep_range(10000, 10500); /* Tuned based on SMP2P latencies */
		msm_ipc_router_set_ws_allowed(true);
		break;

	case PM_POST_SUSPEND:
		gpio_set_value(slst_gpio_base_id + PROC_AWAKE_ID, 1);
		usleep_range(10000, 10500); /* Tuned based on SMP2P latencies */
		msm_ipc_router_set_ws_allowed(false);
		break;
	}