Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\rcu\srcutree.c Create Date:2022-07-28 10:18:29
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:srcu_readers_active - returns true if there are readers. and false* otherwise*@ssp: which srcu_struct to count active readers (holding srcu_read_lock).* Note that this is not an atomic primitive, and can therefore suffer

Proto:static bool srcu_readers_active(struct srcu_struct *ssp)

Type:bool

Parameter:

TypeParameterName
struct srcu_struct *ssp
336  sum = 0
338  for_each_possible_cpu(cpu)
339  cpuc = per_cpu_ptr(sda, cpu)
341  sum += READ_ONCE(srcu_lock_count[0])
342  sum += READ_ONCE(srcu_lock_count[1])
343  sum -= READ_ONCE(srcu_unlock_count[0])
344  sum -= READ_ONCE(srcu_unlock_count[1])
346  Return sum
Caller
NameDescribe
cleanup_srcu_structleanup_srcu_struct - deconstruct a sleep-RCU structure*@ssp: structure to clean up.* Must invoke this after you are finished using a given srcu_struct that* was initialized via init_srcu_struct(), else you leak memory.