RFC blk-mq: Timeout rework
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest3 patches 60 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | blk-mq: Reference count request usageblock/ include/ | +25 | 2 replies | |
| 2/3 | blk-mq: Fix timeout and state orderblock/ | +1 | 3 replies | |
| 3/3 | blk-mq: Remove generation seqeunceblock/ block/ block/ +3 more | +58 | 51 replies |
Reviews trailers per patch
1 of 3 patches has a Reviewed-by or Acked-by.
| Patch | Ming Lei |
|---|---|
| 1/3 | |
| 2/3 | R-b |
| 3/3 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [RFC PATCH 0/3] blk-mq: Timeout rework
The current blk-mq code potentially locks requests out of completion by the thousands, making drivers jump through hoops to handle them. This patch set allows drivers to complete their requests whenever they're completed without requiring drivers know anything about the timeout code with minimal syncronization.
Other proposals under current consideration still have moments that prevent a driver from progressing a request to the completed state.
The timeout is ultimatley made safe by reference counting the request when timeout handling claims the request. By holding the reference count, we don't need to do any tricks to prevent a driver from completing the request out from under the timeout handler, allowing the actual state to be changed inline with the true state, and drivers don't need to be aware any of this is happening.
In order to make the overhead as minimal as possible, the request's reference is taken only when it appears that actual timeout handling needs to be done.
Keith Busch (3):
blk-mq: Reference count request usage
blk-mq: Fix timeout and state order
blk-mq: Remove generation seqeunce
block/blk-core.c | 6 - block/blk-mq-debugfs.c | 1 - block/blk-mq.c | 291 +++++++++++++------------------------------------ block/blk-mq.h | 20 +--- block/blk-timeout.c | 1 - include/linux/blkdev.h | 26 +---- 6 files changed, 83 insertions(+), 262 deletions(-)
Signature · 1 line
2.14.3