sched/walt: complain if num clusters is high

num_sched_clusters has to be less than MAX_CLUSTERS, complain otherwise.

Change-Id: I0648585139d31dc948cf73aae7d093757a5762cc
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
This commit is contained in:
Abhijeet Dharmapurikar 2021-06-14 14:51:49 -07:00 committed by Rishabh Bhatnagar
parent 031f8e8239
commit beb88676bf

View File

@ -2373,6 +2373,8 @@ static void add_cluster(const struct cpumask *cpus, struct list_head *head)
int i;
struct walt_rq *wrq;
BUG_ON(num_sched_clusters >= MAX_CLUSTERS);
for_each_cpu(i, cpus) {
wrq = (struct walt_rq *) cpu_rq(i)->android_vendor_data1;
wrq->cluster = cluster;