TESTS: add 4MB overlap test to write10_simple
Ceph RADOS block devices split images into 4MB objects. This test ensures that cross object IOs are successful. Signed-off-by: Daniel Oliveira <doliveira@suse.com> Signed-off-by: David Disseldorp <ddiss@suse.de>
This commit is contained in:
committed by
Ronnie Sahlberg
parent
8a44851128
commit
2feb4d40db
@@ -31,6 +31,7 @@ void
|
||||
test_write10_simple(void)
|
||||
{
|
||||
int i;
|
||||
uint32_t lba;
|
||||
|
||||
CHECK_FOR_DATALOSS;
|
||||
|
||||
@@ -55,4 +56,19 @@ test_write10_simple(void)
|
||||
i * block_size, block_size, 0, 0, 0, 0, 0, scratch,
|
||||
EXPECT_STATUS_GOOD);
|
||||
}
|
||||
|
||||
lba = ((4 * 1024 * 1024) / block_size) - 3;
|
||||
if (num_blocks > (lba + 256)) {
|
||||
logging(LOG_VERBOSE,
|
||||
"Test WRITE10 of 1-256 blocks at ~4MB offset");
|
||||
for (i = 1; i <= 256; i++) {
|
||||
if (maximum_transfer_length
|
||||
&& maximum_transfer_length < i) {
|
||||
break;
|
||||
}
|
||||
WRITE10(sd, lba, i * block_size,
|
||||
block_size, 0, 0, 0, 0, 0, scratch,
|
||||
EXPECT_STATUS_GOOD);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user