函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Sleep until I_SYNC is cleared. This function must be called with i_lock* held and drops it. It is aimed for callers not holding any inode reference* so once i_lock is dropped, inode can go away.

函数原型:static void inode_sleep_on_writeback(struct inode *inode)__releases(inode->i_lock)

返回类型:void

参数:

类型参数名称
struct inode *inode
1357  DEFINE_WAIT(wait)
1358  wqh等于bit_waitqueue( & Misc , __I_SYNC)
1361  Note: we use "set_current_state()" _after_ the wait-queue add,* because we need a memory barrier there on SMP, so that any* wake-function that tests for the wait-queue being active* will be guaranteed to see waitqueue addition _or_ subsequent
1362  sleep等于Misc 按位与I_SYNC
1363  自旋锁解锁
1364  如果sleep进程调度
1366  sh_wait - clean up after waiting in a queue*@wq_head: waitqueue waited on*@wq_entry: wait descriptor* Sets current thread back to running state and removes* the wait descriptor from the given waitqueue if still* queued.
调用者
名称描述
writeback_sb_inodesWrite a portion of b_io inodes which belong to @sb.* Return the number of pages and/or inodes written.* NOTE! This is called with wb->list_lock held, and will* unlock and relock that for each inode it ends up doing* IO for.
wb_writebackExplicit flushing or periodic writeback of "old" data