mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-09 18:44:58 -06:00
iotests: Test valid values of l2-cache-entry-size
The l2-cache-entry-size setting can only contain values that are powers of two between 512 and the cluster size. Signed-off-by: Alberto Garcia <berto@igalia.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com> Message-id: bd3547b670b8d0af11480c760991a22bcae5b48c.1517840877.git.berto@igalia.com [mreitz: Changed non-power-of-two test value from 300 to 4242] Signed-off-by: Max Reitz <mreitz@redhat.com>
This commit is contained in:
parent
1221fe6f63
commit
4450c39625
2 changed files with 20 additions and 0 deletions
|
@ -66,6 +66,14 @@ $QEMU_IO -c "open -o cache-size=1M,refcount-cache-size=2M $TEST_IMG" 2>&1 \
|
|||
$QEMU_IO -c "open -o cache-size=0,l2-cache-size=0,refcount-cache-size=0 $TEST_IMG" \
|
||||
2>&1 | _filter_testdir | _filter_imgfmt
|
||||
|
||||
# Invalid cache entry sizes
|
||||
$QEMU_IO -c "open -o l2-cache-entry-size=256 $TEST_IMG" \
|
||||
2>&1 | _filter_testdir | _filter_imgfmt
|
||||
$QEMU_IO -c "open -o l2-cache-entry-size=4242 $TEST_IMG" \
|
||||
2>&1 | _filter_testdir | _filter_imgfmt
|
||||
$QEMU_IO -c "open -o l2-cache-entry-size=128k $TEST_IMG" \
|
||||
2>&1 | _filter_testdir | _filter_imgfmt
|
||||
|
||||
echo
|
||||
echo '=== Testing valid option combinations ==='
|
||||
echo
|
||||
|
@ -94,6 +102,15 @@ $QEMU_IO -c "open -o l2-cache-size=1M,refcount-cache-size=0.25M $TEST_IMG" \
|
|||
-c 'read -P 42 0 64k' \
|
||||
| _filter_qemu_io
|
||||
|
||||
# Valid cache entry sizes
|
||||
$QEMU_IO -c "open -o l2-cache-entry-size=512 $TEST_IMG" \
|
||||
2>&1 | _filter_testdir | _filter_imgfmt
|
||||
$QEMU_IO -c "open -o l2-cache-entry-size=16k $TEST_IMG" \
|
||||
2>&1 | _filter_testdir | _filter_imgfmt
|
||||
$QEMU_IO -c "open -o l2-cache-entry-size=64k $TEST_IMG" \
|
||||
2>&1 | _filter_testdir | _filter_imgfmt
|
||||
|
||||
|
||||
echo
|
||||
echo '=== Testing minimal L2 cache and COW ==='
|
||||
echo
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue