Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:fanotify_release

Proto:static int fanotify_release(struct inode *ignored, struct file *file)

Type:int

Parameter:

TypeParameterName
struct inode *ignored
struct file *file
442  group = needed for tty driver, and maybe others
451  Stop queueing new events for this group. Once this function returns* fsnotify_add_event() will not add any new events to the group's queue.
457  spin_lock( & protect the notification_list )
458  When Not list_empty - tests whether a list is empty*@head: the list to test. cycle
459  event = list_first_entry - get the first element from a list*@ptr: the list head to take the element from.*@type: the type of the struct this is embedded in.*@member: the name of the list_head within the struct.* Note, that list is expected to be not empty.( & access_list, structfanotify_perm_event, list)
461  list_del_init - deletes entry from list and reinitialize it.*@entry: the element to delete from the list.
462  Finish processing of permission event by setting it to ANSWERED state and* drop group->notification_lock.
463  spin_lock( & protect the notification_list )
471  When Not rn true if the notify queue is empty, false otherwise cycle
472  fsn_event = Remove and return the first event from the notification list. It is the* responsibility of the caller to destroy the obtained event
476  Else
480  spin_lock( & protect the notification_list )
482  spin_unlock( & protect the notification_list )
485  wake_up( & access_waitq)
488  Trying to get rid of a group. Remove all marks, flush all events and release* the group reference.* Note that another thread calling fsnotify_clear_marks_by_group() may still* hold a ref to the group.
490  Return 0