[PATCH v2 00/27] context_tracking, rcu: Spring cleaning renaming
From: Valentin Schneider
Date: Tue Apr 30 2024 - 05:18:20 EST
Hi folks,
This is v2 of [1], where I've now gone through the rabbit hole of renaming /just
a few/ more things.
I've done one patch per symbol for my own sanity, a lot of these probably
deserve to be squashed together (e.g. all of the nmi_nesting into one).
All patches are pure renaming, with the exception of:
- patch 14/27, which also lifts a negation out of a function and straps it to its
callsites.
- patch 27/27, which renames a trace event and flips the tracepoint strings passed
to it
At the end of the renaming exercise, the remaining RCU references to "dyntick"
are:
- Comments in core RCU code:
kernel/rcu/:
tree.c:354:56: * We inform the RCU core by emulating a zero-duration dyntick-idle period.
tree.c:769:10: * is in dynticks idle mode, which is an extended quiescent state.
tree.c:784:54: * by virtue of being in or having passed through an dynticks idle state since
tree.c:799:44: * If the CPU passed through or entered a dynticks idle phase with
tree.c:1983:14: /* Collect dyntick-idle snapshots. */
tree.c:1986:13: /* Handle dyntick-idle and offline CPUs. */
tree.c:2680:54: * Otherwise, invoke the specified function to check dyntick state for
tree.c:2740:16: * CPUs are in dyntick-idle mode.
tree_plugin.h:863:4: * dyntick-idle quiescent state visible to other CPUs, which will in
tree_nocb.h:55:19: * about entering dyntick-idle mode.
tree.h:208:8: /* 3) dynticks interface. */
tree.h:209:46: int watching_snap; /* Per-GP tracking for dynticks. */
Kconfig:11:4: # Dynticks-idle tracking
- Stale documentation in RCU/Design/Data-Structures/Data-Structures.rst
referencing fields that have been moved out of RCU after
904e600e60f4 ("rcu/context_tracking: Move dynticks_nesting to context tracking")
The series is based on rcu/next at:
b93b7b4635f1 ("ftrace: Asynchronous grace period for register_ftrace_direct()")
It's also available as a git tree at:
https://gitlab.com/vschneid/linux.git -b redhat/isolirq/defer/v3-rcu-v2
Cheers,
Valentin
[1]: https://lore.kernel.org/lkml/20240327112902.1184822-1-vschneid@xxxxxxxxxx/
Valentin Schneider (27):
treewide: context_tracking: Rename CONTEXT_* into CT_STATE_*
context_tracking, rcu: Rename RCU_DYNTICKS_IDX into CT_RCU_WATCHING
context_tracking, rcu: Rename ct_dynticks() into ct_rcu_watching()
context_tracking, rcu: Rename ct_dynticks_cpu() into
ct_rcu_watching_cpu()
context_tracking, rcu: Rename ct_dynticks_cpu_acquire() into
ct_rcu_watching_cpu_acquire()
context_tracking, rcu: Rename struct context_tracking
.dynticks_nesting into .nesting
context_tracking, rcu: Rename ct_dynticks_nesting() into ct_nesting()
context_tracking, rcu: Rename ct_dynticks_nesting_cpu() into
ct_nesting_cpu()
context_tracking, rcu: Rename struct context_tracking
.dynticks_nmi_nesting into .nmi_nesting
context_tracking, rcu: Rename ct_dynticks_nmi_nesting() into
ct_nmi_nesting()
context_tracking, rcu: Rename ct_dynticks_nmi_nesting_cpu() into
ct_nmi_nesting_cpu()
context_tracking, rcu: Rename DYNTICK_IRQ_NONIDLE into
CT_NESTING_IRQ_NONIDLE
context_tracking, rcu: Rename rcu_dynticks_task*() into rcu_task*()
context_tracking, rcu: Rename rcu_dynticks_curr_cpu_in_eqs() into
rcu_watching_curr_cpu()
rcu: Rename rcu_dynticks_eqs_online() into rcu_watching_eqs_online()
rcu: Rename rcu_dynticks_snap() into rcu_watching_snap()
rcu: Rename rcu_dynticks_in_eqs() into rcu_watching_in_eqs()
rcu: Rename rcu_dynticks_in_eqs_since() into
rcu_watching_changed_since()
rcu: Rename rcu_dynticks_zero_in_eqs() into rcu_watching_zero_in_eqs()
rcu: Rename struct rcu_data .dynticks_snap into .watching_snap
rcu: Rename struct rcu_data .exp_dynticks_snap into .exp_watching_snap
rcu: Rename dyntick_save_progress_counter() into
eqs_save_progress_counter()
rcu: Rename rcu_implicit_dynticks_qs() into rcu_implicit_eqs()
rcu: Rename rcu_momentary_dyntick_idle() into rcu_momentary_eqs()
context_tracking, rcu: Rename stray ->dynticks comments
rcu: Update stray documentation references to rcu_dynticks_eqs_{enter,
exit}()
context_tracking, rcu: Rename rcu_dyntick trace event into
rcu_watching
.../Data-Structures/Data-Structures.rst | 28 ++--
.../Tree-RCU-Memory-Ordering.rst | 8 +-
.../Memory-Ordering/TreeRCU-dyntick.svg | 8 +-
.../Design/Memory-Ordering/TreeRCU-gp-fqs.svg | 8 +-
.../RCU/Design/Memory-Ordering/TreeRCU-gp.svg | 8 +-
.../Memory-Ordering/TreeRCU-hotplug.svg | 4 +-
arch/Kconfig | 2 +-
arch/arm64/kernel/entry-common.c | 2 +-
arch/powerpc/include/asm/interrupt.h | 6 +-
arch/powerpc/kernel/interrupt.c | 6 +-
arch/powerpc/kernel/syscall.c | 2 +-
arch/x86/entry/common.c | 2 +-
include/linux/context_tracking.h | 32 +++--
include/linux/context_tracking_state.h | 58 ++++----
include/linux/entry-common.h | 2 +-
include/linux/rcutiny.h | 2 +-
include/linux/rcutree.h | 2 +-
include/trace/events/rcu.h | 18 +--
kernel/context_tracking.c | 132 +++++++++---------
kernel/entry/common.c | 2 +-
kernel/rcu/rcu.h | 4 +-
kernel/rcu/rcutorture.c | 4 +-
kernel/rcu/tasks.h | 2 +-
kernel/rcu/tree.c | 104 +++++++-------
kernel/rcu/tree.h | 4 +-
kernel/rcu/tree_exp.h | 8 +-
kernel/rcu/tree_nocb.h | 2 +-
kernel/rcu/tree_plugin.h | 6 +-
kernel/rcu/tree_stall.h | 6 +-
kernel/sched/core.c | 4 +-
kernel/stop_machine.c | 2 +-
kernel/trace/trace_osnoise.c | 4 +-
32 files changed, 243 insertions(+), 239 deletions(-)
--
2.43.0