Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:apparmor_sk_alloc_security - allocate and attach the sk_security field

Proto:static int apparmor_sk_alloc_security(struct sock *sk, int family, gfp_t flags)

Type:int

Parameter:

TypeParameterName
struct sock *sk
intfamily
gfp_tflags
776  ctx = kzalloc - allocate memory. The memory is set to zero.*@size: how many bytes of memory are required.*@flags: the type of memory to allocate (see kmalloc).
777  If Not ctx Then Return -ENOMEM
780  SK_CTX(sk) = ctx
782  Return 0