summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorMichael Bestas <mkbestas@lineageos.org>2020-09-19 22:34:46 +0300
committerMichael Bestas <mkbestas@lineageos.org>2020-09-19 22:34:46 +0300
commit642144e159f93a0748721d2fd36e784802dc6ed8 (patch)
tree7ab5e752f10f57c758c323be5e6996ab297c843b /kernel
parent3b601dd398b0f8a66744c0ecf384a6cbe65e36e7 (diff)
parent99c6bb5cf1297f2aa2d4fac3fad98e78aca8cbbe (diff)
Merge tag 'LA.UM.8.4.r1-06000-8x98.0' of https://source.codeaurora.org/quic/la/kernel/msm-4.4 into lineage-17.1-caf-msm8998
* tag 'LA.UM.8.4.r1-06000-8x98.0' of https://source.codeaurora.org/quic/la/kernel/msm-4.4: asoc: add missing null check for pcm pointer of snd_pcm_volume Revert "include: Fix for compilation issue" media: uvcvideo: Avoid cyclic entity chains due to malformed USB descriptors soc: add proxy ports for call screening in machine driver ARM: dts: msm: add CPU dai for additional proxy ports Input: add safety guards to input_set_keycode() sched: Fix out of bounds issue in for_each_cluster macro msm: kgsl: skip if requested address doesn't fall in the svm range msm: kgsl: Remove VM_MAYWRITE flag to restrict mprotect msm: kgsl: Correctly clean up dma buffer attachment in case of error msm: kgsl: Mark the scratch buffer as privileged msm: kgsl: Fix possible use-after-free while adding context to active list asoc: add new path for in call recording Change-Id: Ic6596e831ef92bab7134db0f49dccaab132dcd56
Diffstat (limited to 'kernel')
-rw-r--r--kernel/sched/core_ctl.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/sched/core_ctl.c b/kernel/sched/core_ctl.c
index 99f16128cf49..2f060a570061 100644
--- a/kernel/sched/core_ctl.c
+++ b/kernel/sched/core_ctl.c
@@ -1,4 +1,4 @@
-/* Copyright (c) 2014-2017, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2014-2017, 2020 The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
@@ -71,8 +71,8 @@ static struct cluster_data cluster_state[MAX_CLUSTERS];
static unsigned int num_clusters;
#define for_each_cluster(cluster, idx) \
- for ((cluster) = &cluster_state[idx]; (idx) < num_clusters;\
- (idx)++, (cluster) = &cluster_state[idx])
+ for (; (idx) < num_clusters && ((cluster) = &cluster_state[idx]);\
+ (idx)++)
static DEFINE_SPINLOCK(state_lock);
static void apply_need(struct cluster_data *state);