Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\bpf\inode.c Create Date:2022-07-28 13:06:34
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:bpf_symlink

Proto:static int bpf_symlink(struct inode *dir, struct dentry *dentry, const char *target)

Type:int

Parameter:

TypeParameterName
struct inode *dir
struct dentry *dentry
const char *target
353  link = kstrdup(target, GFP_USER | DOC: Action modifiers* Action modifiers* ~~~~~~~~~~~~~~~~* %__GFP_NOWARN suppresses allocation failure reports.* %__GFP_COMP address compound page metadata.* %__GFP_ZERO returns a zeroed page on success.)
356  If Not link Then Return -ENOMEM
359  inode = bpf_get_inode(i_sb, dir, S_IRWXUGO | S_IFLNK)
360  If IS_ERR(inode) Then
361  kfree(link)
362  Return PTR_ERR(inode)
365  i_op = simple_symlink_inode_operations
366  i_link = link
368  bpf_dentry_finalize(dentry, inode, dir)
369  Return 0