函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\lockref.c Create Date:2022-07-27 07:16:13
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称: 有引用则递增计数

函数原型:int lockref_get_not_dead(struct lockref *lockref)

返回类型:int

参数:

类型参数名称
struct lockref *lockref
203  Note that the "cmpxchg()" reloads the "old" value for the* failure case.(count++;如果count小于0则返回0;, 返回1;)
211  加自旋锁
212  retval等于0
213  如果count大于等于0则
214  count自加
215  retval等于1
217  自旋锁解锁
218  返回:retval
调用者
名称描述
unlazy_childlazy_child - try to switch to ref-walk mode
d_alloc_parallel
__ns_get_path
legitimize_pathpath_put is needed afterwards regardless of success or failure