函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:iomap_readpages

函数原型:int iomap_readpages(struct address_space *mapping, struct list_head *pages, unsigned nr_pages, const struct iomap_ops *ops)

返回类型:int

参数:

类型参数名称
struct address_space *mapping
struct list_head *pages
unsignednr_pages
const struct iomap_ops *ops
430  struct iomap_readpage_ctx ctx = {pages = pages, is_readahead = true, }
434  pos等于Return byte-offset into filesystem object for page.
435  last等于Return byte-offset into filesystem object for page.
436  length等于lastposPAGE_SIZE, ret等于0
438  trace_iomap_readpages(host, nr_pages)
440 length大于0循环
441  ret等于Execute a iomap write on a segment of the mapping that spans a* contiguous range of pages that have identical block mapping state
443  如果ret小于等于0则
444  WARN_ON_ONCE(ret == 0)
445  转到:done
447  pos加等于ret
448  length减等于ret
450  ret等于0
451  done :
452  如果biosubmit_bio(bio)
454  如果cur_page
455  如果非cur_page_in_biolock_page - unlock a locked page*@page: the page* Unlocks the page and wakes up sleepers in ___wait_on_page_locked().* Also wakes sleepers in wait_on_page_writeback() because the wakeup* mechanism between PageLocked pages and PageWriteback pages is shared.
457  Perform a free_page(), also freeing any swap cache associated with* this page if it is the last user of the page.
464  WARN_ON_ONCE(!ret && !链表为空)
465  返回:ret