函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:aggregate disk stat collector. Uses the same stats that the sysfs* entries do, above, but makes them available through one seq_file.* The output looks suspiciously like /proc/partitions with a bunch of* extra fields.

函数原型:static int diskstats_show(struct seq_file *seqf, void *v)

返回类型:int

参数:

类型参数名称
struct seq_file *seqf
void *v
1367  gp等于v
1381  disk_part_iter_init - initialize partition iterator*@piter: iterator to initialize*@disk: disk to iterate over*@flags: DISK_PITER_* flags* Initialize @piter so that it iterates over partitions of @disk.* CONTEXT:* Don't care.
1382 hd等于disk_part_iter_next - proceed iterator to the next partition and return it*@piter: iterator of interest* Proceed @piter to the next partition and return it.* CONTEXT:* Don't care.循环
1383  inflight等于part_in_flight(queue, hd)
1384  seq_printf(seqf, "%4d %7d %s %lu %lu %lu %u %lu %lu %lu %u %u %u %u %lu %lu %lu %u %lu %u\n", MAJOR(part_devt(hd)), MINOR(part_devt(hd)), disk_name(gp, partno, buf), part_stat_read(hd, ios[STAT_READ]), part_stat_read(hd, merges[STAT_READ]), part_stat_read(hd, sectors[STAT_READ]), (unsignedint)part_stat_read_msecs(hd, STAT_READ), part_stat_read(hd, ios[STAT_WRITE]), part_stat_read(hd, merges[STAT_WRITE]), part_stat_read(hd, sectors[STAT_WRITE]), (unsignedint)part_stat_read_msecs(hd, STAT_WRITE), inflight, Convert jiffies to milliseconds and back.* Avoid unnecessary multiplications/divisions in the* two most common HZ cases:, Convert jiffies to milliseconds and back.* Avoid unnecessary multiplications/divisions in the* two most common HZ cases:, part_stat_read(hd, ios[STAT_DISCARD]), part_stat_read(hd, merges[STAT_DISCARD]), part_stat_read(hd, sectors[STAT_DISCARD]), (unsignedint)part_stat_read_msecs(hd, STAT_DISCARD), part_stat_read(hd, ios[STAT_FLUSH]), (unsignedint)part_stat_read_msecs(hd, STAT_FLUSH))
1412  disk_part_iter_exit - finish up partition iteration*@piter: iter of interest* Called when iteration is over. Cleans up @piter.* CONTEXT:* Don't care.
1414  返回:0