Skip to content

Commit

Permalink
bcache: trace missed reading by cache_missed
Browse files Browse the repository at this point in the history
Missed reading IOs are identified by s->cache_missed, not the
s->cache_miss, so in trace_bcache_read() using trace_bcache_read
to identify whether the IO is missed or not.

Signed-off-by: Tang Junhui <tang.junhui.linux@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: Coly Li <colyli@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
  • Loading branch information
Tang Junhui authored and Jens Axboe committed Oct 8, 2018
1 parent 7a55948 commit 502b291
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/md/bcache/request.c
Original file line number Diff line number Diff line change
Expand Up @@ -850,7 +850,7 @@ static void cached_dev_read_done_bh(struct closure *cl)

bch_mark_cache_accounting(s->iop.c, s->d,
!s->cache_missed, s->iop.bypass);
trace_bcache_read(s->orig_bio, !s->cache_miss, s->iop.bypass);
trace_bcache_read(s->orig_bio, !s->cache_missed, s->iop.bypass);

if (s->iop.status)
continue_at_nobarrier(cl, cached_dev_read_error, bcache_wq);
Expand Down

0 comments on commit 502b291

Please sign in to comment.