diff options
author | 2022-08-09 10:24:36 -0700 | |
---|---|---|
committer | 2022-08-31 04:58:15 -0700 | |
commit | 99cf092058e13f133ff9373fcbd25ae38509df03 (patch) | |
tree | 8c5a3e700b8a1059316be2183b582bb3fe8a2a5f /scripts/generate_rust_analyzer.py | |
parent | doc: Update rcu_access_pointer() advice in rcu_dereference.rst (diff) | |
download | linux-dev-99cf092058e13f133ff9373fcbd25ae38509df03.tar.xz linux-dev-99cf092058e13f133ff9373fcbd25ae38509df03.zip |
doc: SLAB_TYPESAFE_BY_RCU uses cannot rely on spinlocks
Because the SLAB_TYPESAFE_BY_RCU code does not zero pages that are
to be broken up into slabs, the memory returned by kmem_cache_alloc()
must be fully initialized, including any spinlocks included in the newly
allocated structure. This means that readers attempting to look up an
SLAB_TYPESAFE_BY_RCU object must use a reference-counting approach.
A spinlock may be acquired only after a reference is obtained, which
prevents that object from being passed to kmem_struct_free(), but only
while that reference continues to be held.
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Diffstat (limited to 'scripts/generate_rust_analyzer.py')
0 files changed, 0 insertions, 0 deletions