git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
net/bnxt: fix null dereference in session cleanup
[dpdk.git]
/
app
/
test
/
test_service_cores.c
diff --git
a/app/test/test_service_cores.c
b/app/test/test_service_cores.c
index
ece1040
..
ced6ed0
100644
(file)
--- a/
app/test/test_service_cores.c
+++ b/
app/test/test_service_cores.c
@@
-68,7
+68,7
@@
static int32_t dummy_mt_unsafe_cb(void *args)
rte_delay_ms(250);
__atomic_store_n(lock, 0, __ATOMIC_RELAXED);
} else {
rte_delay_ms(250);
__atomic_store_n(lock, 0, __ATOMIC_RELAXED);
} else {
- /* 2nd thread will fail to take lock, so
set
pass flag */
+ /* 2nd thread will fail to take lock, so
clear
pass flag */
*pass_test = 0;
}
*pass_test = 0;
}
@@
-318,10
+318,16
@@
service_attr_get(void)
TEST_ASSERT_EQUAL(1, cycles_gt_zero,
"attr_get() failed to get cycles (expected > zero)");
TEST_ASSERT_EQUAL(1, cycles_gt_zero,
"attr_get() failed to get cycles (expected > zero)");
- rte_service_lcore_stop(slcore_id);
+ TEST_ASSERT_EQUAL(0, rte_service_map_lcore_set(id, slcore_id, 0),
+ "Disabling valid service and core failed");
+ TEST_ASSERT_EQUAL(0, rte_service_lcore_stop(slcore_id),
+ "Failed to stop service lcore");
wait_slcore_inactive(slcore_id);
wait_slcore_inactive(slcore_id);
+ TEST_ASSERT_EQUAL(0, rte_service_lcore_may_be_active(slcore_id),
+ "Service lcore not stopped after waiting.");
+
TEST_ASSERT_EQUAL(0, rte_service_attr_get(id, attr_calls, &attr_value),
"Valid attr_get() call didn't return success");
TEST_ASSERT_EQUAL(1, (attr_value > 0),
TEST_ASSERT_EQUAL(0, rte_service_attr_get(id, attr_calls, &attr_value),
"Valid attr_get() call didn't return success");
TEST_ASSERT_EQUAL(1, (attr_value > 0),