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:Remove the mark from the idr (if present) and drop the reference* on the mark because it was in the idr.

Proto:static void inotify_remove_from_idr(struct fsnotify_group *group, struct inotify_inode_mark *i_mark)

Type:void

Parameter:

TypeParameterName
struct fsnotify_group *group
struct inotify_inode_mark *i_mark
418  idr = idr
419  idr_lock = idr_lock
420  struct inotify_inode_mark * found_i_mark = NULL
423  spin_lock(idr_lock)
424  wd = wd
430  If wd == -1 Then
431  WARN_ONCE(1, "%s: i_mark=%p i_mark->wd=%d i_mark->group=%p\n", __func__, i_mark, wd, Group this mark is for. Set on mark creation, stable until last ref * is dropped )
433  Go to out
437  found_i_mark = inotify_idr_find_locked(group, wd)
438  If Value for the false possibility is greater at compile time(!found_i_mark) Then
439  WARN_ONCE(1, "%s: i_mark=%p i_mark->wd=%d i_mark->group=%p\n", __func__, i_mark, wd, Group this mark is for. Set on mark creation, stable until last ref * is dropped )
441  Go to out
449  If Value for the false possibility is greater at compile time(found_i_mark != i_mark) Then
450  WARN_ONCE(1, "%s: i_mark=%p i_mark->wd=%d i_mark->group=%p found_i_mark=%p found_i_mark->wd=%d found_i_mark->group=%p\n", __func__, i_mark, wd, Group this mark is for. Set on mark creation, stable until last ref * is dropped , found_i_mark, wd, Group this mark is for. Set on mark creation, stable until last ref * is dropped )
455  Go to out
462  If Value for the false possibility is greater at compile time(_read - get a refcount's value*@r: the refcount* Return: the refcount's value < 2) Then
463  printk - print a kernel message*@fmt: format string* This is printk(). It can be called from any context. We want it to work.* We try to grab the console_lock. If we succeed, it's easy - we log the* output and call the console drivers
466  BUG()
469  dr_remove() - Remove an ID from the IDR
471  fsnotify_put_mark( & fsn_mark)
472  out :
473  wd = -1
474  spin_unlock(idr_lock)
476  If found_i_mark Then fsnotify_put_mark( & fsn_mark)
Caller
NameDescribe
inotify_ignored_and_remove_idrSend IN_IGNORED for this wd, remove this wd from the idr.
inotify_new_watch