linux-uconsole/kernel/sched
Johannes Weiner cf46cf40bc UPSTREAM: psi: Fix a division error in psi poll()
The psi window size is a u64 an can be up to 10 seconds right now,
which exceeds the lower 32 bits of the variable. We currently use
div_u64 for it, which is meant only for 32-bit divisors. The result is
garbage pressure sampling values and even potential div0 crashes.

Use div64_u64.

Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Suren Baghdasaryan <surenb@google.com>
Cc: Jingfeng Xie <xiejingfeng@linux.alibaba.com>
Link: https://lkml.kernel.org/r/20191203183524.41378-3-hannes@cmpxchg.org
Signed-off-by: Sasha Levin <sashal@kernel.org>

(cherry picked from commit c3466952ca)

Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I49fdfd55751d1a2cde19666624c9c5d76dc78dad
2020-02-28 15:30:04 +00:00
..
autogroup.c ANDROID: sched/autogroup: Define autogroup_path() for !CONFIG_SCHED_DEBUG 2018-10-26 12:44:03 +01:00
autogroup.h sched/headers: Simplify and clean up header usage in the scheduler 2018-03-04 12:39:29 +01:00
clock.c sched/clock: Disable interrupts when calling generic_sched_clock_init() 2018-07-30 19:33:35 +02:00
completion.c sched/Documentation: Update wake_up() & co. memory-barrier guarantees 2018-07-17 09:30:34 +02:00
core.c ANDROID: Re-use SUGOV_RT_MAX_FREQ to control uclamp rt behavior 2020-02-01 16:14:12 +00:00
cpuacct.c sched/headers: Simplify and clean up header usage in the scheduler 2018-03-04 12:39:29 +01:00
cpudeadline.c sched/headers: Simplify and clean up header usage in the scheduler 2018-03-04 12:39:29 +01:00
cpudeadline.h sched/headers: Simplify and clean up header usage in the scheduler 2018-03-04 12:39:29 +01:00
cpufreq.c cpufreq: Avoid leaving stale IRQ work items during CPU offline 2019-12-31 16:36:22 +01:00
cpufreq_schedutil.c ANDROID: Re-use SUGOV_RT_MAX_FREQ to control uclamp rt behavior 2020-02-01 16:14:12 +00:00
cpupri.c BACKPORT: sched/rt: Make RT capacity-aware 2020-02-01 15:03:16 +00:00
cpupri.h BACKPORT: sched/rt: Make RT capacity-aware 2020-02-01 15:03:16 +00:00
cputime.c This is the 4.19.82 stable release 2019-11-06 13:21:58 +01:00
deadline.c This is the 4.19.77 stable release 2019-10-06 11:27:45 +02:00
debug.c jump_label: move 'asm goto' support test to Kconfig 2019-06-04 08:02:34 +02:00
fair.c This is the 4.19.101 stable release 2020-02-02 20:22:38 +00:00
features.h UPSTREAM: sched/fair/util_est: Implement faster ramp-up EWMA on utilization increases 2020-02-01 17:35:00 +00:00
idle.c This is the 4.19.77 stable release 2019-10-06 11:27:45 +02:00
isolation.c sched/headers: Simplify and clean up header usage in the scheduler 2018-03-04 12:39:29 +01:00
loadavg.c UPSTREAM: sched: loadavg: make calc_load_n() public 2019-03-21 16:25:27 -07:00
Makefile UPSTREAM: psi: pressure stall information for CPU, memory, and IO 2019-03-21 16:25:27 -07:00
membarrier.c sched/membarrier: Fix private expedited registration check 2019-10-11 18:21:22 +02:00
pelt.c UPSTREAM: sched/fair: Update scale invariance of PELT 2019-03-26 14:22:50 +00:00
pelt.h UPSTREAM: sched/fair: Update scale invariance of PELT 2019-03-26 14:22:50 +00:00
psi.c UPSTREAM: psi: Fix a division error in psi poll() 2020-02-28 15:30:04 +00:00
rt.c BACKPORT: sched/rt: Make RT capacity-aware 2020-02-01 15:03:16 +00:00
sched-pelt.h sched/fair: Fix "runnable_avg_yN_inv" not used warnings 2019-07-26 09:14:08 +02:00
sched.h ANDROID: sched/core: Move SchedTune task API into UtilClamp wrappers 2020-02-01 16:14:11 +00:00
stats.c proc: introduce proc_create_seq{,_data} 2018-05-16 07:23:35 +02:00
stats.h UPSTREAM: psi: make disabling/enabling easier for vendor kernels 2019-03-21 16:25:27 -07:00
stop_task.c FROMLIST: sched/fair: Use wake_q length as a hint for wake_wide 2018-10-26 12:15:52 +01:00
swait.c sched/swait: Rename to exclusive 2018-06-20 11:35:56 +02:00
topology.c UPSTREAM: sched/topology: Introduce a sysctl for Energy Aware Scheduling 2020-02-19 10:50:59 +00:00
tune.c ANDROID: increase limit on sched-tune boost groups 2020-02-26 21:55:29 +00:00
tune.h ANDROID: sched/tune: Move SchedTune cpu API into UtilClamp wrappers 2020-02-01 15:03:17 +00:00
wait.c sched/wait: assert the wait_queue_head lock is held in __wake_up_common 2018-08-22 10:52:47 -07:00
wait_bit.c sched/wait: Improve __var_waitqueue() code generation 2018-03-20 08:23:25 +01:00