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
tile: fix build
[dpdk.git]
/
app
/
test
/
test_ring.c
diff --git
a/app/test/test_ring.c
b/app/test/test_ring.c
index
943c350
..
ebcb896
100644
(file)
--- a/
app/test/test_ring.c
+++ b/
app/test/test_ring.c
@@
-100,8
+100,6
@@
#define RING_SIZE 4096
#define MAX_BULK 32
#define RING_SIZE 4096
#define MAX_BULK 32
-#define N 65536
-#define TIME_S 5
static rte_atomic32_t synchro;
static rte_atomic32_t synchro;
@@
-112,7
+110,7
@@
static struct rte_ring *r;
printf("error at %s:%d\tcondition " #exp " failed\n", \
__func__, __LINE__); \
rte_ring_dump(stdout, r); \
printf("error at %s:%d\tcondition " #exp " failed\n", \
__func__, __LINE__); \
rte_ring_dump(stdout, r); \
- return
(-1);
\
+ return
-1;
\
}
#define TEST_RING_FULL_EMTPY_ITER 8
}
#define TEST_RING_FULL_EMTPY_ITER 8
@@
-130,7
+128,7
@@
check_live_watermark_change(__attribute__((unused)) void *dummy)
/* init the object table */
memset(obj_table, 0, sizeof(obj_table));
/* init the object table */
memset(obj_table, 0, sizeof(obj_table));
- end_time = rte_get_timer_cycles() + (hz
* 2
);
+ end_time = rte_get_timer_cycles() + (hz
/ 4
);
/* check that bulk and watermark are 4 and 32 (respectively) */
while (diff >= 0) {
/* check that bulk and watermark are 4 and 32 (respectively) */
while (diff >= 0) {
@@
-194,9
+192,9
@@
test_live_watermark_change(void)
* watermark and quota */
rte_eal_remote_launch(check_live_watermark_change, NULL, lcore_id2);
* watermark and quota */
rte_eal_remote_launch(check_live_watermark_change, NULL, lcore_id2);
- rte_delay_ms(100
0
);
+ rte_delay_ms(100);
rte_ring_set_water_mark(r, 32);
rte_ring_set_water_mark(r, 32);
- rte_delay_ms(100
0
);
+ rte_delay_ms(100);
if (rte_eal_wait_lcore(lcore_id2) < 0)
return -1;
if (rte_eal_wait_lcore(lcore_id2) < 0)
return -1;
@@
-274,7
+272,7
@@
test_ring_basic_full_empty(void * const src[], void *dst[])
TEST_RING_VERIFY(0 == memcmp(src, dst, rsz));
rte_ring_dump(stdout, r);
}
TEST_RING_VERIFY(0 == memcmp(src, dst, rsz));
rte_ring_dump(stdout, r);
}
- return
(0)
;
+ return
0
;
}
static int
}
static int
@@
-1380,8
+1378,4
@@
test_ring(void)
return 0;
}
return 0;
}
-static struct test_command ring_cmd = {
- .command = "ring_autotest",
- .callback = test_ring,
-};
-REGISTER_TEST_COMMAND(ring_cmd);
+REGISTER_TEST_COMMAND(ring_autotest, test_ring);