]> git.baikalelectronics.ru Git - kernel.git/commit
dm writecache: count number of blocks written, not number of write bios
authorMikulas Patocka <mpatocka@redhat.com>
Mon, 11 Jul 2022 20:31:26 +0000 (16:31 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Aug 2022 12:23:13 +0000 (14:23 +0200)
commitba2e351c11ae45f5f5f6a22e1552b74c654ebb26
tree8530a6f4ebdc19c41c89835e84831a4edf82e500
parent242a4e2e64aac41188c168b25a5467fe2f41799c
dm writecache: count number of blocks written, not number of write bios

[ Upstream commit 887f0e707156c3ddfc1205f0c645d5bcbaf1260d ]

Change dm-writecache, so that it counts the number of blocks written
instead of the number of write bios. Bios can be split and requeued
using the dm_accept_partial_bio function, so counting bios caused
inaccurate results.

Fixes: 2f3825b88d33 ("dm writecache: add event counters")
Reported-by: Yu Kuai <yukuai1@huaweicloud.com>
Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Documentation/admin-guide/device-mapper/writecache.rst
drivers/md/dm-writecache.c