函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Initialize debugfs for the locking event counts.

函数原型:static int __init init_lockevent_counts(void)

返回类型:int

参数:

146  d_counts等于debugfs_create_dir(LOCK_EVENTS_DIR, NULL)
149  如果非d_counts则转到:out
159 i小于 # of write lock handoffs 循环
160  如果skip_lockevent(When CONFIG_LOCK_EVENT_COUNTS is enabled, event counts of different* types of locks will be reported under the /lock_event_counts/* directory. See lock_events_list.h for the list of available locking* events.* Writing to the special "[i])则继续下一循环
162  如果非debugfs_create_file(When CONFIG_LOCK_EVENT_COUNTS is enabled, event counts of different* types of locks will be reported under the /lock_event_counts/* directory. See lock_events_list.h for the list of available locking* events.* Writing to the special "[i], 0400, d_counts, (void * )(long)i, & Debugfs data structures)则转到:fail_undo
167  如果非debugfs_create_file(When CONFIG_LOCK_EVENT_COUNTS is enabled, event counts of different* types of locks will be reported under the /lock_event_counts/* directory. See lock_events_list.h for the list of available locking* events.* Writing to the special "[LOCKEVENT_reset_cnts], 0200, d_counts, (void * )(long)LOCKEVENT_reset_cnts, & Debugfs data structures)则转到:fail_undo
172  返回:0
173  fail_undo :
174  debugfs_remove_recursive(d_counts)
175  out :
176  打印警告信息("Could not create '%s' debugfs entries\n", LOCK_EVENTS_DIR)
177  返回:负ENOMEM