Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\keys\keyring.c Create Date:2022-07-28 18:18:16
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:See if a cycle will will be created by inserting acyclic tree B in acyclic* tree A at the topmost level (ie: as a direct child of A).* Since we are adding B to A at the top level, checking for cycles should just

Proto:static int keyring_detect_cycle(struct key *A, struct key *B)

Type:int

Parameter:

TypeParameterName
struct key *A
struct key *B
1217  struct keyring_search_context ctx = {index_key = index_key, Raw match data = A, Type of lookup for this search. = Direct lookup by description. , iterator = keyring_detect_cycle_iterator, flags = (Skip state checks | Don't update times | Don't check permissions | Give an error on excessive depth | Search child keyrings also ), }
1229  _read_lock() - mark the beginning of an RCU read-side critical section* When synchronize_rcu() is invoked on one CPU while other CPUs* are within RCU read-side critical sections, then the* synchronize_rcu() is guaranteed to block until after all the other
1230  Search a tree of keyrings that point to other keyrings up to the maximum* depth.
1231  _read_unlock() - marks the end of an RCU read-side critical section.* In most situations, rcu_read_unlock() is immune from deadlock.* However, in kernels built with CONFIG_RCU_BOOST, rcu_read_unlock()
1232  Return If PTR_ERR(result) == -EAGAIN Then 0 Else PTR_ERR(result)
Caller
NameDescribe
__key_link_check_live_keyCheck already instantiated keys aren't going to be a problem.* The caller must have called __key_link_begin(). Don't need to call this for* keys that were created since __key_link_begin() was called.