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

Commit 0cee1e86 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "sched: walt: move walt_stats member in cfs_rq under CFS_BANDWIDTH"

parents b7a4d9d4 538d9022
Loading
Loading
Loading
Loading
+31 −0
Original line number Diff line number Diff line
@@ -160,6 +160,37 @@ DEFINE_EVENT(softirq, softirq_raise,
	TP_ARGS(vec_nr)
);

DECLARE_EVENT_CLASS(tasklet,

	TP_PROTO(void *func),

	TP_ARGS(func),

	TP_STRUCT__entry(
		__field( void *,	func)
	),

	TP_fast_assign(
		__entry->func = func;
	),

	TP_printk("function=%ps", __entry->func)
);

DEFINE_EVENT(tasklet, tasklet_entry,

	TP_PROTO(void *func),

	TP_ARGS(func)
);

DEFINE_EVENT(tasklet, tasklet_exit,

	TP_PROTO(void *func),

	TP_ARGS(func)
);

#endif /*  _TRACE_IRQ_H */

/* This part must be outside protection */
+7 −4
Original line number Diff line number Diff line
@@ -650,11 +650,10 @@ struct cfs_rq {
	struct list_head	leaf_cfs_rq_list;
	struct task_group	*tg;	/* group that "owns" this runqueue */

#ifdef CONFIG_CFS_BANDWIDTH
#ifdef CONFIG_SCHED_WALT
	struct walt_sched_stats walt_stats;
#endif

#ifdef CONFIG_CFS_BANDWIDTH
	int			runtime_enabled;
	s64			runtime_remaining;

@@ -2169,7 +2168,7 @@ cpu_util_freq_walt(int cpu, struct sched_walt_cpu_load *walt_load);
#define sched_ravg_window TICK_NSEC
static inline u64 sched_ktime_clock(void)
{
	return 0;
	return sched_clock();
}
#endif

@@ -2646,16 +2645,20 @@ DECLARE_PER_CPU(struct update_util_data __rcu *, cpufreq_update_util_data);
static inline void cpufreq_update_util(struct rq *rq, unsigned int flags)
{
	struct update_util_data *data;
	u64 clock;

#ifdef CONFIG_SCHED_WALT
	if (!(flags & SCHED_CPUFREQ_WALT))
		return;
	clock = sched_ktime_clock();
#else
	clock = rq_clock(rq);
#endif

	data = rcu_dereference_sched(*per_cpu_ptr(&cpufreq_update_util_data,
					cpu_of(rq)));
	if (data)
		data->func(data, sched_ktime_clock(), flags);
		data->func(data, clock, flags);
}
#else
static inline void cpufreq_update_util(struct rq *rq, unsigned int flags) {}
+2 −0
Original line number Diff line number Diff line
@@ -523,7 +523,9 @@ static void tasklet_action_common(struct softirq_action *a,
				if (!test_and_clear_bit(TASKLET_STATE_SCHED,
							&t->state))
					BUG();
				trace_tasklet_entry(t->func);
				t->func(t->data);
				trace_tasklet_exit(t->func);
				tasklet_unlock(t);
				continue;
			}