Commit Message

The commit is pushed to "branch-rh7-3.10.0-862.6.3.vz7.62.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-862.6.3.vz7.62.4
------>
commit e8d11b283ec87d45ea0101430ab226a6f7c34e19
Author: Kirill Tkhai <ktkhai@virtuozzo.com>
Date: Thu Jul 19 15:56:57 2018 +0300
sched: Call calc_load_ve() out of jiffies_lock
jiffies_lock is a big global seqlock, which is used in many
places. In combination with another actions like smp call
functions and readers of this seqlock, system may hang for
a long time. There is already a pair of hard lockups because
of long iteration in calc_load_ve() with jiffies_lock held,
which made readers of this seqlock to spin long time.
This patch makes calc_load_ve() to use separate lock,
and this relaxes jiffies_lock. I think, this should be enough
to resolve the problem, since both the crashes I saw contains
readers of the seqlock on parallel cpus, and we won't have
to relax further (say, moving calc_load_ve() to softirq).
Note, that the principal change of this patch makes is
jiffies_lock readers on parallel cpus won't wait till calc_load_ve()
finishes, so instead of (n_readers + 1) cpus waiting till
this function completes, there will be only 1 cpu doing that.
https://jira.sw.ru/browse/PSBM-84967
Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
=========================
Patchset description:
Make calc_load_ve() be executed out of jiffies_lock
https://jira.sw.ru/browse/PSBM-84967
Kirill Tkhai (3):
sched: Make calc_global_load() return true when it's need to update ve statistic
sched: Export calc_load_ve()
sched: Call calc_load_ve() out of jiffies_lock
---
kernel/sched/core.c | 13 ++++++++-----
kernel/time/tick-common.c | 8 +++++++-
kernel/time/tick-sched.c | 5 ++++-
kernel/time/timekeeping.c | 5 ++++-
4 files changed, 23 insertions(+), 8 deletions(-)