1TRUNCATE_SETSIZE(9)       Memory Management in Linux       TRUNCATE_SETSIZE(9)
2
3
4

NAME

6       truncate_setsize - update inode and pagecache for a new file size
7

SYNOPSIS

9       void truncate_setsize(struct inode * inode, loff_t newsize);
10

ARGUMENTS

12       inode
13           inode
14
15       newsize
16           new file size
17

DESCRIPTION

19       truncate_setsize updastes i_size update and performs pagecache
20       truncation (if necessary) for a file size updates. It will be typically
21       be called from the filesystem´s setattr function when ATTR_SIZE is
22       passed in.
23
24       Must be called with inode_mutex held and after all filesystem specific
25       block truncation has been performed.
26
28Kernel Hackers Manual 2.6.         June 2019               TRUNCATE_SETSIZE(9)
Impressum