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

Commit 13899271 authored by Syed Rameez Mustafa's avatar Syed Rameez Mustafa
Browse files

sched: Move data structures under CONFIG_SCHED_HMP



Frequency-demand conversion data structures are only used under
CONFIG_SCHED_HMP. Move them out of sched.h into hmp.c to where they
actually belong after the recent refactor.

Change-Id: I3c3eebca86062f11b80af93ba3716695eb787376
Signed-off-by: default avatarSyed Rameez Mustafa <rameezmustafa@codeaurora.org>
parent 3dc7ca5e
Loading
Loading
Loading
Loading
+12 −1
Original line number Diff line number Diff line
@@ -124,7 +124,18 @@ u32 __weak get_freq_max_load(int cpu, u32 freq)
	return 100;
}

DEFINE_PER_CPU(struct freq_max_load *, freq_max_load);
struct freq_max_load_entry {
	/* The maximum load which has accounted governor's headroom. */
	u64 hdemand;
};

struct freq_max_load {
	struct rcu_head rcu;
	int length;
	struct freq_max_load_entry freqs[0];
};

static DEFINE_PER_CPU(struct freq_max_load *, freq_max_load);
static DEFINE_SPINLOCK(freq_max_load_lock);

struct cpu_pwr_stats __weak *get_cpu_pwr_stats(void)
+0 −13
Original line number Diff line number Diff line
@@ -28,19 +28,6 @@ extern atomic_long_t calc_load_tasks;

extern void calc_global_load_tick(struct rq *this_rq);

struct freq_max_load_entry {
	/* The maximum load which has accounted governor's headroom. */
	u64 hdemand;
};

struct freq_max_load {
	struct rcu_head rcu;
	int length;
	struct freq_max_load_entry freqs[0];
};

extern DEFINE_PER_CPU(struct freq_max_load *, freq_max_load);

extern long calc_load_fold_active(struct rq *this_rq);

#ifdef CONFIG_SMP