projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cadfbb6
)
block: don't hardcode blk_qc_t -> tag mask
author
Jens Axboe
<axboe@fb.com>
Wed, 11 Nov 2015 16:37:34 +0000
(09:37 -0700)
committer
Jens Axboe
<axboe@fb.com>
Wed, 11 Nov 2015 16:37:34 +0000
(09:37 -0700)
Use the shift/mask we use elsewhere.
Signed-off-by: Jens Axboe <axboe@fb.com>
include/linux/blk_types.h
patch
|
blob
|
blame
|
history
diff --git
a/include/linux/blk_types.h
b/include/linux/blk_types.h
index 641e5a3ed58c4d2e1d8fb5c64c216eb3b5b821a5..0fb65843ec1e8522461dfe2d308c06e6fe33e2af 100644
(file)
--- a/
include/linux/blk_types.h
+++ b/
include/linux/blk_types.h
@@
-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 */