| From: |
| Daniel Wagner <dwagner-AT-suse.de> |
| To: |
| Christoph Hellwig <hch-AT-infradead.org>, Stephen Zhang <starzhangzsd-AT-gmail.com>, Kent Overstreet <kent.overstreet-AT-linux.dev>, Coly Li <colyli-AT-fnnas.com>, Shin'ichiro Kawasaki <shinichiro.kawasaki-AT-wdc.com>, Johannes Thumshirn <Johannes.Thumshirn-AT-wdc.com>, linux-block-AT-vger.kernel.org, linux-bcache-AT-vger.kernel.org, Daniel Wagner <dwagner-AT-suse.de> |
| Subject: |
| [PATCH blktests v3 0/3] bcache: add initial test cases |
| Date: |
| Thu, 22 Jan 2026 10:57:11 +0100 |
| Message-ID: |
| <20260122-bcache-v3-0-2c02d15a4503@suse.de> |
| Archive-link: |
| Article |
I've added the test case from Stephen [1] which showed all the limitation in v2.
The cleanup code should be more robust now. The new test case reports
bcache/001 => nvme0n1 vdb vdc (test bcache setup and teardown) [passed]
runtime 1.373s ... 1.334s
bcache/002 => nvme0n1 vdb vdc (test bcache for bio leaks in clone) [failed]
runtime 7.360s ... 7.336s
--- tests/bcache/002.out 2026-01-22 09:49:22.379130632 +0000
+++ /tmp/blktests/nvme0n1_vdb_vdc/bcache/002.out.bad 2026-01-22 09:49:39.343331470 +0000
@@ -1,2 +1,3 @@
Running bcache/002
Device state: no cache
+ERROR: Accounting leak detected!
So it seems to do something. Though I think it could look at sysfs values
directly isntead using iostat. Though that's for another time.
I wont work on this in the next two weeks as I am on vacation. So no hurry to
review :)
Cheers,
Daniel
[1] https://lore.kernel.org/linux-bcache/CANubcdX7eNbH_bo4-f9...
Signed-off-by: Daniel Wagner <dwagner@suse.de>
---
Changes in v3:
- add bcache/002
- return created bcache devices to tests case
- made cleanup more robust (handling detached cache)
- track all resources correctly
- operatoe only in final cleanup on known devices
- Link to v2: https://patch.msgid.link/20260121-bcache-v2-0-b26af185e63...
Changes in v2:
- fixed whitespace damage
- added documentation on how to configure for bcache tests
- do registering explicitly
- made disk wiping more robust
- Link to v1: https://patch.msgid.link/20260120-bcache-v1-1-59bf0b2d414...
---
Daniel Wagner (3):
bcache: add bcache/001
bcache: add bcache/002
doc: document how to configure bcache tests
Documentation/running-tests.md | 16 ++
tests/bcache/001 | 48 ++++++
tests/bcache/001.out | 3 +
tests/bcache/002 | 63 +++++++
tests/bcache/002.out | 2 +
tests/bcache/rc | 368 +++++++++++++++++++++++++++++++++++++++++
6 files changed, 500 insertions(+)
---
base-commit: e387a7e0169cc012eb6a7140a0561d2901c92a76
change-id: 20260120-bcache-35ec7368c8f4
Best regards,
--
Daniel Wagner <dwagner@suse.de>