Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:ramfs_nommu_resize

Proto:static int ramfs_nommu_resize(struct inode *inode, loff_t newsize, loff_t size)

Type:int

Parameter:

TypeParameterName
struct inode *inode
loff_tnewsize
loff_tsize
138  If size == 0 Then
139  If Value for the false possibility is greater at compile time(newsize >> 32) Then Return -EFBIG
142  Return add a contiguous set of pages into a ramfs inode when it's truncated from* size 0 on the assumption that it's going to be used for an mmap of shared* memory
146  If newsize < size Then
147  ret = mmu_shrink_inode_mappings - Shrink the shared mappings on an inode*@inode: The inode to check*@size: The current filesize of the inode*@newsize: The proposed filesize of the inode* Check the shared mappings on an inode on behalf of a shrinking truncate
148  If ret < 0 Then Return ret
152  runcate_setsize - update inode and pagecache for a new file size*@inode: inode*@newsize: new file size* truncate_setsize updates i_size and performs pagecache truncation (if* necessary) to @newsize. It will be typically be called from the filesystem's
153  Return 0
Caller
NameDescribe
ramfs_nommu_setattrhandle a change of attributes* - we're specifically interested in a change of size