Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Execute a iomap write on a segment of the mapping that spans a* contiguous range of pages that have identical block mapping state

Proto:loff_t iomap_apply(struct inode *inode, loff_t pos, loff_t length, unsigned flags, const struct iomap_ops *ops, void *data, iomap_actor_t actor)

Type:loff_t

Parameter:

TypeParameterName
struct inode *inode
loff_tpos
loff_tlength
unsignedflags
const struct iomap_ops *ops
void *data
iomap_actor_tactor
27  struct iomap iomap = { type of mapping = blocks allocated, need allocation }
28  struct iomap srcmap = { type of mapping = blocks allocated, need allocation }
29  written = 0
32  trace_iomap_apply(inode, pos, length, flags, ops, actor, _RET_IP_)
46  ret = iomap_begin(inode, pos, length, flags, & iomap, & srcmap)
47  If ret Then Return ret
49  If WARN_ON( file offset of mapping, bytes > pos) Then Return -EIO
51  If WARN_ON( length of mapping, bytes == 0) Then Return -EIO
54  trace_iomap_apply_dstmap(inode, & iomap)
55  If type of mapping != blocks allocated, need allocation Then trace_iomap_apply_srcmap(inode, & srcmap)
62  end = file offset of mapping, bytes + length of mapping, bytes
63  If type of mapping != blocks allocated, need allocation Then end = min - return minimum of two values of the same or compatible types*@x: first value*@y: second value(end, file offset of mapping, bytes + length of mapping, bytes )
65  If pos + length > end Then length = end - pos
80  written = actor(inode, pos, length, data, & iomap, type of mapping != blocks allocated, need allocation ? & srcmap : & iomap)
87  If iomap_end Then
88  ret = iomap_end(inode, pos, length, written > 0 ? written : 0, flags, & iomap)
93  Return If written Then written Else ret
Caller
NameDescribe
iomap_readpage
iomap_readpages
iomap_file_buffered_write
iomap_file_unshare
iomap_zero_range
iomap_page_mkwrite
iomap_dio_rwmap_dio_rw() always completes O_[D]SYNC writes regardless of whether the IO* is being issued as AIO or not. This allows us to optimise pure data writes* to use REQ_FUA rather than requiring generic_write_sync() to issue a* REQ_FLUSH post write
iomap_fiemap
iomap_bmaplegacy ->bmap interface. 0 is the error return (!)
iomap_seek_hole
iomap_seek_data
iomap_swapfile_activateIterate a swap file's iomaps to construct physical extents that can be* passed to the swapfile subsystem.