函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:iomap_write_actor

函数原型:static loff_t iomap_write_actor(struct inode *inode, loff_t pos, loff_t length, void *data, struct iomap *iomap, struct iomap *srcmap)

返回类型:loff_t

参数:

类型参数名称
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  循环
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  如果bytes大于lengthbytes等于length
830  status等于负EFAULT
831  退出
834  status等于iomap_write_begin(inode, pos, bytes, 0, & page, iomap, srcmap)
836  如果此条件成立可能性小(为编译器优化)(status)则退出
839  如果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 iflush_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  如果此条件成立可能性小(为编译器优化)(status < 0)则退出
850  copied等于status
852  cond_resched()
854  iov_iter_advance(i, copied)
866  转到: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 iov_iter_count(i)且length循环
875  返回:如果writtenwritten否则status