On Thu, Apr 15, 2021 at 03:20:57PM -0700, Sean Christopherson wrote:
> This is a continuation of Wanpeng's series[1] to fix tick-based CPU time
> accounting on x86, with my cleanups[2] bolted on top. The core premise of
> Wanpeng's patches are preserved, but they are heavily stripped down.
>
On Thu, Apr 15, 2021 at 03:21:00PM -0700, Sean Christopherson wrote:
> From: Wanpeng Li
>
> When using tick-based accounting, defer the call to account guest time
> until after servicing any IRQ(s) that happened in the guest or
> immediately after VM-Exit. Tick-based accounting of vCPU time
On Sat, Apr 17, 2021 at 09:46:16PM -0700, Paul E. McKenney wrote:
> On Sat, Apr 17, 2021 at 03:16:49PM +0200, Frederic Weisbecker wrote:
> > On Wed, Apr 14, 2021 at 08:55:38AM -0700, Paul E. McKenney wrote:
> > > > diff --git a/kernel/rcu/rcu.h b/kernel/rcu/rcu.h
>
cu_init_geometry()'s
> instructions (maybe we are?), then rcu_init_geometry() can be split
> into a function that just does the check (which is not __init) and the
> remainder of the function, which could remain __init.
There you go:
---
From: Frederic Weisbecker
Date: Wed, 31 Mar 2021 1
On Wed, Apr 14, 2021 at 08:55:38AM -0700, Paul E. McKenney wrote:
> On Wed, Apr 14, 2021 at 03:24:12PM +0200, Frederic Weisbecker wrote:
> > diff --git a/kernel/rcu/rcu.h b/kernel/rcu/rcu.h
> > index 75ed367d5b60..24db97cbf76b 100644
> > --- a/kernel/rcu/rcu.h
>
-off-by: Frederic Weisbecker
Cc: Boqun Feng
Cc: Lai Jiangshan
Cc: Neeraj Upadhyay
Cc: Josh Triplett
Cc: Joel Fernandes
Cc: Uladzislau Rezki
---
kernel/rcu/update.c | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/kernel/rcu/update.c b/kernel/rcu/update.c
index
rcu_init(). This way we make sure the
RCU nodes hierarchy is properly built and distributed before the nodes
of a struct srcu_state are allocated.
Suggested-by: Paul E. McKenney
Signed-off-by: Frederic Weisbecker
Cc: Boqun Feng
Cc: Lai Jiangshan
Cc: Neeraj Upadhyay
Cc: Josh Triplett
Cc: Joel Fer
Hi,
Another approach, suggested offlist by Paul. Much more
simple and maintainable. Enjoy!
git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks.git
rcu/dev-v3
HEAD: bd6cef5d990e47a523027aea95f80537644af55e
Thanks,
Frederic
---
Frederic Weisbecker (2
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: d3ad5bbc4da70c25ad6b386e038e711d0755767b
Gitweb:
https://git.kernel.org/tip/d3ad5bbc4da70c25ad6b386e038e711d0755767b
Author:Frederic Weisbecker
AuthorDate:Wed, 06 Jan 2021 23:07:15 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: b2fcf2102049f6e56981e0ab3d9b633b8e2741da
Gitweb:
https://git.kernel.org/tip/b2fcf2102049f6e56981e0ab3d9b633b8e2741da
Author:Frederic Weisbecker
AuthorDate:Tue, 23 Feb 2021 01:09:59 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 3820b513a2e33d6dee1caa3b4815f92079cb9890
Gitweb:
https://git.kernel.org/tip/3820b513a2e33d6dee1caa3b4815f92079cb9890
Author:Frederic Weisbecker
AuthorDate:Thu, 12 Nov 2020 01:51:21 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 5de2e5bb80aeef82f75fff76120874cdc86f935d
Gitweb:
https://git.kernel.org/tip/5de2e5bb80aeef82f75fff76120874cdc86f935d
Author:Frederic Weisbecker
AuthorDate:Thu, 28 Jan 2021 18:12:08 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 8a682b3974c36853b52fc8ede14dee966e96e19f
Gitweb:
https://git.kernel.org/tip/8a682b3974c36853b52fc8ede14dee966e96e19f
Author:Frederic Weisbecker
AuthorDate:Thu, 28 Jan 2021 18:12:12 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 64305db2856b969a5d48e8f3a5b0d06b5594591c
Gitweb:
https://git.kernel.org/tip/64305db2856b969a5d48e8f3a5b0d06b5594591c
Author:Frederic Weisbecker
AuthorDate:Thu, 28 Jan 2021 18:12:09 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 55adc3e1c82a25e99e9efef4f2b14b8b4806918a
Gitweb:
https://git.kernel.org/tip/55adc3e1c82a25e99e9efef4f2b14b8b4806918a
Author:Frederic Weisbecker
AuthorDate:Thu, 28 Jan 2021 18:12:13 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: ec711bc12c777b1165585f59f7a6c35a89e04cc3
Gitweb:
https://git.kernel.org/tip/ec711bc12c777b1165585f59f7a6c35a89e04cc3
Author:Frederic Weisbecker
AuthorDate:Thu, 28 Jan 2021 18:12:10 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 76d00b494d7962e88d4bbd4135f34aba9019c67f
Gitweb:
https://git.kernel.org/tip/76d00b494d7962e88d4bbd4135f34aba9019c67f
Author:Frederic Weisbecker
AuthorDate:Tue, 23 Feb 2021 01:10:00 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 0efdf14a9f83618335a0849df3586808bff36cfb
Gitweb:
https://git.kernel.org/tip/0efdf14a9f83618335a0849df3586808bff36cfb
Author:Frederic Weisbecker
AuthorDate:Tue, 23 Feb 2021 01:10:01 +01:00
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: e02691b7ef51c5fac0eee5a6ebde45ce92958fae
Gitweb:
https://git.kernel.org/tip/e02691b7ef51c5fac0eee5a6ebde45ce92958fae
Author:Frederic Weisbecker
AuthorDate:Tue, 23 Feb 2021 01:10:02 +01:00
but early calls to
start_poll_synchronize_srcu() involve empty callbacks.
Signed-off-by: Frederic Weisbecker
Cc: Boqun Feng
Cc: Lai Jiangshan
Cc: Neeraj Upadhyay
Cc: Josh Triplett
Cc: Joel Fernandes
Cc: Uladzislau Rezki
---
kernel/rcu/update.c | 12 +++-
1 file changed, 11 insertions
grace period so there is no need to queue empty callbacks beyond the
second call.
Suggested-by: Paul E . McKenney
Signed-off-by: Frederic Weisbecker
Cc: Boqun Feng
Cc: Lai Jiangshan
Cc: Neeraj Upadhyay
Cc: Josh Triplett
Cc: Joel Fernandes
Cc: Uladzislau Rezki
---
include/linux/srcutree.h
early initialized ssp's. Queued
callbacks are saved then requeued once the ssp reset is done.
Suggested-by: Paul E . McKenney
Signed-off-by: Frederic Weisbecker
Cc: Boqun Feng
Cc: Lai Jiangshan
Cc: Neeraj Upadhyay
Cc: Josh Triplett
Cc: Joel Fernandes
Cc: Uladzislau Rezki
---
include/linux
mode until everything is well settled.
Signed-off-by: Frederic Weisbecker
Cc: Uladzislau Rezki
Cc: Boqun Feng
Cc: Lai Jiangshan
Cc: Neeraj Upadhyay
Cc: Josh Triplett
Cc: Joel Fernandes
---
include/linux/srcu.h | 6 ++
init/main.c | 2 ++
kernel/rcu/rcu.h | 6 --
kernel
struct lockdep_map is empty when CONFIG_DEBUG_LOCK_ALLOC=n. We can
remove the ifdeffery while adding the lockdep map in struct srcu_struct
without risking consuming space in the off-case. This will also simplify
further manipulations on this field.
Signed-off-by: Frederic Weisbecker
Cc
: 0dc3551822c74a0f34783cbd64a9199c9758ec6d
Thanks,
Frederic
---
Frederic Weisbecker (5):
srcu: Unconditionally embed struct lockdep_map
srcu: Initialize SRCU after timers
srcu: Fix broken node geometry after early ssp init
srcu: Queue a callback in case of early started poll
On Wed, Apr 07, 2021 at 10:53:01AM -0300, Marcelo Tosatti wrote:
>
> Setting the realtime clock triggers an IPI to all CPUs to reprogram
> hrtimers.
>
> However, only base, boottime and tai clocks have their offsets updated
> (and therefore potentially require a reprogram).
>
> If the CPU is a
The 3 diagrams describing rcu_gp_init() all spuriously refer to the same
figure, probably due to some copy/paste issue. Fix the references.
Signed-off-by: Frederic Weisbecker
---
.../RCU/Design/Memory-Ordering/Tree-RCU-Memory-Ordering.rst | 4 ++--
1 file changed, 2 insertions(+), 2 deletions
On Fri, Apr 02, 2021 at 08:03:57AM -0700, Paul E. McKenney wrote:
> On Fri, Apr 02, 2021 at 12:02:21PM +0200, Frederic Weisbecker wrote:
> > Arguably that's a quite a corner case and I don't expect anyone to call
> > start_poll_synchronize_srcu() so early but who knows.
On Thu, Apr 01, 2021 at 06:12:41PM -0700, Paul E. McKenney wrote:
> On Fri, Apr 02, 2021 at 01:47:04AM +0200, Frederic Weisbecker wrote:
gg> > void __init srcu_init(void)
> > {
> > - struct srcu_struct *ssp;
> > + static struct srcu_data __initdata old_sdp;
>
On Thu, Apr 01, 2021 at 05:48:56PM -0700, Paul E. McKenney wrote:
> On Fri, Apr 02, 2021 at 01:47:02AM +0200, Frederic Weisbecker wrote:
> > When an ssp has already started a grace period and queued an early work
> > to flush after SRCU workqueues are created, we expect the ssp to
alloc_percpu() zeroes out the allocated memory. Therefore we can assume
the whole struct srcu_data to be clear after calling it, just like after
a static initialization. No need for a special treatment in the dynamic
allocation case.
Signed-off-by: Frederic Weisbecker
Cc: Boqun Feng
Cc: Lai
. Unfortunately this involves a new
field into struct srcu_struct to postpone the ssp hierarchy rebuild.
Signed-off-by: Frederic Weisbecker
Cc: Boqun Feng
Cc: Lai Jiangshan
Cc: Neeraj Upadhyay
Cc: Josh Triplett
Cc: Joel Fernandes
Cc: Uladzislau Rezki
---
include/linux/srcutre
When an ssp has already started a grace period and queued an early work
to flush after SRCU workqueues are created, we expect the ssp to be
properly initialized already. So we can skip this step at this stage.
Signed-off-by: Frederic Weisbecker
Cc: Boqun Feng
Cc: Lai Jiangshan
Cc: Neeraj
nticks.git
rcu/dev
HEAD: 6390b2aa1295f79150fac8f5ff60177eea5d8f8b
Thanks,
Frederic
---
Frederic Weisbecker (3):
srcu: Remove superfluous ssp initialization on deferred work queue
srcu: Remove superfluous sdp->srcu_lock_count zero filling
srcu: Fix broken node geometr
On Thu, Apr 01, 2021 at 03:33:29PM -0700, Paul E. McKenney wrote:
> On Thu, Apr 01, 2021 at 11:08:02PM +0200, Frederic Weisbecker wrote:
> How about like this? I put this only in kvm.sh for the moment, but
> if these keep cropping up I will just hit all the scripts. ;-)
Sure, wor
On Thu, Apr 01, 2021 at 02:02:53PM -0700, Paul E. McKenney wrote:
> On Thu, Apr 01, 2021 at 10:41:13PM +0200, Frederic Weisbecker wrote:
> > On Thu, Apr 01, 2021 at 01:40:22PM -0700, Paul E. McKenney wrote:
> > > On Thu, Apr 01, 2021 at 10:31:12PM +0200, Frederic Weisbecker wro
On Thu, Apr 01, 2021 at 01:40:22PM -0700, Paul E. McKenney wrote:
> On Thu, Apr 01, 2021 at 10:31:12PM +0200, Frederic Weisbecker wrote:
> > On Thu, Apr 01, 2021 at 11:51:16AM -0700, Paul E. McKenney wrote:
> > > On Thu, Apr 01, 2021 at 03:26:02PM +0200, Frederic Weisbecker wrote
On Thu, Apr 01, 2021 at 11:51:16AM -0700, Paul E. McKenney wrote:
> On Thu, Apr 01, 2021 at 03:26:02PM +0200, Frederic Weisbecker wrote:
> > Grepping for "CPU" on lscpu output isn't always successful, depending
> > on the local language setting. As a result, the build
Grepping for "CPU" on lscpu output isn't always successful, depending
on the local language setting. As a result, the build can be aborted
early with:
"make: the '-j' option requires a positive integer argument"
Prefer a more generic solution.
Signed-off-by:
On Tue, Mar 16, 2021 at 04:08:08PM +, Zhou Ti (x2019cwm) wrote:
> But I don't think it's a good idea to handle this in callers, because
> logically the function shouldn't return negative values. Returning 0 directly
> would allow idle governors to get another chance to select again.
Hmm,
On Tue, Mar 16, 2021 at 04:27:56PM +0100, Peter Zijlstra wrote:
> On Thu, Mar 11, 2021 at 01:37:04PM +0100, Frederic Weisbecker wrote:
> > Enqueuing a local timer after the tick has been stopped will result in
> > the timer being ignored until the next random interrupt.
> >
On Mon, Mar 22, 2021 at 12:45:22PM -0700, Paul E. McKenney wrote:
> On Mon, Mar 22, 2021 at 08:00:35PM +0100, Frederic Weisbecker wrote:
> > But poll_state_synchronize_rcu() checks that the gp_num has changed,
> > which is not needed for cond_synchronize_rcu() since this it is
&
On Mon, Mar 22, 2021 at 08:47:44AM -0700, Paul E. McKenney wrote:
> On Sun, Mar 21, 2021 at 11:28:55PM +0100, Frederic Weisbecker wrote:
> > On Wed, Mar 03, 2021 at 04:26:31PM -0800, paul...@kernel.org wrote:
> > > From: "Paul E. McKenney"
> > >
> > &
On Wed, Mar 03, 2021 at 04:26:31PM -0800, paul...@kernel.org wrote:
> From: "Paul E. McKenney"
>
> There is a need for a non-blocking polling interface for RCU grace
> periods, so this commit supplies start_poll_synchronize_rcu() and
> poll_state_synchronize_rcu() for this purpose. Note that
On Fri, Mar 19, 2021 at 04:38:48PM -0700, Paul E. McKenney wrote:
> > I didn't even think that far.
> > My scenario was:
> >
> > 1. cookie = start_poll_synchronize_rcu()
> >
> >
> > 2. cond_synchronize_rcu() checks the cookie and sees that the
> > grace period has not yet expired. So it
On Fri, Mar 19, 2021 at 10:51:16AM -0700, Paul E. McKenney wrote:
> On Fri, Mar 19, 2021 at 02:58:54PM +0100, Frederic Weisbecker wrote:
> > It's all a matter of personal taste but if I may suggest some namespace
> > modifications:
> >
> >
has elapsed since the earlier call from
> + * which oldstate was obtained, return @true, otherwise return @false.
> + * Otherwise, invoke synchronize_rcu() to wait for a full grace period.
Rephrase suggestion for the last sentence:
"In case of failure, it's up to the caller to try polling again later or
invoke synchronize_rcu() to wait for a new full grace period to complete."
In any case: Reviewed-by: Frederic Weisbecker
Thanks!
On Tue, Mar 16, 2021 at 09:51:01AM -0700, Paul E. McKenney wrote:
> On Tue, Mar 16, 2021 at 04:17:50PM +0100, Frederic Weisbecker wrote:
> > On Wed, Mar 03, 2021 at 04:26:30PM -0800, paul...@kernel.org wrote:
> > > +/**
> > > + * poll_state_synchronize_rcu - Conditio
On Wed, Mar 03, 2021 at 04:26:30PM -0800, paul...@kernel.org wrote:
> +/**
> + * poll_state_synchronize_rcu - Conditionally wait for an RCU grace period
> + *
> + * @oldstate: return from call to get_state_synchronize_rcu() or
> start_poll_synchronize_rcu()
> + *
> + * If a full RCU grace period
On Tue, Mar 16, 2021 at 03:35:37PM +0100, Peter Zijlstra wrote:
> On Tue, Mar 16, 2021 at 02:37:03PM +0100, Frederic Weisbecker wrote:
> > On Tue, Mar 16, 2021 at 01:21:29PM +0100, Peter Zijlstra wrote:
> > > On Thu, Mar 11, 2021 at 01:36:59PM +0100, Frederic Weisbecker wrote:
&
On Wed, Mar 03, 2021 at 04:26:30PM -0800, paul...@kernel.org wrote:
> +/**
> + * poll_state_synchronize_rcu - Conditionally wait for an RCU grace period
> + *
> + * @oldstate: return from call to get_state_synchronize_rcu() or
> start_poll_synchronize_rcu()
> + *
> + * If a full RCU grace period
On Tue, Mar 16, 2021 at 01:21:29PM +0100, Peter Zijlstra wrote:
> On Thu, Mar 11, 2021 at 01:36:59PM +0100, Frederic Weisbecker wrote:
> > From: "Zhou Ti (x2019cwm)"
> >
> > If the hardware clock happens to fire its interrupts late, two possible
>
On Tue, Mar 16, 2021 at 01:28:01PM +0100, Peter Zijlstra wrote:
> On Thu, Mar 11, 2021 at 01:37:00PM +0100, Frederic Weisbecker wrote:
> > Optimize further the check for local full dynticks CPU. Testing directly
> > tick_nohz_full_cpu(smp_processor_id()) is suboptimal because t
On Mon, Mar 15, 2021 at 08:02:39PM -0700, Paul E. McKenney wrote:
> On Tue, Feb 23, 2021 at 01:10:10AM +0100, Frederic Weisbecker wrote:
> > Provide a way to tune the deferred wakeup level we want to perform from
> > a safe wakeup point. Currently those sites are:
> >
> &
On Mon, Mar 15, 2021 at 10:53:36PM +0800, Boqun Feng wrote:
> On Wed, Mar 10, 2021 at 11:17:02PM +0100, Frederic Weisbecker wrote:
> > On Tue, Mar 02, 2021 at 05:24:56PM -0800, Paul E. McKenney wrote:
> > > On Tue, Feb 23, 2021 at 01:10:08AM +0100, Frederic Weisbecker wrote:
>
On Wed, Mar 03, 2021 at 04:26:30PM -0800, paul...@kernel.org wrote:
> /**
> + * start_poll_state_synchronize_rcu - Snapshot and start RCU grace period
> + *
> + * Returns a cookie that is used by a later call to cond_synchronize_rcu()
> + * or poll_state_synchronize_rcu() to determine whether or
On Wed, Mar 03, 2021 at 04:26:30PM -0800, paul...@kernel.org wrote:
> From: "Paul E. McKenney"
>
> There is a need for a non-blocking polling interface for RCU grace
> periods, so this commit supplies start_poll_synchronize_rcu() and
> poll_state_synchronize_rcu() for this purpose. Note that
rq processing when ksoftirqd does not
> yet exist. With this change, the above test passes.
>
> Reported-by: Sebastian Andrzej Siewior
> Reported-by: Uladzislau Rezki
> Cc: Peter Zijlstra
> Cc: Thomas Gleixner
> [ paulmck: Remove unneeded check per Sebastian Siewior feedback. ]
> Signed-off-by: Paul E. McKenney
Reviewed-by: Frederic Weisbecker
On Wed, Mar 03, 2021 at 04:00:16PM -0800, paul...@kernel.org wrote:
> From: "Paul E. McKenney"
>
> After interrupts have enabled at boot but before some random point
> in early_initcall() processing, softirq processing is unreliable.
> If softirq sees a need to push softirq-handler invocation to
we never
deactivate a task while it is running, the only exception being the task
deactivating itself while scheduling out.
Suggested-by: Peter Zijlstra
Signed-off-by: Marcelo Tosatti
Cc: Yunfeng Ye
Cc: Thomas Gleixner
Cc: Rafael J. Wysocki
Signed-off-by: Frederic Weisbecker
---
include/linu
Signed-off-by: Frederic Weisbecker
---
include/linux/tick.h | 8
kernel/time/posix-cpu-timers.c | 4 ++--
kernel/time/tick-sched.c | 15 +--
3 files changed, 19 insertions(+), 8 deletions(-)
diff --git a/include/linux/tick.h b/include/linux/tick.h
index
cpu and task->tick_dep_mask.
Suggested-by: Peter Zijlstra
Signed-off-by: Frederic Weisbecker
Cc: Yunfeng Ye
Cc: Thomas Gleixner
Cc: Rafael J. Wysocki
Signed-off-by: Marcelo Tosatti
---
kernel/time/tick-sched.c | 40 +++-
1 file changed, 27 insertions(
Enqueuing a local timer after the tick has been stopped will result in
the timer being ignored until the next random interrupt.
Perform sanity checks to report these situations.
Reviewed-by: Rafael J. Wysocki
Signed-off-by: Frederic Weisbecker
Cc: Peter Zijlstra
Cc: Thomas Gleixner
Cc: Ingo
tra
Cc: Thomas Gleixner
Cc: Marcelo Tosatti
Cc: Rafael J. Wysocki
Signed-off-by: Frederic Weisbecker
---
kernel/time/tick-sched.c | 14 --
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c
index c86b586d65e0..2a041d0dc
CONFIG_NO_HZ_FULL behaves just like CONFIG_NO_HZ_IDLE by default.
Reassure distros about it.
Signed-off-by: Frederic Weisbecker
Cc: Yunfeng Ye
Cc: Peter Zijlstra
Cc: Thomas Gleixner
Cc: Marcelo Tosatti
Cc: Rafael J. Wysocki
---
kernel/time/Kconfig | 11 ++-
1 file changed, 6
The vtime_accounting_enabled_this_cpu() early check already makes what
follows as dead code in the case of CONFIG_VIRT_CPU_ACCOUNTING_NATIVE.
No need to keep the ifdeferry around.
Signed-off-by: Frederic Weisbecker
Cc: Yunfeng Ye
Cc: Peter Zijlstra
Cc: Thomas Gleixner
Cc: Marcelo Tosatti
Cc
er
Signed-off-by: Frederic Weisbecker
---
kernel/time/tick-sched.c | 6 ++
1 file changed, 6 insertions(+)
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c
index e10a4af88737..22b6a46818cf 100644
--- a/kernel/time/tick-sched.c
+++ b/kernel/time/tick-sched.c
@@ -1142,6 +1142,9
rs/nohz
HEAD: e469edfa00f97e5ec5d31fe31d3aef0a5c9bd607
Thanks,
Frederic
---
Frederic Weisbecker (5):
tick/nohz: Add tick_nohz_full_this_cpu()
tick/nohz: Remove superflous check for CONFIG_VIRT_CPU_ACCOUNTING_NATIVE
timer: Report ignored local enqueue in nohz mode
tick/nohz: Upd
on idle exit when it's strictly
necessary.
Signed-off-by: Yunfeng Ye
Cc: Peter Zijlstra
Cc: Thomas Gleixner
Cc: Marcelo Tosatti
Cc: Rafael J. Wysocki
Signed-off-by: Frederic Weisbecker
---
kernel/time/tick-sched.c | 50
1 file changed, 30 insertions
that handles that correctly and convert some users along.
Signed-off-by: Frederic Weisbecker
Cc: Yunfeng Ye
Cc: Peter Zijlstra
Cc: Thomas Gleixner
Cc: Marcelo Tosatti
Cc: Rafael J. Wysocki
---
include/linux/tick.h | 11 ++-
kernel/time/tick-sched.c | 12 +---
2 files
On Tue, Mar 02, 2021 at 05:24:56PM -0800, Paul E. McKenney wrote:
> On Tue, Feb 23, 2021 at 01:10:08AM +0100, Frederic Weisbecker wrote:
> > A NOCB-gp wake up can safely delete the nocb_bypass_timer. nocb_gp_wait()
> > is going to check again the bypass state and rearm t
On Tue, Mar 02, 2021 at 05:22:29PM -0800, Paul E. McKenney wrote:
> On Tue, Feb 23, 2021 at 01:10:09AM +0100, Frederic Weisbecker wrote:
> > No need to disarm the nocb_timer if rcu_nocb is polling because it
> > shouldn't be armed either.
> >
> > Signed-off-by: Freder
On Tue, Mar 02, 2021 at 05:15:57PM -0800, Paul E. McKenney wrote:
> The first question is of course: Did you try this with lockdep enabled? ;-)
Yep I always do. But I may miss some configs on my testings. I usually
test at least TREE01 on x86 and arm64.
> > @@ -1702,43 +1692,50 @@ bool
-off-by: Thomas Gleixner
> Tested-by: Sebastian Andrzej Siewior
> Reviewed-by: Paul E. McKenney
Reviewed-by: Frederic Weisbecker
b9e65158ef1cb2bb94372 Mon Sep 17 00:00:00 2001
From: Frederic Weisbecker
Date: Fri, 8 Jan 2021 13:50:12 +0100
Subject: [PATCH] timer: Report ignored local enqueue in nohz mode
Enqueuing a local timer after the tick has been stopped will result in
the timer being ignored until the next random inter
On Tue, Mar 02, 2021 at 06:06:43PM -0800, Paul E. McKenney wrote:
> On Wed, Mar 03, 2021 at 02:35:33AM +0100, Frederic Weisbecker wrote:
> > On Tue, Mar 02, 2021 at 10:17:29AM -0800, Paul E. McKenney wrote:
> > > On Tue, Mar 02, 2021 at 01:34:44PM +0100, Frederic Weisbecker wrot
On Tue, Mar 02, 2021 at 10:17:29AM -0800, Paul E. McKenney wrote:
> On Tue, Mar 02, 2021 at 01:34:44PM +0100, Frederic Weisbecker wrote:
>
> OK, how about if I queue a temporary commit (shown below) that just
> calls out the first scenario so that I can start testing, and you get
>
On Mon, Mar 01, 2021 at 05:48:29PM -0800, Paul E. McKenney wrote:
> On Wed, Feb 24, 2021 at 11:06:06PM +0100, Frederic Weisbecker wrote:
> > On Wed, Feb 24, 2021 at 10:37:09AM -0800, Paul E. McKenney wrote:
> > > On Tue, Feb 23, 2021 at 01:09:59AM +0100, Frederic Weisbecker
On Wed, Feb 24, 2021 at 04:14:25PM -0800, Paul E. McKenney wrote:
> On Wed, Feb 24, 2021 at 11:06:06PM +0100, Frederic Weisbecker wrote:
> > I managed to recollect some pieces of my brain. So keep the above but
> > let's change the point 10:
> >
> > 10. CPU 0 e
On Wed, Feb 24, 2021 at 10:37:09AM -0800, Paul E. McKenney wrote:
> On Tue, Feb 23, 2021 at 01:09:59AM +0100, Frederic Weisbecker wrote:
> > Two situations can cause a missed nocb timer rearm:
> >
> > 1) rdp(CPU A) queues its nocb timer. The grace period elapses before
-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc: Neeraj Upadhyay
Cc: Boqun Feng
---
kernel/rcu/tree.c| 2 +-
kernel/rcu/tree.h| 2 +-
kernel/rcu/tree_plugin.h | 15 ---
3 files changed, 10 insertions(+), 9 deletions(-)
diff --git a/kernel
shouldn't bring visible overhead since the
timers almost never fire.
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc: Neeraj Upadhyay
Cc: Boqun Feng
---
include/trace/events/rcu.h | 1 +
kernel/rcu/tree.h | 6 +--
kernel/rcu/tree_plugin.h
As we wake up in nocb_gp_wait(), there is no need to keep the nocb_timer
around as we are going to go through the whole rdp list again. Any update
performed before the timer was armed will now be visible after the
nocb_gp_lock acquire.
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc
A NOCB-gp wake up can safely delete the nocb_bypass_timer. nocb_gp_wait()
is going to check again the bypass state and rearm the bypass timer if
necessary.
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc: Neeraj Upadhyay
Cc: Boqun Feng
No need to disarm the nocb_timer if rcu_nocb is polling because it
shouldn't be armed either.
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc: Neeraj Upadhyay
Cc: Boqun Feng
---
kernel/rcu/tree_plugin.h | 14 +++---
1 file changed, 7
can be for any rdp from the group and not
necessarily the rdp leader on which the bypass timer is attached.
Therefore we can simply call directly __wake_nocb_gp(). This way we
don't even need to lock the nocb_lock.
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: J
ter though because we only need
the guarantee to see the timer armed if we were the last one to arm it.
Any other situation (another rdp has armed it and we either see it or not)
is fine.
This solves all the issues listed above.
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
: Neeraj Upadhyay
Cc: Boqun Feng
Signed-off-by: Frederic Weisbecker
---
kernel/rcu/tree_plugin.h | 4
1 file changed, 4 deletions(-)
diff --git a/kernel/rcu/tree_plugin.h b/kernel/rcu/tree_plugin.h
index c80b214a86bb..0fdf0223f08f 100644
--- a/kernel/rcu/tree_plugin.h
+++ b/kernel/rcu
Those tracing calls don't need to be under the nocb lock. Move them
outside.
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc: Neeraj Upadhyay
Cc: Boqun Feng
---
kernel/rcu/tree_plugin.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions
Remove stale comment claiming that the cblist must be empty before
changing the offloading state. This applied when the offloaded state was
defined exclusively on boot.
Reported-by: Paul E. McKenney
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc
This reverts commit dcd42591ebb8a25895b551a5297ea9c24414ba54.
The only user was RCU/nocb.
Signed-off-by: Frederic Weisbecker
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc: Neeraj Upadhyay
Cc: Boqun Feng
Cc: Thomas Gleixner
---
include/linux/timer.h | 2 --
kernel/time/timer.c
otic behaviour.
Fix this with resetting rdp->nocb_defer_wakeup everytime we disarm the
timer.
Fixes: d1b222c6be1f (rcu/nocb: Add bypass callback queueing)
Cc: Stable
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc: Neeraj Upadhyay
Cc: Boqun Feng
Signed-off-by: Frederic Weisbecker
---
k
, only enable bypass once we safely complete the offloading
process.
Reported-by: Paul E. McKenney
Cc: Josh Triplett
Cc: Lai Jiangshan
Cc: Joel Fernandes
Cc: Neeraj Upadhyay
Cc: Boqun Feng
Signed-off-by: Frederic Weisbecker
---
include/linux/rcu_segcblist.h | 7 ---
kernel/rcu/tree_plugin.h
t;timer: Add timer_curr_running()""
* New patch
git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks.git
rcu/dev-v2
HEAD: 925ee3076eb694db893e2c6664d90ad8fb9cb6e5
Thanks,
Frederic
---
Frederic Weisbecker (13):
rcu/nocb: Fix potential missed noc
ll_update_tick
tick_nohz_restart_sched_tick
ts->idle_exittime = now;
It's thus overwritten by mistake on nohz_full tick restart. Move the
update to the appropriate idle exit path instead.
Signed-off-by: Yunfeng Ye
Signed-off-by: Frederic Weisbecker
---
kernel/time/tick-sched.c
sary.
Signed-off-by: Yunfeng Ye
Signed-off-by: Frederic Weisbecker
---
kernel/time/tick-sched.c | 44
1 file changed, 27 insertions(+), 17 deletions(-)
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c
index 3e272490fe2e..79796286a4ba 100
expires past the last idle entry time.
Make sure that both cases are handled to avoid returning a negative
duration to the cpuidle governors.
Signed-off-by: Ti Zhou
Signed-off-by: Frederic Weisbecker
---
kernel/time/tick-sched.c | 6 ++
1 file changed, 6 insertions(+)
diff --git a/kernel/ti
The following commit has been merged into the sched/core branch of tip:
Commit-ID: 29fd01944b7273bb630c649a2104b7f9e4ef3fa6
Gitweb:
https://git.kernel.org/tip/29fd01944b7273bb630c649a2104b7f9e4ef3fa6
Author:Frederic Weisbecker
AuthorDate:Mon, 18 Jan 2021 15:12:17 +01:00
The following commit has been merged into the sched/core branch of tip:
Commit-ID: 54b7429efffc99e845ba9381bee3244f012a06c2
Gitweb:
https://git.kernel.org/tip/54b7429efffc99e845ba9381bee3244f012a06c2
Author:Frederic Weisbecker
AuthorDate:Mon, 01 Feb 2021 00:05:44 +01:00
The following commit has been merged into the sched/core branch of tip:
Commit-ID: 43789ef3f7d61aa7bed0cb2764e588fc990c30ef
Gitweb:
https://git.kernel.org/tip/43789ef3f7d61aa7bed0cb2764e588fc990c30ef
Author:Frederic Weisbecker
AuthorDate:Mon, 01 Feb 2021 00:05:45 +01:00
1 - 100 of 8299 matches
Mail list logo