147: RCU update operations should not be used inside RCU read sections
RCU update operations inside read sections
RCU update operations should not be used inside RCU read sections
Update operations in RCU like rcu_assign_pointer wait until all updates will be accepted including current thread. Threads in read section can accept updates only after leaving critical section (in rcu_read_unlock).
It is prohibited to call update operations inside RCU read section, because in this case current thread will wait for the end of own read section and will be deadlocked.
Example of incorrect behavior:
rcu_read_lock(); // starting read section
*v = 2;
rcu_assign_pointer(gv,v); //update operation
rcu_read_unlock(); //unreachable operation
No data to display