diff options
| author | Linux Build Service Account <lnxbuild@localhost> | 2016-05-24 08:45:05 -0600 |
|---|---|---|
| committer | Linux Build Service Account <lnxbuild@localhost> | 2016-05-24 08:45:06 -0600 |
| commit | 52b2ed5fccc94244dbf50f1d0879c213ff231c58 (patch) | |
| tree | fe34ec03ce24bf9bcc79a5b72db5df2b3f45a06d /kernel | |
| parent | 8c10ab37da3d535640c9b6ead17704106f66d139 (diff) | |
| parent | dfc289423d7a0c8303048165c696db7a75f12114 (diff) | |
Promotion of kernel.lnx.4.4-160520.
CRs Change ID Subject
--------------------------------------------------------------------------------------------------------------
996586 Ia4329ac982eb2a29a2b925897cd87ca9711c30e3 soundwire: Add support for 48x2 frame structure
1014388 Ia6484ed03d9508b827f8c7e4dadb84c14e306bd9 msm: gsi: fix for clearing IEOB interrupt
997751 I31b90d64c2facb0a681f9da586e2c90803776819 iommu/iommu-debug: Add debugfs file to enable config clo
1007465 I4f1b39dac949aa3f6aa3abb12ff0310fb0e98d1c swr-wcd-ctrl: Handle soundwire slave device ungroup
997751 I016937309ac8e16775d13e63b630bb98469c9fca defconfig: msm: Enable the "fast" IOMMU page table mappe
1017216 I8638814f7e06b0e63638c5acd268663d6a627718 defconfig: arm64: msm: Add defconfigs needed for data ca
1017735 Ib9b508591d28d22e7d5aa8f33d8d829d3378ccea ARM: dts: Add BIMC bandwidth monitor node for msmcobalt
1007465 Ic1653194c22fa5669b1c04fd9630158633fb00a5 swr-wcd-ctrl: Ensure soundwire banks are always in sync
997751 I58734a82f4dc3e4658ab7995b6682205097da991 iommu/iommu-debug: Add functional test for ARM DMA IOMMU
997751 I29d31e9649c24d30a5a7ffaa4b238a0203846594 iommu: Add domain attribute for getting page table info
1018309 Ie0c6639fff9b829a58e12037f88c6508864b60a0 msm: sde: Correct resource release upon rotator exit
1012226 Ifddcce1ff9cdbb35dc5645d0ed85963c18dec54e defconfig: msm: enable HBTP input drivers for cobalt
1018746 I4f812f280688984bd21fc68ae4d18355c9b2aac8 msm: defconfig: Enable camera
1018787 Ia140bfb2fcd699937cd845c4489458e5fefb5150 [media] v4l: Add qcom video color formats
997751 I9a73a31ee63a054cc44c50a21f7a616efd4af964 iommu/arm-smmu: Implement .get_pgsize_bitmap for domain
1018722 Ida9a93db8459d065ab7850de506e5b9124f6fdd4 msm: sde: Enable rotator r3 driver to support r3 minor v
1017735 I4efa37b8bb84ab62e82086b622896173b7d2fc7d defconfig: Enable DDR bus scaling governor
978785 I72fc29a8d7b286b0766c0483ba69d6e02d29b661 msm: mdss: Add newly supported writeback formats to MDP
997751 I46d70733be647599e148fe52258a4d8f009ac48a iommu: Support dynamic pgsize_bitmap
1017151 Idd7e7255ebc8a08f418289fa172c37f72a21ced0 msm: camera: cpp: Support conditional reset of micro
1018752 I30f1ee0f4fdb8d92a9f6e187c1d8b797a0bdc94d clk: msm: clock-alpha-pll: Fix incorrect fabia PLL setti
1018471 I41d6520eea1d4a5ef1ad002797cf2c8433078570 msm: defconfig: Enable CONFIG_QCOM_KGSL in msmcortex-per
997751 I95056952f60494fe5745f2183f9af8aab3a40315 iommu: Add {enable,disable}_config_clocks ops
997751 Idc3692679409093faf8f458d53326e669d7f6479 iommu/arm-smmu: Implement {enable,disable}_config_clocks
1007465 I358ab4edcb85ec65b064ca28368ad744f2d36870 ASoC: wsa881x: Request device ungroup for speaker disabl
1006303 Ie7a628d4bc77c9b6c769f6099ce8d75740262a14 sched: simplify CPU frequency estimation and cycle count
997751 I5adc3c3ecd432552386b600b9e66e3db42e73138 iommu/iommu-debug: Add file for profiling fast mapper
997751 Iba9f499dba89db91c1150947b9599d85ade65b0e iommu/arm-smmu: Implement the .tlbi_domain op
997751 Ia9f8ad6d924b294b6758970da2e9767f183b5649 iommu: Add DOMAIN_ATTR_FAST for requesting a fast domain
997751 I1236d9b6aaeab9d34b39e7f5d7b285691d1779da iommu/iommu-debug: Add file for profiling the fast DMA A
1015501 I0c6471549dfa7af435a5ce5f21a56caab1c4ea09 ARM: dts: msm: enable flash LED on cobalt
987962 I4e8e58626e5e8bd8468f3d216eadb2b326a84f75 msm: camera: isp: For testgen disable camif on frame bou
997751 Iebcafeb630d9023f666078604898069e9f26dfdd iommu: Add DMA mapper for io-pgtable-fast
997751 Icf9c1e41977cb71e8b137190adb3b4a201c339da iommu/io-pgtable-fast: Prove correctness of TLB maintena
987962 I6c4f8fd494b6206b0e1fae8ddfe9d7bc708723d2 msm: camera: isp: Set init rate for mnoc_maxi_clk
997751 I5861270709675016988052360d196e0a16a0d103 iommu/io-pgtable: Add fast page table mapper for ARMv8L
997751 I9ddd2dd2cad91ac3d3ccce7c0cd0abb37cd57075 iommu/arm-smmu: Wire up io-pgtable-fast for domains that
997751 If817f5514fdd5d24b9c592440760b81b88ec71a8 iommu: Add tlbi_domain op
1017735 I156ba6e2b5f8e06a28540ca5def5b178c3604512 PM / devfreq: Change the 'MSM' in devfreq device names t
997751 Id3acec0089b126e7d6ad44d8d322bf473614f716 iommu/arm-smmu: Implement DOMAIN_ATTR_PGTBL_INFO
997751 Ic5f890fda6b4fc8bb2dcd5e6ff49050d5a934c31 iommu/arm-smmu: Don't enable/disable clocks in inv_range
997751 Iefb80124c335d65ea5bd8a15406c685125030003 iommu/iommu-debug: Add functional tests for fast mapper
1007465 Ibca3e33c0e85629ae5ce121e75526f4786d6408a soundwire: Add API to ungroup soundwire slave devices
1017697 I6597746b87c0b7545401a4d51e07d3c8dbfd5906 defconfig: msmcortex: Enable watchdog bite on panic
1015501 I30618e6e4b983171d4a616a8a316c76f13ceee2d defconfig: msmcortex: enable qpnp flash
988356 Ie0f60ca79efc05901a88da13f7a6476f390518a5 clk: msm: clock-osm: register cycle counter callbacks wi
Change-Id: Idce34441199515c727ac882ad74826e6a0ae9fe4
CRs-Fixed: 1018722, 978785, 1012226, 1017151, 996586, 1018471, 1006303, 997751, 1018752, 1007465, 1017697, 1018746, 1015501, 1017735, 1018787, 1014388, 1018309, 988356, 987962, 1017216
Diffstat (limited to 'kernel')
| -rw-r--r-- | kernel/sched/core.c | 32 | ||||
| -rw-r--r-- | kernel/sched/sched.h | 12 |
2 files changed, 4 insertions, 40 deletions
diff --git a/kernel/sched/core.c b/kernel/sched/core.c index ac5f67da19b9..0b55bbbd7431 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c @@ -1403,7 +1403,6 @@ static struct sched_cluster init_cluster = { .max_mitigated_freq = UINT_MAX, .min_freq = 1, .max_possible_freq = 1, - .cpu_cycle_max_scale_factor = 1, .dstate = 0, .dstate_wakeup_energy = 0, .dstate_wakeup_latency = 0, @@ -1553,7 +1552,6 @@ static struct sched_cluster *alloc_new_cluster(const struct cpumask *cpus) cluster->max_mitigated_freq = UINT_MAX; cluster->min_freq = 1; cluster->max_possible_freq = 1; - cluster->cpu_cycle_max_scale_factor = 1; cluster->dstate = 0; cluster->dstate_wakeup_energy = 0; cluster->dstate_wakeup_latency = 0; @@ -1620,38 +1618,15 @@ static void init_clusters(void) INIT_LIST_HEAD(&cluster_head); } -static inline void -__update_cpu_cycle_max_possible_freq(struct sched_cluster *cluster) -{ - int cpu = cluster_first_cpu(cluster); - - cluster->cpu_cycle_max_scale_factor = - div64_u64(cluster->max_possible_freq * NSEC_PER_USEC, - cpu_cycle_counter_cb.get_cpu_cycles_max_per_us(cpu)); -} - -static inline void -update_cpu_cycle_max_possible_freq(struct sched_cluster *cluster) -{ - if (!use_cycle_counter) - return; - - __update_cpu_cycle_max_possible_freq(cluster); -} - int register_cpu_cycle_counter_cb(struct cpu_cycle_counter_cb *cb) { - struct sched_cluster *cluster = NULL; - mutex_lock(&cluster_lock); - if (!cb->get_cpu_cycle_counter || !cb->get_cpu_cycles_max_per_us) { + if (!cb->get_cpu_cycle_counter) { mutex_unlock(&cluster_lock); return -EINVAL; } cpu_cycle_counter_cb = *cb; - for_each_sched_cluster(cluster) - __update_cpu_cycle_max_possible_freq(cluster); use_cycle_counter = true; mutex_unlock(&cluster_lock); @@ -1931,8 +1906,7 @@ static inline u64 scale_exec_time(u64 delta, struct rq *rq, int cpu = cpu_of(rq); int sf; - delta = DIV64_U64_ROUNDUP(delta * cc->cycles * - cpu_cycle_max_scale_factor(cpu), + delta = DIV64_U64_ROUNDUP(delta * cc->cycles, max_possible_freq * cc->time); sf = DIV_ROUND_UP(cpu_efficiency(cpu) * 1024, max_possible_efficiency); @@ -2613,6 +2587,7 @@ get_task_cpu_cycles(struct task_struct *p, struct rq *rq, int event, cc.cycles = cur_cycles + (U64_MAX - p->cpu_cycles); else cc.cycles = cur_cycles - p->cpu_cycles; + cc.cycles = cc.cycles * NSEC_PER_MSEC; cc.time = wallclock - p->ravg.mark_start; BUG_ON((s64)cc.time < 0); @@ -3688,7 +3663,6 @@ static int cpufreq_notifier_policy(struct notifier_block *nb, sort_clusters(); update_all_clusters_stats(); - update_cpu_cycle_max_possible_freq(cluster); mutex_unlock(&cluster_lock); continue; } diff --git a/kernel/sched/sched.h b/kernel/sched/sched.h index 96f5c187dfcd..a66d8a12051c 100644 --- a/kernel/sched/sched.h +++ b/kernel/sched/sched.h @@ -389,11 +389,6 @@ struct sched_cluster { */ unsigned int cur_freq, max_freq, max_mitigated_freq, min_freq; unsigned int max_possible_freq; - /* - * cpu_cycle_max_scale_factor represents number of cycles per NSEC at - * CPU's fmax. - */ - u32 cpu_cycle_max_scale_factor; bool freq_init_done; int dstate, dstate_wakeup_latency, dstate_wakeup_energy; unsigned int static_cluster_pwr_cost; @@ -1137,14 +1132,9 @@ static inline int cpu_max_power_cost(int cpu) return cpu_rq(cpu)->cluster->max_power_cost; } -static inline int cpu_cycle_max_scale_factor(int cpu) -{ - return cpu_rq(cpu)->cluster->cpu_cycle_max_scale_factor; -} - static inline u32 cpu_cycles_to_freq(int cpu, u64 cycles, u32 period) { - return div64_u64(cycles * cpu_cycle_max_scale_factor(cpu), period); + return div64_u64(cycles, period); } static inline bool hmp_capable(void) |
