kvfree_rcu: Fix comments according to current code
authorUladzislau Rezki (Sony) <urezki@gmail.com>
Wed, 28 Apr 2021 13:44:22 +0000 (15:44 +0200)
committerPaul E. McKenney <paulmck@kernel.org>
Mon, 10 May 2021 23:00:48 +0000 (16:00 -0700)
commitd8628f35bae0d0b1f06ca32fa57de76a7055e731
tree0503aceae12f5bc0c2e479a6666fea7081dd0d7b
parent7fe1da33f6bad33b79135b1df6c3476f87856928
kvfree_rcu: Fix comments according to current code

The kvfree_rcu() function now defers allocations in the common
case due to the fact that there is no lockless access to the
memory-allocator caches/pools.  In addition, in CONFIG_PREEMPT_NONE=y
and in CONFIG_PREEMPT_VOLUNTARY=y kernels, there is no reliable way to
determine if spinlocks are held.  As a result, allocation is deferred in
the common case, and the two-argument form of kvfree_rcu() thus uses the
"channel 3" queue through all the rcu_head structures.  This channel
is called referred to as the emergency case in comments, and these
comments are now obsolete.

This commit therefore updates these comments to reflect the new
common-case nature of such emergencies.

Signed-off-by: Uladzislau Rezki (Sony) <urezki@gmail.com>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
kernel/rcu/tree.c