Skip to content

RCU flavor-consolidation changes for v4.20/v5.0

Paul E. McKenney lkml rcu 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest19 patches 29 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/19rcu: Refactor rcu_{nmi,irq}_{enter,exit}()kernel/rcu/tree.c+41 -203 replies
2/19rcu: Defer reporting RCU-preempt quiescent states when disabledDocumentation/RCU/Design/Requirements/Requirements.html include/linux/rcutiny.h kernel/rcu/tree.c +3 more+205 -779 replies
3/19rcutorture: Test extended "rcu" read-side critical sectionskernel/rcu/rcutorture.c+1 -00 replies
4/19rcu: Allow processing deferred QSes for exiting RCU-preempt readerskernel/rcu/tree_plugin.h+1 -10 replies
5/19rcu: Remove now-unused ->b.exp_need_qs field from the rcu_special unioninclude/linux/sched.h kernel/rcu/tree_plugin.h+5 -140 replies
6/19rcu: Add warning to detect half-interruptskernel/rcu/tree.c+2 -016 replies
7/19rcu: Apply RCU-bh QSes to RCU-sched and RCU-preempt when safeinclude/linux/rcutiny.h include/linux/rcutree.h kernel/rcu/tree.c +3 more+21 -00 replies
8/19rcu: Report expedited grace periods at context-switch timekernel/rcu/tree_plugin.h+3 -20 replies
9/19rcu: Define RCU-bh update API in terms of RCUinclude/linux/rcupdate.h include/linux/rcutiny.h include/linux/rcutree.h +4 more+48 -1940 replies
10/19rcu: Update comments and help text for no more RCU-bh updatersinclude/linux/rcupdate.h include/linux/rcupdate_wait.h include/linux/rcutree.h +3 more+24 -370 replies
11/19rcu: Drop "wake" parameter from rcu_report_exp_rdp()kernel/rcu/tree.c kernel/rcu/tree_exp.h kernel/rcu/tree_plugin.h+10 -140 replies
12/19rcu: Fix typo in rcu_get_gp_kthreads_prio() header commentkernel/rcu/tree.c+1 -10 replies
13/19rcu: Define RCU-sched API in terms of RCU for Tree RCU PREEMPT buildsinclude/linux/rcupdate.h include/linux/rcutiny.h include/linux/rcutree.h +4 more+308 -4800 replies
14/19rcu: Express Tiny RCU updates in terms of RCU rather than RCU-schedinclude/linux/rcupdate.h include/linux/rcutiny.h include/linux/rcutree.h +1 more+48 -470 replies
15/19rcu: Remove RCU_STATE_INITIALIZER()kernel/rcu/tree.c kernel/rcu/tree.h+37 -460 replies
16/19rcu: Eliminate rcu_state structure's ->call fieldkernel/rcu/tree.c kernel/rcu/tree.h kernel/rcu/tree_exp.h+1 -30 replies
17/19rcu: Remove rcu_state structure's ->rda fieldkernel/rcu/tree.c kernel/rcu/tree.h kernel/rcu/tree_exp.h +1 more+54 -570 replies
18/19rcu: Remove rcu_state_p pointer to default rcu_state structurekernel/rcu/tree.c kernel/rcu/tree_exp.h kernel/rcu/tree_plugin.h+21 -240 replies
19/19rcu: Remove rcu_data_p pointer to default rcu_data structurekernel/rcu/tree.c kernel/rcu/tree_plugin.h+5 -60 replies

Reviews trailers per patch

2 of 19 patches have a Reviewed-by or Acked-by.

PatchJoel Fernandes (Google)Steven Rostedt (VMware)
1/19R-b
2/19
3/19
4/19
5/19
6/19R-b
7/19
8/19
9/19
10/19
11/19
12/19
13/19
14/19
15/19
16/19
17/19
18/19
19/19

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH tip/core/rcu 0/19] RCU flavor-consolidation changes for v4.20/v5.0

Hello!

This series contains the RCU flavor consolidation, along with some initial cleanup work enabled by that consolidation (and some that became apparent while cleaning up):

1. Refactor rcu_{nmi,irq}_{enter,exit}(), saving a branch on the
idle entry/exit hotpaths, courtesy of Byungchul Park,

2. Defer reporting RCU-preempt quiescent states when disabled.
This is the key commit that consolidates the RCU-bh and RCU-sched flavors into RCU, however, the RCU-bh and RCU-sched flavors still exist independently as well at this point.

3. Test extended "rcu" read-side critical sections. This commit
causes rcutorture to test RCU's new-found ability to act as the combination of RCU, RCU-bh, and RCU-sched.

4. Allow processing deferred QSes for exiting RCU-preempt readers.
This is a optimization.

5. Remove now-unused ->b.exp_need_qs field from the rcu_special union.

6. Add warning to detect half-interrupts. Test the claim that
the Linux kernel no longer does half-interrupts.

7. Apply RCU-bh QSes to RCU-sched and RCU-preempt when safe, that is,
make the consolidated RCU inherit RCU-bh's denial-of-service avoidance mechanism.

8. Report expedited grace periods at context-switch time. This is
an optimization enabled by the RCU flavor consolidation.

9. Define RCU-bh update API in terms of RCU. This commit gets rid
of the RCU-bh update mechanism.

10. Update comments and help text to account for the removal of
the RCU-bh update mechanism.

11. Drop "wake" parameter from rcu_report_exp_rdp().

12. Fix typo in rcu_get_gp_kthreads_prio() header comment.

13. Define RCU-sched API in terms of RCU for Tree RCU PREEMPT builds.
Although this commit gets rid of the RCU-sched update mechanism from PREEMPT builds, it of course remains as the sole RCU flavor for !PREEMPT && !SMP builds.

14. Express Tiny RCU updates in terms of RCU rather than RCU-sched.
This will enable additional cleanups and code savings.

15. Remove RCU_STATE_INITIALIZER() in favor of just using an open-coded
initializer for the sole remaining rcu_state structure.

16. Eliminate rcu_state structure's ->call field, as it is now always
just call_rcu().

17. Remove rcu_state structure's ->rda field, as there is now only one
set of per-CPU rcu_data structures.

Thanx, Paul

------------------------------------------------------------------------

 Documentation/RCU/Design/Requirements/Requirements.html |   50 -
 include/linux/rcupdate.h                                |   48 -
 include/linux/rcupdate_wait.h                           |    6 
 include/linux/rcutiny.h                                 |   61 +
 include/linux/rcutree.h                                 |   31 
 include/linux/sched.h                                   |    6 
 kernel/rcu/Kconfig                                      |   10 
 kernel/rcu/rcutorture.c                                 |    1 
 kernel/rcu/tiny.c                                       |  163 +--
 kernel/rcu/tree.c                                       |  655 +++++-----------
 kernel/rcu/tree.h                                       |   44 -
 kernel/rcu/tree_exp.h                                   |  256 +++---
 kernel/rcu/tree_plugin.h                                |  523 ++++++------
 kernel/rcu/update.c                                     |    2 
 kernel/softirq.c                                        |    3 
 15 files changed, 836 insertions(+), 1023 deletions(-)