Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\notify\inotify\inotify_user.c Create Date:2022-07-28 20:17:46
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:inotify_add_to_idr

Proto:static int inotify_add_to_idr(struct idr *idr, spinlock_t *idr_lock, struct inotify_inode_mark *i_mark)

Type:int

Parameter:

TypeParameterName
struct idr *idr
spinlock_t *idr_lock
struct inotify_inode_mark *i_mark
362  dr_preload - preload for idr_alloc()*@gfp_mask: allocation mask to use for preloading* Preallocate memory to use for the next call to idr_alloc(). This function* returns with preemption disabled. It will be enabled by idr_preload_end().
363  spin_lock(idr_lock)
365  ret = dr_alloc_cyclic() - Allocate an ID cyclically.*@idr: IDR handle.*@ptr: Pointer to be associated with the new ID.*@start: The minimum ID (inclusive).*@end: The maximum ID (exclusive).*@gfp: Memory allocation flags.
366  If ret >= 0 Then
368  wd = ret
369  fsnotify_get_mark( & fsn_mark)
372  spin_unlock(idr_lock)
373  dr_preload_end - end preload section started with idr_preload()* Each idr_preload() should be matched with an invocation of this* function. See idr_preload() for details.
374  Return If ret < 0 Then ret Else 0
Caller
NameDescribe
inotify_new_watch