函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Sync everything. We start by waking flusher threads so that most of* writeback runs on all devices in parallel. Then we sync all inodes reliably* which effectively also waits for all flusher threads to finish doing* writeback

函数原型:void ksys_sync(void)

返回类型:void

参数:

110  nowait等于0, wait等于1
112  Wakeup the flusher threads to start writeback of all currently dirty pages
113  rate_supers - call function for all active superblocks*@f: function to call*@arg: argument to pass to it* Scans the superblock list and calls given function, passing it* locked superblock and given argument.
114  rate_supers - call function for all active superblocks*@f: function to call*@arg: argument to pass to it* Scans the superblock list and calls given function, passing it* locked superblock and given argument.
115  rate_supers - call function for all active superblocks*@f: function to call*@arg: argument to pass to it* Scans the superblock list and calls given function, passing it* locked superblock and given argument.
116  iterate_bdevs(fdatawrite_one_bdev, NULL)
117  iterate_bdevs(fdatawait_one_bdev, NULL)
118  如果此条件成立可能性小(为编译器优化)(Flag that puts the machine in "laptop mode". Doubles as a timeout in jiffies:* a full sync is triggered after this time elapses without any disk activity.)则We're in laptop mode and we've just synced. The sync's writes will have* caused another writeback to be scheduled by laptop_io_completion.* Nothing needs to be written back anymore, so we unschedule the writeback.
调用者
名称描述
sys_sync