Lines Matching full:rcu
12 This document describes RCU's major data structures and their relationship
18 RCU is for all intents and purposes a large state machine, and its
19 data structures maintain the state in such a way as to allow RCU readers
20 to execute extremely quickly, while also processing the RCU grace periods
22 The efficiency and scalability of RCU updaters is provided primarily
35 If the actual hardware has only 16 CPUs, RCU will adjust itself
88 32-bit system), then RCU will automatically add more levels to the tree.
90 65,536 CPUs, RCU would configure the ``rcu_node`` tree as follows:
94 RCU currently permits up to a four-level tree, which on a 64-bit system
102 and scalability benefits of partitioning, even though RCU grace-period
121 RCU updaters wait for normal grace periods by registering RCU callbacks,
123 ``synchronize_rcu()`` and friends. RCU callbacks are represented by
144 different ideas about the state of RCU at any given time. For but one
145 example, awareness of the start or end of a given RCU grace period
147 absolutely necessary for RCU to have good read-side performance. If this
167 lists of tasks that have blocked while in their current RCU read-side
174 detection and RCU callback queuing. It also tracks its relationship
182 #. ``rcu_head``: This structure represents RCU callbacks, and is the
183 only structure allocated and managed by RCU users. The ``rcu_head``
184 structure is normally embedded within the RCU-protected data
187 If all you wanted from this article was a general notion of how RCU's
196 state of RCU in the system. This structure forms the interconnection
274 RCU grace periods are numbered, and the ``->gp_seq`` field contains the
278 ``->gp_seq`` are zero, then RCU is idle. Any other value in the bottom
303 The ``->name`` and ``->abbr`` fields distinguish between preemptible RCU
304 (“rcu_preempt” and “p”) and non-preemptible RCU (“rcu_sched” and “s”).
317 of tasks that have blocked while in their current RCU read-side critical
341 tree, and is ``NULL`` for the root ``rcu_node``. The RCU implementation
390 then this ``rcu_node`` structure believes that RCU is idle.
460 | wakes up, it notices that the current RCU grace period needs it to |
466 | #. CPU 0's scheduling clock interrupt fires in the middle of an RCU |
467 | read-side critical section, and notices that the RCU core needs |
468 | something, so commences RCU softirq processing. |
474 | That grace period might now end before the RCU read-side critical |
485 ``PREEMPT_RCU`` allows tasks to be preempted in the midst of their RCU
488 separate article on RCU read-side processing. For now, it is enough to
499 preempted tasks. As tasks undergo context switches within RCU read-side
504 later exit their RCU read-side critical sections, they remove themselves
520 RCU read-side critical section, then an expedited grace period started,
521 then task T2 blocked in an RCU read-side critical section, then a normal
522 grace period started, and finally task 3 blocked in an RCU read-side
532 execute the outermost ``rcu_read_unlock()`` that ends their RCU
624 levels of ``rcu_node`` tree permits better testing of RCU's
715 In this figure, the ``->head`` pointer references the first RCU callback
722 ``->tails[RCU_NEXT_READY_TAIL]`` array element references the same RCU
724 there are no callbacks waiting on the next RCU grace period. The
726 pointer, indicating that all the remaining RCU callbacks have not yet
727 been assigned to an RCU grace period. Note that the
728 ``->tails[RCU_NEXT_TAIL]`` array element always references the last RCU
782 The ``rcu_data`` maintains the per-CPU state for the RCU subsystem. The
785 of quiescent-state detection and RCU callback queuing. It also tracks
844 believes that RCU is idle.
866 that the RCU core needs a quiescent state from the corresponding CPU.
872 RCU Callback Handling
875 In the absence of CPU-hotplug events, RCU callbacks are invoked by the
897 whenever it notices that another RCU grace period has completed. The CPU
898 detects the completion of an RCU grace period by noticing that the value
914 Finally, the ``->blimit`` counter is the maximum number of RCU callbacks
979 RCU core code would really like to see a quiescent state from the
981 heavy-weight dyntick-counter operations. This flag is checked by RCU's
986 the RCU core code would really like to see a quiescent state from the
988 badly RCU wants this quiescent state. This flag is checked by RCU's
1012 Each ``rcu_head`` structure represents an RCU callback. These structures
1013 are normally embedded within RCU-protected data structures whose
1015 algorithms that block waiting for RCU grace periods, RCU users need not
1031 enclosing RCU-protected data structure.
1033 Both of these fields are used internally by RCU. From the viewpoint of
1034 RCU users, this structure is an opaque “cookie”.
1041 | beginning of the enclosing RCU-protected data structure? |
1046 | RCU-protected data structure. The callback function can therefore use |
1052 RCU-Specific Fields in the ``task_struct`` Structure
1073 The ``->rcu_read_lock_nesting`` field records the nesting level for RCU
1078 preemptible-RCU read-side critical sections and the
1081 preemptible-RCU read-side critical section.
1085 tasks-RCU grace period, ``->rcu_tasks_holdout`` is set if the current
1086 tasks-RCU grace period is waiting on this task,
1140 So the state of RCU is represented by an ``rcu_state`` structure, which