函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\locking\lockdep.c Create Date:2022-07-27 10:49:54
Last Modify:2020-03-17 14:16:01 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:To make lock name printouts unique, we calculate a unique* class->name_version generation counter. The caller must hold the graph* lock.

函数原型:static int count_matching_names(struct lock_class *new_class)

返回类型:int

参数:

类型参数名称
struct lock_class *new_class
775  count等于0
777  如果非name则返回:0
781  如果keysubclass恒等于key则返回:name_version
783  如果name且非字符串比较count等于两数取大(count, name_version)
787  返回:count加1
调用者
名称描述
register_lock_classRegister a lock's class in the hash-table, if the class is not present* yet. Otherwise we look it up. We cache the result in the lock object* itself, so actual lookup of the hash should be once per lock object.