History

rcu: Refactor rcu_barrier() empty-list handling

This commit saves a few lines by checking first for an empty callback list. If the callback list is empty, then that CPU is taken care of, regardless of its online or nocb state. Also simplify tracing accordingly and fold a few lines together.

Paul E. McKenney committed 4 years ago

Commit 0cabb471 parent 82980b12 files · +12 −22Browse files

Showing the changes to include (1 of 2 files). Show all

Unified · Split

include/trace/events/rcu.h+4−5
@@ -794,16 +794,15 @@ TRACE_EVENT_RCU(rcu_torture_read, · 793 unmodified lines
794 * Tracepoint for rcu_barrier() execution. The string "s" describes794 * Tracepoint for rcu_barrier() execution. The string "s" describes
795 * the rcu_barrier phase:795 * the rcu_barrier phase:
796 * "Begin": rcu_barrier() started.796 * "Begin": rcu_barrier() started.
797 * "CB": An rcu_barrier_callback() invoked a callback, not the last.
797 * "EarlyExit": rcu_barrier() piggybacked, thus early exit.798 * "EarlyExit": rcu_barrier() piggybacked, thus early exit.
798 * "Inc1": rcu_barrier() piggyback check counter incremented.799 * "Inc1": rcu_barrier() piggyback check counter incremented.
799 * "OfflineNoCBQ": rcu_barrier() found offline no-CBs CPU with callbacks.800 * "Inc2": rcu_barrier() piggyback check counter incremented.
800 * "OnlineQ": rcu_barrier() found online CPU with callbacks.
801 * "OnlineNQ": rcu_barrier() found online CPU, no callbacks.
802 * "IRQ": An rcu_barrier_callback() callback posted on remote CPU.801 * "IRQ": An rcu_barrier_callback() callback posted on remote CPU.
803 * "IRQNQ": An rcu_barrier_callback() callback found no callbacks.802 * "IRQNQ": An rcu_barrier_callback() callback found no callbacks.
804 * "CB": An rcu_barrier_callback() invoked a callback, not the last.
805 * "LastCB": An rcu_barrier_callback() invoked the last callback.803 * "LastCB": An rcu_barrier_callback() invoked the last callback.
806 * "Inc2": rcu_barrier() piggyback check counter incremented.804 * "NQ": rcu_barrier() found a CPU with no callbacks.
805 * "OnlineQ": rcu_barrier() found online CPU with callbacks.
807 * The "cpu" argument is the CPU or -1 if meaningless, the "cnt" argument806 * The "cpu" argument is the CPU or -1 if meaningless, the "cnt" argument
808 * is the count of remaining callbacks, and "done" is the piggybacking count.807 * is the count of remaining callbacks, and "done" is the piggybacking count.
809 */808 */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t