For qultivate target its trying to call per_cpu() for
cpu's which are fused out and leading to crash So, Add
a check for available cpu's before calling per_cpu.
Change-Id: Idfd97fcfc83baa59afe9010396e7b6314087bf13
Signed-off-by: Avaneesh Kumar Dwivedi <quic_akdwived@quicinc.com>
Signed-off-by: Chetan C R <quic_cchinnad@quicinc.com>
Improve the naming and types of variables in eval_need,
reduce computation and adjust the tracepoint to reflect
the new names of variables.
Change-Id: Ifc19bc802bbc8382577b0e4ed4b4c9be77ffe99e
Signed-off-by: Stephen Dickey <dickey@codeaurora.org>
Signed-off-by: Tengfei Fan <tengfeif@codeaurora.org>
Improve core_ctl tracing such that the necessary flags for
debugging eval_need are present in the trace, and so that
all returns go through the same tracepoint, unlocking, and
return functionality.
Change-Id: I61d5ab86ba7650bea77e4416b0ffa9a07869bbf3
Signed-off-by: Stephen Dickey <dickey@codeaurora.org>
Signed-off-by: Tengfei Fan <tengfeif@codeaurora.org>
This change is for general scheduler improvement.
Change-Id: I42edf6c6df05f0bf72e4c57ee701916860773428
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Tengfei Fan <tengfeif@codeaurora.org>
This change is for general scheduler improvement.
Change-Id: I17cca453e5a4e6bbf4d0b55440d9f776dc2583cb
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Tengfei Fan <tengfeif@codeaurora.org>
Check if necessary to do exit and next_boost enter
oprations instead of doing it regardlessly.
Core control boost refcounts has been wrong if doing
current sched_boost exit and next_boost enter by mistake.
Change-Id: Ie40ebf0be0e1b99291d07d160ebef5964d44ba16
Signed-off-by: Maria Yu <aiquny@codeaurora.org>
Signed-off-by: Tengfei Fan <tengfeif@codeaurora.org>
This change is for general scheduler improvements.
Change-Id: I78a13f15f7b95d7b6583222fbc68b828e651b802
Signed-off-by: Lingutla Chandrasekhar <clingutla@codeaurora.org>
This change is for general scheduler improvements.
Change-Id: Ib0ed25f0b83a6a7bbc0f600ef2a9351d578bffb5
Signed-off-by: Lingutla Chandrasekhar <clingutla@codeaurora.org>
Re-introduce walt_high_irqload tunable to decide whether cpu is high irq
loaded or not.
This tunable takes 50 to 100 in pct, and scaled to sched_ravg_window.
ex:
echo 90 > /proc/sys/kernel/sched_cpu_high_irqload
If 90, cpu's irq load is greater than 90% of window size, then cpu
treated as high irq loaded.
Change-Id: I018d424d5eea470a640bba3aabf5691ffc227f47
Signed-off-by: Lingutla Chandrasekhar <clingutla@codeaurora.org>
This change is for general scheduler improvements.
Change-Id: I37d6cb75ca8b08d9ca155b86b7d71ff369f46e14
Signed-off-by: Lingutla Chandrasekhar <clingutla@codeaurora.org>
When CPU trying to move a task to other cpu in active load balance or
by other means, then the other helping cpu marked as reserved to avoid
it for other scheduler decisions. Once the task moved successfully,
the reservation will be cleared enables for other scheduler decisions.
The reserved flag is been analogously protected with busy cpu’s
rq->active_balance, which is protected with runqueue locks. So whenever
rq->active_balance is set for busy cpu, then reserved flag would set for
helping cpu.
Sometimes, it is observed that, cpu is marked as reserved with no cpu's
rq->active_balance set. There are some unlikely possible corner cases
may cause this behavior:
- On active load balance path, cpu stop machine returns queued status
of active_balance work on cpu_stopper, which is not checked on active
balance path. so when stop machine is not able to queue ( unlikely),
then reserved flag wouldn't be cleared.
So, catch the return value and on failure, clear reserved flag for cpu.
- Clear_walt_request() called on the cpu to clear any pending walt works,
it may possible that, push_task might have changed or cleared, then
reserved cpu would be left uncleared.
So clear the push_cpu independent of push_task.
Change-Id: I75d032bf399cb3da8e807186b1bc903114168a4e
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
Signed-off-by: Lingutla Chandrasekhar <clingutla@codeaurora.org>
There is frequent Ping-Pong effect if only consider max_nr
in core control, so also consider average max_nr which in
many windows, this will make core control more smooth.
Change-Id: Ic5f3285db604357f7c953b02ec40379ac49b95e0
Signed-off-by: Tengfei Fan <tengfeif@codeaurora.org>
The weak symbols are no longer needed as the WALT code is
moved from techpack to kernel.
Change-Id: I2918ac475d264482b039ee8b65357657c427eb28
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
This change is for general scheduler improvemnts.
Change-Id: If28d00691bc42b62cc4fc96a49d601c7ac5e3e34
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
The scheduler techpack sources are moved to kernel to ease
the development.
The weak symbol definitions for WALT functions are no longer
required to cover the case of compiling kernel without syncing
the scheduler techpack. So remove all the weak symbol references.
Change-Id: Ief85bccd3dceaf60dda44aef9893b4138dc63380
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>