Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\inode.c Create Date:2022-07-28 20:07:55
Last Modify:2020-03-18 19:19:59 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Free the inode passed in, removing it from the lists it is still connected* to

Proto:static void evict(struct inode *inode)

Type:void

Parameter:

TypeParameterName
struct inode *inode
555  op = s_op
557  BUG_ON(!(Misc & Set when inode is about to be freed but still has dirty pages or buffers attached or the inode itself is still dirty))
558  BUG_ON(!list_empty - tests whether a list is empty*@head: the list to test.)
560  If Not list_empty - tests whether a list is empty*@head: the list to test. Then s-writeback.c
563  inode_sb_list_del(inode)
571  inode_wait_for_writeback(inode)
573  If evict_inode Then
574  evict_inode(inode)
575  Else
576  runcate_inode_pages_final - truncate *all* pages before inode dies*@mapping: mapping to truncate* Called under (and serialized by) inode->i_mutex.* Filesystems have to use this in the .evict_inode path to inform the
577  clear an inode
579  If S_ISBLK(i_mode) && i_bdev Then bd_forget(inode)
581  If S_ISCHR(i_mode) && i_cdev Then cd_forget(inode)
584  remove an inode from the hash
586  spin_lock( & _blocks, i_bytes, maybe i_size )
587  wake_up_bit - wake up a waiter on a bit*@word: the word being waited on, a kernel virtual address*@bit: the bit of the word being waited on* There is a standard hashed waitqueue table for generic use
588  BUG_ON(Misc != (Set when inode is about to be freed but still has dirty pages or buffers attached or the inode itself is still dirty | Added by clear_inode()))
589  spin_unlock( & _blocks, i_bytes, maybe i_size )
591  destroy_inode(inode)
Caller
NameDescribe
dispose_listdispose_list - dispose of the contents of a local list*@head: the head of the list to free* Dispose-list gets a local list with local inodes in it, so it doesn't* need to worry about list corruption and SMP locks.
iput_finalCalled when we're dropping the last reference* to an inode