函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Increment the object use_count. Return 1 if successful or 0 otherwise. Note* that once an object's use_count reached 0, the RCU freeing was already* registered and the object should no longer be used. This function must be

函数原型:static int get_object(struct kmemleak_object *object)

返回类型:int

参数:

类型参数名称
struct kmemleak_object *object
410  返回:atomic_inc_not_zero - increment unless the number is zero*@v: pointer of type atomic_t* Atomically increments @v by 1, if @v is non-zero.* Returns true if the increment was done.
调用者
名称描述
find_and_get_objectLook up an object in the object search tree and increase its use_count.
update_refsUpdate an object's references. object->lock must be held by the caller.
kmemleak_scanScan data sections and all the referenced memory blocks allocated via the* kernel's standard allocators. This function must be called with the* scan_mutex held.
kmemleak_seq_startIterate over the object_list and return the first valid object at or after* the required position with its use_count incremented. The function triggers* a memory scanning when the pos argument points to the first position.
kmemleak_seq_nextReturn the next object in the object_list. The function decrements the* use_count of the previous object and increases that of the next one.