Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:iomap_write_actor

Proto:static loff_t iomap_write_actor(struct inode *inode, loff_t pos, loff_t length, void *data, struct iomap *iomap, struct iomap *srcmap)

Type:loff_t

Parameter:

TypeParameterName
struct inode *inode
loff_tpos
loff_tlength
void *data
struct iomap *iomap
struct iomap *srcmap
802  i = data
803  status = 0
804  written = 0
806  Do
812  offset = offset_in_page(pos)
813  bytes = min_t - return minimum of two values, using the specified type*@type: data type to use*@x: first value*@y: second value(unsignedlong, PAGE_SIZE - offset, iov_iter_count(i))
815  again :
816  If bytes > length Then bytes = length
830  status = -EFAULT
831  Break
834  status = iomap_write_begin(inode, pos, bytes, 0, & page, iomap, srcmap)
836  If Value for the false possibility is greater at compile time(status) Then Break
839  If Might pages of this file have been modified in userspace?* Note that i_mmap_writable counts all VM_SHARED vmas: do_mmap_pgoff* marks vma as VM_SHARED if it is shared, and the file was opened for* writing i Then flush_dcache_page(page)
842  copied = iov_iter_copy_from_user_atomic(page, i, offset, bytes)
844  flush_dcache_page(page)
846  status = iomap_write_end(inode, pos, bytes, copied, page, iomap, srcmap)
848  If Value for the false possibility is greater at compile time(status < 0) Then Break
850  copied = status
852  cond_resched()
854  iov_iter_advance(i, copied)
866  Go to again
868  pos += copied
869  written += copied
870  length -= copied
872  alance_dirty_pages_ratelimited - balance dirty memory state*@mapping: address_space which was dirtied* Processes which are dirtying memory should call in here once for each page* which was newly dirtied. The function will periodically check the system's
873  When iov_iter_count(i) && length cycle
875  Return If written Then written Else status