From 3c443961073c821ab50bc1ded0558dd7bf6aeac6 Mon Sep 17 00:00:00 2001 From: Pavankumar Kondeti Date: Fri, 9 Feb 2018 13:53:04 +0530 Subject: sched: add sched_get_cpu_last_busy_time() API sched_get_cpu_last_busy_time() returns the last time stamp when a given CPU is busy with more than 2 runnable tasks or has load greater than 50% of it's max capacity. The LPM driver can make use of this API and create a policy to prevent a recently loaded CPU entering deep sleep state. This API is implemented only for the higher capacity CPUs in the system. It returns 0 for other CPUs. Change-Id: I97ef47970a71647f4f55f21165d0cc1351770a53 Signed-off-by: Pavankumar Kondeti --- include/linux/sched.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/linux') diff --git a/include/linux/sched.h b/include/linux/sched.h index 92b59a1c2010..0bfa46261687 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -182,6 +182,7 @@ extern void sched_update_nr_prod(int cpu, long delta, bool inc); extern void sched_get_nr_running_avg(int *avg, int *iowait_avg, int *big_avg, unsigned int *max_nr, unsigned int *big_max_nr); +extern u64 sched_get_cpu_last_busy_time(int cpu); extern void calc_global_load(unsigned long ticks); -- cgit v1.2.3