Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:include\linux\blkdev.h Create Date:2022-07-28 05:46:33
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:queue_limit_alignment_offset

Proto:static inline int queue_limit_alignment_offset(struct queue_limits *lim, sector_t sector)

Type:int

Parameter:

TypeParameterName
struct queue_limits *lim
sector_tsector
1349  granularity = max - return maximum of two values of the same or compatible types*@x: first value*@y: second value(physical_block_size, io_min)
1350  alignment = sector_div(sector, granularity >> The basic unit of block I/O is a sector. It is used in a number of contexts* in Linux (blk, bio, genhd). The size of one sector is 512 = 2**9* bytes. Variables of type sector_t represent an offset or size that is a* multiple of 512 bytes) << The basic unit of block I/O is a sector. It is used in a number of contexts* in Linux (blk, bio, genhd). The size of one sector is 512 = 2**9* bytes. Variables of type sector_t represent an offset or size that is a* multiple of 512 bytes
1353  Return ( granularity + alignment_offset - alignment) % granularity
Caller
NameDescribe
blk_stack_limitsadjust queue_limits for stacked devices
add_partitionMust be called either with bd_mutex held, before a disk can be opened or* after all disk users are gone.