函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:moyo_try_to_gc - Try to kfree() an entry.*@type: One of values in "enum tomoyo_policy_id".*@element: Pointer to "struct list_head".* Returns nothing.* Caller holds tomoyo_policy_lock mutex.

函数原型:static void tomoyo_try_to_gc(const enum tomoyo_policy_id type, struct list_head *element)

返回类型:void

参数:

类型参数名称
const enum tomoyo_policy_idtype
struct list_head *element
395  删除链表项
396  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
397  synchronize_srcu - wait for prior SRCU read-side critical-section completion*@ssp: srcu_struct with which to synchronize
405  如果moyo_struct_used_by_io_buffer - Check whether the list element is used by /sys/kernel/security/tomoyo/ users or not.*@element: Pointer to "struct list_head".* Returns true if @element is used by /sys/kernel/security/tomoyo/ users,* false otherwise.则转到:reinject
408  :type恒等于TOMOYO_ID_TRANSITION_CONTROL
409  moyo_del_transition_control - Delete members in "struct tomoyo_transition_control".*@element: Pointer to "struct list_head".* Returns nothing.
410  退出
411  :type恒等于TOMOYO_ID_MANAGER
412  moyo_del_manager - Delete members in "struct tomoyo_manager".*@element: Pointer to "struct list_head".* Returns nothing.
413  退出
414  :type恒等于TOMOYO_ID_AGGREGATOR
415  moyo_del_aggregator - Delete members in "struct tomoyo_aggregator".*@element: Pointer to "struct list_head".* Returns nothing.
416  退出
417  :type恒等于TOMOYO_ID_GROUP
418  moyo_del_group - Delete "struct tomoyo_group".*@element: Pointer to "struct list_head".* Returns nothing.
419  退出
420  :type恒等于TOMOYO_ID_PATH_GROUP
421  moyo_del_path_group - Delete members in "struct tomoyo_path_group".*@element: Pointer to "struct list_head".* Returns nothing.
422  退出
423  :type恒等于TOMOYO_ID_ADDRESS_GROUP
424  moyo_del_address_group - Delete members in "struct tomoyo_address_group".*@element: Pointer to "struct list_head".* Returns nothing.
425  退出
426  :type恒等于TOMOYO_ID_NUMBER_GROUP
427  moyo_del_number_group - Delete members in "struct tomoyo_number_group".*@element: Pointer to "struct list_head".* Returns nothing.
428  退出
429  :type恒等于TOMOYO_ID_CONDITION
430  moyo_del_condition - Delete members in "struct tomoyo_condition".*@element: Pointer to "struct list_head".* Returns nothing.
431  退出
432  :type恒等于TOMOYO_ID_NAME
437  如果moyo_name_used_by_io_buffer - Check whether the string is used by /sys/kernel/security/tomoyo/ users or not.*@string: String to check.* Returns true if @string is used by /sys/kernel/security/tomoyo/ users,* false otherwise.则转到:reinject
441  moyo_del_name - Delete members in "struct tomoyo_name".*@element: Pointer to "struct list_head".* Returns nothing.
442  退出
443  :type恒等于TOMOYO_ID_ACL
444  moyo_del_acl - Delete members in "struct tomoyo_acl_info".*@element: Pointer to "struct list_head".* Returns nothing.
445  退出
446  :type恒等于TOMOYO_ID_DOMAIN
451  如果atomic_read( & container_of - cast a member of a structure out to the containing structure*@ptr: the pointer to the member.*@type: the type of the container struct this is embedded in.*@member: the name of the member within the struct.users)则转到:reinject
455  退出
456  :type恒等于TOMOYO_MAX_POLICY
457  退出
459  mutex_lock( & tomoyo_policy_lock)
460  如果type恒等于TOMOYO_ID_DOMAINmoyo_del_domain - Delete members in "struct tomoyo_domain_info".*@element: Pointer to "struct list_head".* Returns nothing.* Caller holds tomoyo_policy_lock mutex.
462  moyo_memory_free - Free memory for elements.*@ptr: Pointer to allocated memory.* Returns nothing.* Caller holds tomoyo_policy_lock mutex.
463  返回
464  reinject :
473  mutex_lock( & tomoyo_policy_lock)
474  添加RCU保护项
调用者
名称描述
tomoyo_collect_membermoyo_collect_member - Delete elements with "struct tomoyo_acl_head".*@id: One of values in "enum tomoyo_policy_id".*@member_list: Pointer to "struct list_head".* Returns nothing.
tomoyo_collect_aclmoyo_collect_acl - Delete elements in "struct tomoyo_domain_info".*@list: Pointer to "struct list_head".* Returns nothing.
tomoyo_collect_entrymoyo_collect_entry - Try to kfree() deleted elements.* Returns nothing.