TESTS: fix PREFETCH10/16 tests
This commit is contained in:
@@ -33,7 +33,8 @@ test_prefetch10_0blocks(void)
|
|||||||
ret = prefetch10(iscsic, tgt_lun, 0,
|
ret = prefetch10(iscsic, tgt_lun, 0,
|
||||||
0, 0, 0);
|
0, 0, 0);
|
||||||
if (ret == -2) {
|
if (ret == -2) {
|
||||||
CU_PASS("[SKIPPED] Target does not support PREFETCH10. Skipping test");
|
logging(LOG_NORMAL, "[SKIPPED] PREFETCH10 is not implemented.");
|
||||||
|
CU_PASS("PREFETCH10 is not implemented.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
CU_ASSERT_EQUAL(ret, 0);
|
CU_ASSERT_EQUAL(ret, 0);
|
||||||
|
|||||||
@@ -40,7 +40,8 @@ test_prefetch10_beyond_eol(void)
|
|||||||
ret = prefetch10_lbaoutofrange(iscsic, tgt_lun, num_blocks + 1 - i,
|
ret = prefetch10_lbaoutofrange(iscsic, tgt_lun, num_blocks + 1 - i,
|
||||||
i, 0, 0);
|
i, 0, 0);
|
||||||
if (ret == -2) {
|
if (ret == -2) {
|
||||||
CU_PASS("[SKIPPED] Target does not support PREFETCH10. Skipping test");
|
logging(LOG_NORMAL, "[SKIPPED] PREFETCH10 is not implemented.");
|
||||||
|
CU_PASS("PREFETCH10 is not implemented.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
CU_ASSERT_EQUAL(ret, 0);
|
CU_ASSERT_EQUAL(ret, 0);
|
||||||
|
|||||||
@@ -36,6 +36,11 @@ test_prefetch10_flags(void)
|
|||||||
logging(LOG_VERBOSE, "Test PREFETCH10 with IMMED==1");
|
logging(LOG_VERBOSE, "Test PREFETCH10 with IMMED==1");
|
||||||
ret = prefetch10(iscsic, tgt_lun, 0,
|
ret = prefetch10(iscsic, tgt_lun, 0,
|
||||||
1, 1, 0);
|
1, 1, 0);
|
||||||
|
if (ret == -2) {
|
||||||
|
logging(LOG_NORMAL, "[SKIPPED] PREFETCH10 is not implemented.");
|
||||||
|
CU_PASS("PREFETCH10 is not implemented.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
CU_ASSERT_EQUAL(ret, 0);
|
CU_ASSERT_EQUAL(ret, 0);
|
||||||
|
|
||||||
logging(LOG_VERBOSE, "Test PREFETCH10 with GROUP==3");
|
logging(LOG_VERBOSE, "Test PREFETCH10 with GROUP==3");
|
||||||
|
|||||||
@@ -35,7 +35,8 @@ test_prefetch10_simple(void)
|
|||||||
for (i = 1; i <= 256; i++) {
|
for (i = 1; i <= 256; i++) {
|
||||||
ret = prefetch10(iscsic, tgt_lun, 0, i, 0, 0);
|
ret = prefetch10(iscsic, tgt_lun, 0, i, 0, 0);
|
||||||
if (ret == -2) {
|
if (ret == -2) {
|
||||||
CU_PASS("[SKIPPED] Target does not support PREFETCH10. Skipping test");
|
logging(LOG_NORMAL, "[SKIPPED] PREFETCH10 is not implemented.");
|
||||||
|
CU_PASS("PREFETCH10 is not implemented.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
CU_ASSERT_EQUAL(ret, 0);
|
CU_ASSERT_EQUAL(ret, 0);
|
||||||
|
|||||||
@@ -33,7 +33,8 @@ test_prefetch16_0blocks(void)
|
|||||||
ret = prefetch16(iscsic, tgt_lun, 0,
|
ret = prefetch16(iscsic, tgt_lun, 0,
|
||||||
0, 0, 0);
|
0, 0, 0);
|
||||||
if (ret == -2) {
|
if (ret == -2) {
|
||||||
CU_PASS("[SKIPPED] Target does not support PREFETCH16. Skipping test");
|
logging(LOG_NORMAL, "[SKIPPED] PREFETCH16 is not implemented.");
|
||||||
|
CU_PASS("PREFETCH16 is not implemented.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
CU_ASSERT_EQUAL(ret, 0);
|
CU_ASSERT_EQUAL(ret, 0);
|
||||||
|
|||||||
@@ -35,7 +35,8 @@ test_prefetch16_beyond_eol(void)
|
|||||||
ret = prefetch16_lbaoutofrange(iscsic, tgt_lun, num_blocks + 1 - i,
|
ret = prefetch16_lbaoutofrange(iscsic, tgt_lun, num_blocks + 1 - i,
|
||||||
i, 0, 0);
|
i, 0, 0);
|
||||||
if (ret == -2) {
|
if (ret == -2) {
|
||||||
CU_PASS("[SKIPPED] Target does not support PREFETCH16. Skipping test");
|
logging(LOG_NORMAL, "[SKIPPED] PREFETCH16 is not implemented.");
|
||||||
|
CU_PASS("PREFETCH16 is not implemented.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
CU_ASSERT_EQUAL(ret, 0);
|
CU_ASSERT_EQUAL(ret, 0);
|
||||||
|
|||||||
@@ -36,6 +36,11 @@ test_prefetch16_flags(void)
|
|||||||
logging(LOG_VERBOSE, "Test PREFETCH16 with IMMED==1");
|
logging(LOG_VERBOSE, "Test PREFETCH16 with IMMED==1");
|
||||||
ret = prefetch16(iscsic, tgt_lun, 0,
|
ret = prefetch16(iscsic, tgt_lun, 0,
|
||||||
1, 1, 0);
|
1, 1, 0);
|
||||||
|
if (ret == -2) {
|
||||||
|
logging(LOG_NORMAL, "[SKIPPED] PREFETCH16 is not implemented.");
|
||||||
|
CU_PASS("PREFETCH16 is not implemented.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
CU_ASSERT_EQUAL(ret, 0);
|
CU_ASSERT_EQUAL(ret, 0);
|
||||||
|
|
||||||
logging(LOG_VERBOSE, "Test PREFETCH16 with GROUP==3");
|
logging(LOG_VERBOSE, "Test PREFETCH16 with GROUP==3");
|
||||||
|
|||||||
@@ -35,7 +35,8 @@ test_prefetch16_simple(void)
|
|||||||
for (i = 1; i <= 256; i++) {
|
for (i = 1; i <= 256; i++) {
|
||||||
ret = prefetch16(iscsic, tgt_lun, 0, i, 0, 0);
|
ret = prefetch16(iscsic, tgt_lun, 0, i, 0, 0);
|
||||||
if (ret == -2) {
|
if (ret == -2) {
|
||||||
CU_PASS("[SKIPPED] Target does not support PREFETCH16. Skipping test");
|
logging(LOG_NORMAL, "[SKIPPED] PREFETCH16 is not implemented.");
|
||||||
|
CU_PASS("PREFETCH16 is not implemented.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
CU_ASSERT_EQUAL(ret, 0);
|
CU_ASSERT_EQUAL(ret, 0);
|
||||||
|
|||||||
Reference in New Issue
Block a user