函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Lock keyring for link.

函数原型:int __key_link_lock(struct key *keyring, const struct keyring_index_key *index_key)__acquires(&keyring->sem) __acquires(&keyring_serialise_link_lock)

返回类型:int

参数:

类型参数名称
struct key *keyring
const struct keyring_index_key *index_key
1243  如果 type of key 不等于key_type_keyring则返回:负ENOTDIR
1246  lock for writing
1251  如果type恒等于key_type_keyringmutex_lock( & Semaphore to serialise link/link calls to prevent two link calls in parallel* introducing a cycle.)
1254  返回:0
调用者
名称描述
key_reject_and_linkkey_reject_and_link - Negatively instantiate a key and link it into the keyring.*@key: The key to instantiate.*@timeout: The timeout on the negative key.*@error: The error to return when the key is hit.
key_create_or_updatekey_create_or_update - Update or create and instantiate a key.*@keyring_ref: A pointer to the destination keyring with possession flag.*@type: The type of key.*@description: The searchable description for the key.
key_linkkey_link - Link a key to a keyring*@keyring: The keyring to make the link in
construct_alloc_keyAllocate a new key in under-construction state and attempt to link it in to* the requested keyring.* May return a key that's already under construction instead if there was a* race between two thread calling request_key().