Skip to content

fix inaccurate io_ticks

Weiping Zhang linux-block 5 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v5 Latest2 patches 8 repliesIn review
  2. v42 patches 2 repliesSuperseded
  3. v31 patch 0 repliesSuperseded
Earlier versions · 2
VersionPostedPatchesRepliesStatus
v21 patch0 repliesSuperseded
v1 RFC1 patch4 repliesSuperseded

Changes in v5 from the cover letter

* only get inflight in update_io_ticks when start a new IO every jiffy.

Patches in v5 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2block: fix inaccurate io_ticksblock/blk-core.c block/blk-mq.c block/blk-mq.h +2 more+67 -20 replies
2/2blk-mq: break more earlier when interate hctxblock/blk-mq-tag.c block/blk-mq-tag.h block/blk-mq.c +1 more+40 -80 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v5 yet.

Read the v5 thread

Cover letter [PATCH v5 0/2] fix inaccurate io_ticks

Hi,

This patchset include two patches,

01. block: fix inaccurate io_ticks
fix the io_ticks if start a new IO and there is no inflight IO before.

02. blk-mq: break more earlier when interate hctx
An optimization for blk_mq_queue_inflight and blk_mq_part_is_in_flight these two function only want to know if there is IO inflight and do not care how many inflight IOs are there.
After this patch blk_mq_queue_inflight will stop interate other hctx when find a inflight IO, blk_mq_part_is_in_inflight stop interate other setbit/hctx when find a inflight IO.

Changes since v4:
* only get inflight in update_io_ticks when start a new IO every jiffy.

Changes since v3:
* add a parameter for blk_mq_queue_tag_busy_iter to break earlier when interate hctx of a queue, since blk_mq_part_is_in_inflight and blk_mq_queue_inflight do not care how many inflight IOs.

Changes since v2:
* use blk_mq_queue_tag_busy_iter framework instead of open-code.
* update_io_ticks before update inflight for __part_start_io_acct

Changes since v1:
* avoid iterate all tagset, return directly if find a set bit.
* fix some typo in commit message

Weiping Zhang (2):
block: fix inaccurate io_ticks
blk-mq: break more earlier when interate hctx

 block/blk-core.c       | 19 ++++++++++----
 block/blk-mq-tag.c     | 11 ++++++--
 block/blk-mq-tag.h     |  2 +-
 block/blk-mq.c         | 58 +++++++++++++++++++++++++++++++++++++++---
 block/blk-mq.h         |  1 +
 block/blk.h            |  1 +
 block/genhd.c          | 13 ++++++++++
 include/linux/blk-mq.h |  1 +
 8 files changed, 94 insertions(+), 12 deletions(-)
Signature · 1 line
2.18.4