函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Test to see if we have an existing ioend structure that we could append to* first, otherwise finish off the current ioend and start another.

函数原型:static void iomap_add_to_ioend(struct inode *inode, loff_t offset, struct page *page, struct iomap_page *iop, struct iomap_writepage_ctx *wpc, struct writeback_control *wbc, struct list_head *iolist)

返回类型:void

参数:

类型参数名称
struct inode *inode
loff_toffset
struct page *page
struct iomap_page *iop
struct iomap_writepage_ctx *wpc
struct writeback_control *wbc
struct list_head *iolist
1367  sector等于iomap_sector( & iomap, offset)
1368  len等于i_blocksize(inode)
1369  poff等于offset按位与PAGE_SIZE减1
1370  bool merged, same_page = false
1372  如果非ioend或非iomap_can_add_to_ioend(wpc, offset, sector)则
1373  如果ioend添加链表项
1375  ioend等于iomap_alloc_ioend(inode, wpc, offset, sector, wbc)
1378  merged等于__bio_try_merge_page( being built , page, len, poff, & same_page)
1380  如果iop且非same_pageatomic_inc( & write_count)
1383  如果非merged
1388  bio_add_page( being built , page, len, poff)
1391  size of the extent 加等于len
1392  wbc_account_cgroup_owner(wbc, page, len)
调用者
名称描述
iomap_writepage_mapWe implement an immediate ioend submission policy here to avoid needing to* chain multiple ioends and hence nest mempool allocations which can violate* forward progress guarantees we need to provide