函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\ramfs\file-nommu.c Create Date:2022-07-29 11:11:53
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:ramfs_nommu_resize

函数原型:static int ramfs_nommu_resize(struct inode *inode, loff_t newsize, loff_t size)

返回类型:int

参数:

类型参数名称
struct inode *inode
loff_tnewsize
loff_tsize
138  如果size恒等于0则
139  如果此条件成立可能性小(为编译器优化)(newsize >> 32)则返回:负EFBIG
142  返回: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  如果newsize小于size
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  如果ret小于0则返回: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  返回:0
调用者
名称描述
ramfs_nommu_setattrhandle a change of attributes* - we're specifically interested in a change of size