mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-18 02:04:05 +08:00
block: don't hardcode blk_qc_t -> tag mask
Use the shift/mask we use elsewhere. Signed-off-by: Jens Axboe <axboe@fb.com>
This commit is contained in:
parent
cadfbb6ec2
commit
e3a7a3bf36
@ -265,7 +265,7 @@ static inline unsigned int blk_qc_t_to_queue_num(blk_qc_t cookie)
|
||||
|
||||
static inline unsigned int blk_qc_t_to_tag(blk_qc_t cookie)
|
||||
{
|
||||
return cookie & 0xffff;
|
||||
return cookie & ((1u << BLK_QC_T_SHIFT) - 1);
|
||||
}
|
||||
|
||||
#endif /* __LINUX_BLK_TYPES_H */
|
||||
|
Loading…
Reference in New Issue
Block a user