函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:find_vol1_partitions

函数原型:static int find_vol1_partitions(struct parsed_partitions *state, struct hd_geometry *geo, int blocksize, char name[], union label_t *label)

返回类型:int

参数:

类型参数名称
struct parsed_partitions *state
struct hd_geometry *geo
intblocksize
charname
union label_t *label
148  snprintf - Format a string and place it in a buffer*@buf: The buffer to place the result into*@size: The size of the buffer, including the trailing null space*@fmt: The format string to use*@
149  长字符串拼接
154  secperblk等于blocksize右移9位
155  blk等于mpute the block number from a* cyl-cyl-head-head-block structure加1
156  counter等于0
157  data等于read_part_sector(state, blk * secperblk, & sect)
158  当(data != NULL)循环
159  memcpy( & f1, data, sizeof(structvtoc_format1_label))
160  put_dev_sector(sect)
166  blk自加
168  继续下一循环
171  如果 format identifier 不等于ASCII -> EBCDIC conversion table ['1']且 format identifier 不等于ASCII -> EBCDIC conversion table ['8']则退出
175  offset等于mpute the block number from a* cyl-cyl-head-head structure
176  size等于mpute the block number from a* cyl-cyl-head-head structureoffsetsectors
178  offset乘等于secperblk
179  size乘等于secperblk
180  如果counter大于等于limit退出
182  put_partition(state, counter + 1, offset, size)
183  counter自加
184  blk自加
185  data等于read_part_sector(state, blk * secperblk, & sect)
187  长字符串拼接
189  如果非data则返回:负1
192  返回:1
调用者
名称描述
ibm_partitionThis is the main function, called by check.c