函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\notify\mark.c Create Date:2022-07-29 10:48:09
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:fsnotify_attach_connector_to_object

函数原型:static int fsnotify_attach_connector_to_object(fsnotify_connp_t *connp, unsigned int type, __kernel_fsid_t *fsid)

返回类型:int

参数:

类型参数名称
fsnotify_connp_t *connp
unsigned inttype
__kernel_fsid_t *fsid
476  struct inode * inode = NULL
479  conn等于分配高速缓存区
480  如果非conn则返回:负ENOMEM
482  spin_lock_init( & lock)
483  INIT_HLIST_HEAD( & list)
484  Type of object [lock] 等于type
485  Object pointer [lock] 等于connp
487  如果fsid
488  fsid of filesystem containing object 等于fsid
489  flags [lock] 等于FSNOTIFY_CONN_FLAG_HAS_FSID
490  否则
491  val[0]等于val[1]等于0
492  flags [lock] 等于0
494  如果 Type of object [lock] 恒等于FSNOTIFY_OBJ_TYPE_INODEinode等于igrab(fsnotify_conn_inode(conn))
500  如果cmpxchg(connp, NULL, conn)则
502  如果inode放置一个索引节点
504  kmem_cache_free(fsnotify_mark_connector_cachep, conn)
507  返回:0
调用者
名称描述
fsnotify_add_mark_listAdd mark into proper place in given list of marks. These marks may be used* for the fsnotify backend to determine which event types should be delivered* to which group and for which inodes. These marks are ordered according to