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

Commit 84a90a7e authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "lpm-levels: Print enabled clocks during system suspend"

parents f07150b3 5204c22a
Loading
Loading
Loading
Loading
+2 −0
Original line number Original line Diff line number Diff line
@@ -10,6 +10,7 @@
 */
 */


struct clk_hw;
struct clk_hw;
struct clk_core;


#if defined(CONFIG_OF) && defined(CONFIG_COMMON_CLK)
#if defined(CONFIG_OF) && defined(CONFIG_COMMON_CLK)
struct clk *__of_clk_get_from_provider(struct of_phandle_args *clkspec,
struct clk *__of_clk_get_from_provider(struct of_phandle_args *clkspec,
@@ -53,4 +54,5 @@ static struct clk_hw *__clk_get_hw(struct clk *clk)
	return (struct clk_hw *)clk;
	return (struct clk_hw *)clk;
}
}


void clock_debug_print_enabled(void) {}
#endif
#endif
+10 −7
Original line number Original line Diff line number Diff line
@@ -47,6 +47,7 @@
#include <asm/cpuidle.h>
#include <asm/cpuidle.h>
#include "lpm-levels.h"
#include "lpm-levels.h"
#include <trace/events/power.h>
#include <trace/events/power.h>
#include "../clk/clk.h"
#define CREATE_TRACE_POINTS
#define CREATE_TRACE_POINTS
#include <trace/events/trace_msm_low_power.h>
#include <trace/events/trace_msm_low_power.h>


@@ -1044,6 +1045,15 @@ static int cluster_configure(struct lpm_cluster *cluster, int idx,
	}
	}


	if (level->notify_rpm) {
	if (level->notify_rpm) {
		/*
		 * Print the clocks which are enabled during system suspend
		 * This debug information is useful to know which are the
		 * clocks that are enabled and preventing the system level
		 * LPMs(XO and Vmin).
		 */
		if (!from_idle)
			clock_debug_print_enabled();

		cpu = get_next_online_cpu(from_idle);
		cpu = get_next_online_cpu(from_idle);
		cpumask_copy(&cpumask, cpumask_of(cpu));
		cpumask_copy(&cpumask, cpumask_of(cpu));
		clear_predict_history();
		clear_predict_history();
@@ -1618,13 +1628,6 @@ static int lpm_suspend_enter(suspend_state_t state)
	cpu_prepare(lpm_cpu, idx, false);
	cpu_prepare(lpm_cpu, idx, false);
	cluster_prepare(cluster, cpumask, idx, false, 0);
	cluster_prepare(cluster, cpumask, idx, false, 0);


	/*
	 * Print the clocks which are enabled during system suspend
	 * This debug information is useful to know which are the
	 * clocks that are enabled and preventing the system level
	 * LPMs(XO and Vmin).
	 */

	psci_enter_sleep(lpm_cpu, idx, false);
	psci_enter_sleep(lpm_cpu, idx, false);


	cluster_unprepare(cluster, cpumask, idx, false, 0);
	cluster_unprepare(cluster, cpumask, idx, false, 0);