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

Commit c28bf7dc authored by Lina Iyer's avatar Lina Iyer Committed by Gerrit - the friendly Code Review server
Browse files

drivers: cpuidle: check if its okay to do cluster low power modes



If the system is not idle, for example, RPMH module is busy sending RPMH
requests or waiting on a response, then do not choose cluster low power
modes that reset the state.

Change-Id: I2870082163646a8931adf050a1104f469d4543de
Signed-off-by: default avatarLina Iyer <ilina@codeaurora.org>
parent 4524c0ed
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -959,6 +959,9 @@ static int cluster_select(struct lpm_cluster *cluster, bool from_idle,
		if (suspend_in_progress && from_idle && level->notify_rpm)
			continue;

		if (level->is_reset && !system_sleep_allowed())
			continue;

		best_level = i;

		if (from_idle &&
@@ -1021,7 +1024,8 @@ static int cluster_configure(struct lpm_cluster *cluster, int idx,
		clear_predict_history();
		clear_cl_predict_history();

		system_sleep_enter(us);
		if (system_sleep_enter(us))
			return -EBUSY;
	}
	/* Notify cluster enter event after successfully config completion */
	cluster_notify(cluster, level, true);