Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Dispose of a user structure

Proto:void key_user_put(struct key_user *user)

Type:void

Parameter:

TypeParameterName
struct key_user *user
121  If _dec_and_lock - return holding spinlock if able to decrement* refcount to 0*@r: the refcount*@lock: the spinlock to be locked* Similar to atomic_dec_and_lock(), it will WARN on underflow and fail to* decrement when saturated at REFCOUNT_SATURATED Then
122  rb_erase( & node, & ree of quota records indexed by UID )
123  spin_unlock( & key_user_lock)
125  kfree(user)
Caller
NameDescribe
key_allockey_alloc - Allocate a key of the specified type.*@type: The type of key to allocate.*@desc: The key description to allow the key to be searched out.*@uid: The owner of the new key.*@gid: The group ID for the new key's group permissions.
keyctl_chown_keyChange the ownership of a key* The key must grant the caller Setattr permission for this to work, though* the key need not be fully instantiated yet. For the UID to be changed, or* for the GID to be changed to a group the caller is not a member of, the
construct_key_and_linkCommence key construction.