Skip to contentSkip to conversation

bcache: add initial test cases

PATCH In review Daniel Wagner 4 participants 16 messages Mar 5 – Mar 12

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

v5 cover bcache: add initial test cases

I've addressed all comments from Shinichiro.

bcache/002 is not using iostat anymore, instead it reads directly from sysfs. Also updated this tests according Stephen's feedback. I didn't test yet with an older version.

Unfortunatly, I was not able to reproduce the "nvme?n1" file in my setup with:

TEST_CASE_DEV_ARRAY[bcache/*]="/dev/nvme0n1 /dev/vdb /dev/vdc" TEST_CASE_DEV_ARRAY[bcache/*]="/dev/nvme0n1 /dev/vdb /dev/vdc /dev/nvme1n1"

Not sure where this is coming from.

Cheers,
Daniel

Cc Christoph Hellwig <[email protected]>
Cc Stephen Zhang <[email protected]>
Cc Kent Overstreet <[email protected]>
Cc Coly Li <[email protected]>
Cc Shin'ichiro Kawasaki <[email protected]>
Cc Johannes Thumshirn <[email protected]>

--- Changes in v5:
- Addressed all comments from Shinichiro
- Updated bcache/002 according Stepen's feedback, though reduced fio's runtime to 10s
- Link to v4: https://patch.msgid.link/[email protected]

Changes in v4:
- changed file mode to 755 for 001 and 002
- changed license to GPL-3.0+
- use group_requires
- fixed whitespace damage
- dropped unnecessary '|| true'
- added 'local' for local variables
- added wait loop for register interface to show up
- updated documentation
- Link to v3: https://patch.msgid.link/[email protected]

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/[email protected]

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/[email protected]

---
Daniel Wagner (3):
bcache: add bcache/001
bcache: add bcache/002
doc: document how to configure bcache tests

 Documentation/running-tests.md |  10 ++
 tests/bcache/001               |  44 +++++
 tests/bcache/001.out           |   3 +
 tests/bcache/002               |  78 +++++++++
 tests/bcache/002.out           |   2 +
 tests/bcache/rc                | 377 +++++++++++++++++++++++++++++++++++++++++
 6 files changed, 514 insertions(+)

---
base-commit: e387a7e0169cc012eb6a7140a0561d2901c92a76
change-id: 20260120-bcache-35ec7368c8f4

Best regards,

Signature · 1 line
Daniel Wagner <[email protected]>
#1 lore raw

PATCH v5 1/3 bcache: add bcache/001

So far we are missing tests for bcache. Besides a relative simple setup/teardown tests add also the corresponding infrastructure. More tests are to be expected to depend on this.

_create_bcache/_remove_bcache are tracking the resources and if anything is missing it will complain.

---
 tests/bcache/001     |  44 ++++++
 tests/bcache/001.out |   3 +
 tests/bcache/rc      | 377 +++++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 424 insertions(+)
tests/bcache/001 new file +44 -0
new file mode 100755
index 000000000000..64d5d45d9e6e
@@ -0,0 +1,44 @@
+#!/bin/bash
+# SPDX-License-Identifier: GPL-3.0+
+# Copyright (C) 2026 Daniel Wagner, SUSE Labs
+#
+# Test bcache setup and teardown
+
+. tests/bcache/rc
+
+DESCRIPTION="test bcache setup and teardown"
+
+test_device_array() {
+	echo "Running ${TEST_NAME}"
+
+	if [[ ${#TEST_DEV_ARRAY[@]} -lt 3 ]]; then
+		SKIP_REASONS+=("requires at least 3 devices")
+		return 1
+	fi
+
+	_setup_bcache "${TEST_DEV_ARRAY[@]}"
+
+	local -a bcache_nodes
+
+	mapfile -t bcache_nodes < <(_create_bcache \
+				--cache "${TEST_DEV_ARRAY[0]##*/}" \
+				--bdev "${TEST_DEV_ARRAY[1]##*/}" \
+				--writeback)
+
+	echo "number of bcaches: ${#bcache_nodes[*]}"
+
+	_remove_bcache --bcache "${bcache_nodes[@]}" \
+			--cache "${TEST_DEV_ARRAY[0]##*/}" \
+			--bdev "${TEST_DEV_ARRAY[1]##*/}" \
+
+	mapfile -t bcache_nodes < <(_create_bcache \
+				--cache "${TEST_DEV_ARRAY[0]##*/}" \
+				--bdev "${TEST_DEV_ARRAY[1]##*/}" "${TEST_DEV_ARRAY[2]##*/}" \
+				--writeback)
+
+	echo "number of bcaches: ${#bcache_nodes[*]}"
+
+	_remove_bcache --bcache "${bcache_nodes[@]}" \
+			--cache "${TEST_DEV_ARRAY[0]##*/}" \
+			--bdev "${TEST_DEV_ARRAY[1]##*/}" "${TEST_DEV_ARRAY[2]##*/}"
+}
tests/bcache/001.out new file +3 -0
new file mode 100644
index 000000000000..844154e13822
@@ -0,0 +1,3 @@
+Running bcache/001
+number of bcaches: 1
+number of bcaches: 2
tests/bcache/rc new file +377 -0

377 lines not on this page · raw message

Signature · 1 line
2.53.0
#3 lore raw

Re: [PATCH blktests v5 1/3] bcache: add bcache/001

In reply to Daniel Wagner
Quoted 19 lines · Daniel Wagner

So far we are missing tests for bcache. Besides a relative simple setup/teardown tests add also the corresponding infrastructure. More tests are to be expected to depend on this.

_create_bcache/_remove_bcache are tracking the resources and if anything is missing it will complain.

---
 tests/bcache/001     |  44 ++++++
 tests/bcache/001.out |   3 +
 tests/bcache/rc      | 377 +++++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 424 insertions(+)
tests/bcache/001 new file +0 -0
new file mode 100755
index 000000000000..64d5d45d9e6e

[...]

Quoted 7 lines
tests/bcache/001 new file +7 -0
+_create_bcache() {
+	local -a cdevs=()
+	local -a bdevs=()
+	local -a ARGS=()
+	local -a created_devs=()
+	local bucket_size="64k"
+	local block_size="4k"

[...]

tests/bcache/001

Quoted 3 lines
tests/bcache/001 new file +3 -0
+	# add /dev prefix to device names
+	cdevs=( "${cdevs[@]/#/\/dev\/}" )
+	bdevs=( "${bdevs[@]/#/\/dev\/}" )

Here, /dev/ prefix is added to arguments of _bcache_wipe_devs() call below.

Quoted 3 lines
tests/bcache/001 new file +3 -0
+
+	# make-bcache expects empty/cleared devices
+	_bcache_wipe_devs "${cdevs[@]}" "${bdevs[@]}"

[...]

Quoted 6 lines
tests/bcache/001 new file +6 -0
+_remove_bcache() {
+	local -a cdevs=()
+	local -a bdevs=()
+	local -a csets=()
+	local -a bcache_devs=()
+	local uuid

[...]

tests/bcache/001

Quoted 8 lines
tests/bcache/001 new file +8 -0
+	local timeout
+	for cset in "${csets[@]}"; do
+		timeout=0
+		while [[ -d /sys/fs/bcache/"${cset}" ]] && (( timeout < 10 )); do
+			sleep 0.5
+			(( timeout++ ))
+		done
+	done

However, /dev prefix is not added here for the _bcache_wipe_devs() call below. I added the hunk below, then observed the nvme?n1 files are no longer created in my environment.

       # add /dev prefix to device names
       cdevs=( "${cdevs[@]/#/\/dev\/}" )
       bdevs=( "${bdevs[@]/#/\/dev\/}" )

Other than this, this patch looks good to me. If you are okay with it, I can fold-in the change above when I apply this patch.

Quoted 3 lines
tests/bcache/001 new file +3 -0
+
+	_bcache_wipe_devs "${cdevs[@]}" "${bdevs[@]}"
+}
#4 lore raw

Re: [PATCH blktests v5 1/3] bcache: add bcache/001

Quoted 34 lines

tests/bcache/rc line 135

Quoted 3 lines
tests/bcache/rc new file +3 -0
+	# add /dev prefix to device names
+	cdevs=( "${cdevs[@]/#/\/dev\/}" )
+	bdevs=( "${bdevs[@]/#/\/dev\/}" )

Here, /dev/ prefix is added to arguments of _bcache_wipe_devs() call below.

Quoted 3 lines
tests/bcache/rc new file +3 -0
+
+	# make-bcache expects empty/cleared devices
+	_bcache_wipe_devs "${cdevs[@]}" "${bdevs[@]}"

[...]

Quoted 6 lines
tests/bcache/rc new file +6 -0
+_remove_bcache() {
+	local -a cdevs=()
+	local -a bdevs=()
+	local -a csets=()
+	local -a bcache_devs=()
+	local uuid

[...]

tests/bcache/rc line 294

Quoted 8 lines
tests/bcache/rc new file +8 -0
+	local timeout
+	for cset in "${csets[@]}"; do
+		timeout=0
+		while [[ -d /sys/fs/bcache/"${cset}" ]] && (( timeout < 10 )); do
+			sleep 0.5
+			(( timeout++ ))
+		done
+	done

However, /dev prefix is not added here for the _bcache_wipe_devs() call below. I added the hunk below, then observed the nvme?n1 files are no longer created in my environment.

Quoted 6 lines
       # add /dev prefix to device names
       cdevs=( "${cdevs[@]/#/\/dev\/}" )
       bdevs=( "${bdevs[@]/#/\/dev\/}" )

Other than this, this patch looks good to me. If you are okay with it, I can fold-in the change above when I apply this patch.

No objection from me, please go ahead!

#5 lore raw

PATCH v5 2/3 bcache: add bcache/002

In reply to Daniel Wagner

Add test case from Stephen Zhang [1][2], which is

1. Wait for fio to complete (wait $fio_pid)
2. Wait a few seconds for I/O to drain
3. Then check the utilization

If utilization is still > 0% after I/O completes, then there's a real accounting leak.

[1] https://lore.kernel.org/linux-bcache/CANubcdX7eNbH_bo4-f94DUbdiEbt04Vxy1MPyhm+CZyXB01FuQ@mail.gmail.com/
[2] https://lore.kernel.org/all/CANubcdU92Uv7wNdZH357LLTnfwPouekXNTPSjHnzYzK99-eZ9w@mail.gmail.com

---
 tests/bcache/002     | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 tests/bcache/002.out |  2 ++
 2 files changed, 80 insertions(+)
tests/bcache/002 new file +78 -0
new file mode 100755
index 000000000000..a50722ff9e0e
@@ -0,0 +1,78 @@
+#!/bin/bash
+# SPDX-License-Identifier: GPL-3.0+
+# Copyright (C) 2026 Daniel Wagner, SUSE Labs
+#
+# Test based on Stephen Zhang <[email protected]> test case
+# https://lore.kernel.org/linux-bcache/CANubcdX7eNbH_bo4-f94DUbdiEbt04Vxy1MPyhm+CZyXB01FuQ@mail.gmail.com/#t
+#
+# Test bcache for bio leaks in clone
+
+. tests/bcache/rc
+
+DESCRIPTION="test bcache for bio leaks in clone"
+
+requires() {
+	_have_fio
+}
+
+read_ticks() {
+	local bdev_name="$1"
+	local stat_file
+
+	stat_file="/sys/block/${bdev_name}/stat"
+	awk '{print $10}' "$stat_file"
+}
+
+get_utilization() {
+	local bdev_name="$1"
+	local t1 t2
+
+	t1="$(read_ticks ${bdev_name})"
+	sleep 1
+	t2="$(read_ticks ${bdev_name})"
+
+	# (t2 - t1) is the ms busy. Over 1000ms, (delta/10) gives percentage.
+	echo "scale=2; ($t2 - $t1) / 10" | bc
+}
+
+test_device_array() {
+	echo "Running ${TEST_NAME}"
+
+	if [[ ${#TEST_DEV_ARRAY[@]} -lt 2 ]]; then
+		SKIP_REASONS+=("requires at least 2 devices")
+		return 1
+	fi
+
+	_setup_bcache "${TEST_DEV_ARRAY[@]}"
+
+	local -a bcache_nodes
+	local bcache_dev bdev_name fio_pid state
+
+	mapfile -t bcache_nodes < <(_create_bcache \
+				--cache "${TEST_DEV_ARRAY[0]##*/}" \
+				--bdev "${TEST_DEV_ARRAY[1]##*/}" \
+				--writeback)
+
+	bcache_dev="${bcache_nodes[0]}"
+	bdev_name="$(basename "${bcache_dev}")"
+	echo 1 > /sys/block/"${bdev_name}"/bcache/detach
+
+	state="$(cat /sys/block/"${bdev_name}"/bcache/state)"
+	echo "Device state: ${state}"
+
+	_run_fio_rand_io --filename="${bcache_dev}" --time_base \
+			--runtime=10 >> "$FULL" 2>&1 
+	
+	sleep 5
+
+	local util
+	util="$(get_utilization "${bdev_name}")"
+
+	if (( $(echo "${util} > 1.0" | bc --mathlib) )); then
+		echo "ERROR: Accounting leak detected! Current utilization: ${util}%"
+	fi
+
+	_remove_bcache --bcache "${bcache_nodes[@]}" \
+			--cache "${TEST_DEV_ARRAY[0]##*/}" \
+			--bdev "${TEST_DEV_ARRAY[1]##*/}"
+}
tests/bcache/002.out new file +2 -0
new file mode 100644
index 000000000000..529c1a90b135
@@ -0,0 +1,2 @@
+Running bcache/002
+Device state: no cache
Signature · 1 line
2.53.0
#7 lore raw

Re: [PATCH blktests v5 2/3] bcache: add bcache/002

In reply to Daniel Wagner
Quoted 11 lines · Daniel Wagner

Add test case from Stephen Zhang [1][2], which is

1. Wait for fio to complete (wait $fio_pid)
2. Wait a few seconds for I/O to drain
3. Then check the utilization

If utilization is still > 0% after I/O completes, then there's a real accounting leak.

[1] https://lore.kernel.org/linux-bcache/CANubcdX7eNbH_bo4-f94DUbdiEbt04Vxy1MPyhm+CZyXB01FuQ@mail.gmail.com/
[2] https://lore.kernel.org/all/CANubcdU92Uv7wNdZH357LLTnfwPouekXNTPSjHnzYzK99-eZ9w@mail.gmail.com

Thanks for the updates. It's good that we do not need iostat :)

I ran this test case with v7.0-rc2 kernel, and it passes. Good.

I also ran this test case with older kernel without the kernel fix [1]. I expected failure, but it passed. I ran the Stephen's original test script and it did not fail either. So I guess my test environment does not fulfill the conditions to recreate the failure. Daniel, did you observe this test case failed with any older kernel?

Let me leave nit comments in line. If this patch does not respin, I can fold in the changes for the nit comments.

Quoted 18 lines
---
 tests/bcache/002     | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 tests/bcache/002.out |  2 ++
 2 files changed, 80 insertions(+)
tests/bcache/002 new file +5 -0
new file mode 100755
index 000000000000..a50722ff9e0e
@@ -0,0 +1,78 @@
+#!/bin/bash
+# SPDX-License-Identifier: GPL-3.0+
+# Copyright (C) 2026 Daniel Wagner, SUSE Labs
+#
+# Test based on Stephen Zhang <[email protected]> test case

tests/bcache/002 line 15

Quoted 10 lines
tests/bcache/002 new file +10 -0
+# https://lore.kernel.org/linux-bcache/CANubcdX7eNbH_bo4-f94DUbdiEbt04Vxy1MPyhm+CZyXB01FuQ@mail.gmail.com/#t
+#
+# Test bcache for bio leaks in clone
+
+. tests/bcache/rc
+
+DESCRIPTION="test bcache for bio leaks in clone"
+
+requires() {
+	_have_fio

I forgot to mention that we need,

_have_program bc

here. Let me fold-in this change.

Quoted 5 lines
tests/bcache/002 new file +5 -0
+}
+
+read_ticks() {
+	local bdev_name="$1"
+	local stat_file

tests/bcache/002 line 30

Quoted 10 lines
tests/bcache/002 new file +10 -0
+
+	stat_file="/sys/block/${bdev_name}/stat"
+	awk '{print $10}' "$stat_file"
+}
+
+get_utilization() {
+	local bdev_name="$1"
+	local t1 t2
+
+	t1="$(read_ticks ${bdev_name})"

Nit: for shellcheck, the line above should be,

	t1="$(read_ticks "${bdev_name}")"

tests/bcache/002 line 32

Quoted 2 lines
tests/bcache/002 new file +2 -0
+	sleep 1
+	t2="$(read_ticks ${bdev_name})"

Same here:

	t2="$(read_ticks "${bdev_name}")"
Quoted 7 lines
tests/bcache/002 new file +7 -0
+
+	# (t2 - t1) is the ms busy. Over 1000ms, (delta/10) gives percentage.
+	echo "scale=2; ($t2 - $t1) / 10" | bc
+}
+
+test_device_array() {
+	echo "Running ${TEST_NAME}"

tests/bcache/002 line 49

Quoted 10 lines
tests/bcache/002 new file +10 -0
+
+	if [[ ${#TEST_DEV_ARRAY[@]} -lt 2 ]]; then
+		SKIP_REASONS+=("requires at least 2 devices")
+		return 1
+	fi
+
+	_setup_bcache "${TEST_DEV_ARRAY[@]}"
+
+	local -a bcache_nodes
+	local bcache_dev bdev_name fio_pid state

Nit: for shellcheck, unused 'fio_pid' should be dropped.

local bcache_dev bdev_name state

Quoted 6 lines
tests/bcache/002 new file +6 -0
+
+	mapfile -t bcache_nodes < <(_create_bcache \
+				--cache "${TEST_DEV_ARRAY[0]##*/}" \
+				--bdev "${TEST_DEV_ARRAY[1]##*/}" \
+				--writeback)
+

tests/bcache/002 line 65

Quoted 10 lines
tests/bcache/002 new file +10 -0
+	bcache_dev="${bcache_nodes[0]}"
+	bdev_name="$(basename "${bcache_dev}")"
+	echo 1 > /sys/block/"${bdev_name}"/bcache/detach
+
+	state="$(cat /sys/block/"${bdev_name}"/bcache/state)"
+	echo "Device state: ${state}"
+
+	_run_fio_rand_io --filename="${bcache_dev}" --time_base \
+			--runtime=10 >> "$FULL" 2>&1 
+	

Nit: a stray tab and a space in the above two lines.

#8 lore raw

Re: [PATCH blktests v5 2/3] bcache: add bcache/002

Quoted 15 lines · Shinichiro Kawasaki
Quoted 11 lines · Daniel Wagner

Add test case from Stephen Zhang [1][2], which is

1. Wait for fio to complete (wait $fio_pid)
2. Wait a few seconds for I/O to drain
3. Then check the utilization

If utilization is still > 0% after I/O completes, then there's a real accounting leak.

[1] https://lore.kernel.org/linux-bcache/CANubcdX7eNbH_bo4-f94DUbdiEbt04Vxy1MPyhm+CZyXB01FuQ@mail.gmail.com/
[2] https://lore.kernel.org/all/CANubcdU92Uv7wNdZH357LLTnfwPouekXNTPSjHnzYzK99-eZ9w@mail.gmail.com

Thanks for the updates. It's good that we do not need iostat :)

Quoted 7 lines

I ran this test case with v7.0-rc2 kernel, and it passes. Good.

I also ran this test case with older kernel without the kernel fix [1]. I expected failure, but it passed. I ran the Stephen's original test script and it did not fail either. So I guess my test environment does not fulfill the conditions to recreate the failure. Daniel, did you observe this test case failed with any older kernel?

Same here, it doesn't fail on older kernels either. Maybe we should just not merge this test then? Maybe Stephen can have a look and figure out what needs to be done to trigger the condition more reliable.

Quoted 2 lines

Let me leave nit comments in line. If this patch does not respin, I can fold in the changes for the nit comments.

Sure, just fix it up if you decide to apply it.

Thanks!
Daniel

#9 lore raw

Re: [PATCH blktests v5 2/3] bcache: add bcache/002

Quoted 24 lines · Daniel Wagner
Quoted 15 lines · Shinichiro Kawasaki
Quoted 11 lines · Daniel Wagner

Add test case from Stephen Zhang [1][2], which is

1. Wait for fio to complete (wait $fio_pid)
2. Wait a few seconds for I/O to drain
3. Then check the utilization

If utilization is still > 0% after I/O completes, then there's a real accounting leak.

[1] https://lore.kernel.org/linux-bcache/CANubcdX7eNbH_bo4-f94DUbdiEbt04Vxy1MPyhm+CZyXB01FuQ@mail.gmail.com/
[2] https://lore.kernel.org/all/CANubcdU92Uv7wNdZH357LLTnfwPouekXNTPSjHnzYzK99-eZ9w@mail.gmail.com

Thanks for the updates. It's good that we do not need iostat :)

Quoted 7 lines

I ran this test case with v7.0-rc2 kernel, and it passes. Good.

I also ran this test case with older kernel without the kernel fix [1]. I expected failure, but it passed. I ran the Stephen's original test script and it did not fail either. So I guess my test environment does not fulfill the conditions to recreate the failure. Daniel, did you observe this test case failed with any older kernel?

Quoted 3 lines

Same here, it doesn't fail on older kernels either. Maybe we should just not merge this test then? Maybe Stephen can have a look and figure out what needs to be done to trigger the condition more reliable.

I see. Before merging this patch, I would like to make sure that this test case is valuable, and it does not just waste time and power of CI systems.

Stephen,

May I ask you to share what kind of devices you used to recreate the failure? Also, could you share the kernel .config to recreate the failure? I would like use them to recreate the failure on my test system.

Quoted 5 lines
Quoted 3 lines

Let me leave nit comments in line. If this patch does not respin, I can fold in the changes for the nit comments.

Sure, just fix it up if you decide to apply it.

Got it, thanks.

#10 lore raw

Re: [PATCH blktests v5 2/3] bcache: add bcache/002

Quoted 1 line · Shinichiro Kawasaki <[email protected]> 于2026年3月7日周六 18:24写道:

...

Quoted 5 lines

May I ask you to share what kind of devices you used to recreate the failure? Also, could you share the kernel .config to recreate the failure? I would like use them to recreate the failure on my test system.

Hmm, I tried to reproduce the issue again but couldn't.

#11 lore raw

Re: [PATCH blktests v5 2/3] bcache: add bcache/002

Quoted 10 lines · Stephen Zhang
Quoted 1 line · Shinichiro Kawasaki <[email protected]> 于2026年3月7日周六 18:24写道:

...

Quoted 5 lines

May I ask you to share what kind of devices you used to recreate the failure? Also, could you share the kernel .config to recreate the failure? I would like use them to recreate the failure on my test system.

Hmm, I tried to reproduce the issue again but couldn't.

Stephen, thanks. Then I think the left key difference between bcache/001 and this new bcache/002 is 10 seconds fio random read. IMO, it's the better to drop this patch, and create another test case that intend to exercise bcache driver using fio workloads. To add more value to the test case, I think verify workload is the better, that will check write, read, as well as no data corruption.

#12 lore raw

PATCH v5 3/3 doc: document how to configure bcache tests

In reply to Daniel Wagner

Add a bcache entry in running-tests which explains how to configure blktests for the bcache tests.

---
 Documentation/running-tests.md | 10 ++++++++++
 1 file changed, 10 insertions(+)
Documentation/running-tests.md +10 -0
index f9da042bb3a0..7d935aad3331 100644
@@ -189,6 +189,16 @@ THROTL_BLKDEV_TYPES="sdebug" ./check throtl/
 THROTL_BLKDEV_TYPES="nullb sdebug" ./check throtl/
 ```
 
+### Bcache test configuration
+
+The bcache tests require multiple devices to run simultaneously. By default,
+blktests run each test case for each device in TEST_DEVS. This behavior
+prevents testing with multiple devices. The TEST_CASE_DEV_ARRAY resolves this by
+enabling multiple device configurations per test. Bcache tests need at
+least three devices, which can be specified in your configuration as follows:
+
+TEST_CASE_DEV_ARRAY[bcache/*]="/dev/nvme0n1 /dev/vdb /dev/vdc"
+
 ### Normal user
 
 To run test cases which require normal user privilege, prepare a user and
Signature · 1 line
2.53.0
#14 lore raw
In reply to Daniel Wagner
Quoted 16 lines · Daniel Wagner

I've addressed all comments from Shinichiro.

bcache/002 is not using iostat anymore, instead it reads directly from sysfs. Also updated this tests according Stephen's feedback. I didn't test yet with an older version.

Unfortunatly, I was not able to reproduce the "nvme?n1" file in my setup with:

TEST_CASE_DEV_ARRAY[bcache/*]="/dev/nvme0n1 /dev/vdb /dev/vdc" TEST_CASE_DEV_ARRAY[bcache/*]="/dev/nvme0n1 /dev/vdb /dev/vdc /dev/nvme1n1"

Not sure where this is coming from.

Cheers,
Daniel

Quoted 9 lines
Cc Christoph Hellwig <[email protected]>
Cc Stephen Zhang <[email protected]>
Cc Kent Overstreet <[email protected]>
Cc Coly Li <[email protected]>
Cc Shin'ichiro Kawasaki <[email protected]>
Cc Johannes Thumshirn <[email protected]>

Daniel, thank you for this effot. FYI, I applied the 1st (with my fix) and the 3rd patch. Let's do some more effort to confirm the value of the 2nd patch.

#15 lore raw
Quoted 3 lines · Shinichiro Kawasaki

Daniel, thank you for this effot. FYI, I applied the 1st (with my fix) and the 3rd patch. Let's do some more effort to confirm the value of the 2nd patch.

Thanks! FWIW, it should be hopefully fairly simple to add some more tests based on:

https://evilpiepirate.org/git/ktest.git/tree/tests/bcache

This should cover some more ground.