'\" t .\" Title: synchronize_rcu_tasks .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: Driver Basics .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "SYNCHRONIZE_RCU_TASK" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "Driver Basics" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" synchronize_rcu_tasks \- wait until an rcu\-tasks grace period has elapsed\&. .SH "SYNOPSIS" .HP \w'void\ synchronize_rcu_tasks('u .BI "void synchronize_rcu_tasks(" "void" ");" .SH "ARGUMENTS" .PP \fIvoid\fR .RS 4 no arguments .RE .SH "DESCRIPTION" .PP .PP Control will return to the caller some time after a full rcu\-tasks grace period has elapsed, in other words after all currently executing rcu\-tasks read\-side critical sections have elapsed\&. These read\-side critical sections are delimited by calls to \fBschedule\fR, \fBcond_resched_rcu_qs\fR, idle execution, userspace execution, calls to \fBsynchronize_rcu_tasks\fR, and (in theory, anyway) \fBcond_resched\fR\&. .PP This is a very specialized primitive, intended only for a few uses in tracing and other situations requiring manipulation of function preambles and profiling hooks\&. The \fBsynchronize_rcu_tasks\fR function is not (yet) intended for heavy use from multiple CPUs\&. .PP Note that this guarantee implies further memory\-ordering guarantees\&. On systems with more than one CPU, when \fBsynchronize_rcu_tasks\fR returns, each CPU is guaranteed to have executed a full memory barrier since the end of its last RCU\-tasks read\-side critical section whose beginning preceded the call to \fBsynchronize_rcu_tasks\fR\&. In addition, each CPU having an RCU\-tasks read\-side critical section that extends beyond the return from \fBsynchronize_rcu_tasks\fR is guaranteed to have executed a full memory barrier after the beginning of \fBsynchronize_rcu_tasks\fR and before the beginning of that RCU\-tasks read\-side critical section\&. Note that these guarantees include CPUs that are offline, idle, or executing in user mode, as well as CPUs that are executing in the kernel\&. .PP Furthermore, if CPU A invoked \fBsynchronize_rcu_tasks\fR, which returned to its caller on CPU B, then both CPU A and CPU B are guaranteed to have executed a full memory barrier during the execution of \fBsynchronize_rcu_tasks\fR \-\- even if CPU A and CPU B are the same CPU (but again only if the system has more than one CPU)\&. .SH "COPYRIGHT" .br