event/dlb2: fix delayed pop test in selftest
Number of events scheduled and available for dequeue
after token pop was set to dequeue_depth-1 instead of
dequeue_depth in test_delayed_pop. The expectation is
that all dequeue_depth number of events can be dequeued
once the last event is released.
Fixes: 07d55c418d
("event/dlb2: add delayed token pop logic")
Cc: stable@dpdk.org
Signed-off-by: Rashmi Shetty <rashmi.shetty@intel.com>
Reviewed-by: Mike Ximing Chen <mike.ximing.chen@intel.com>
This commit is contained in:
parent
bd99189724
commit
5fe46ce055
@ -1354,7 +1354,7 @@ test_delayed_pop(void)
|
||||
}
|
||||
|
||||
/* Release one more event. This will trigger the token pop, and
|
||||
* dequeue_depth - 1 more events will be scheduled to the device.
|
||||
* dequeue_depth more events will be scheduled to the device.
|
||||
*/
|
||||
ev.op = RTE_EVENT_OP_RELEASE;
|
||||
|
||||
@ -1366,7 +1366,7 @@ test_delayed_pop(void)
|
||||
|
||||
timeout = 0xFFFFFFFFF;
|
||||
|
||||
for (i = 0; i < port_conf.dequeue_depth - 1; i++) {
|
||||
for (i = 0; i < port_conf.dequeue_depth; i++) {
|
||||
if (rte_event_dequeue_burst(evdev, 0, &ev, 1, timeout) != 1) {
|
||||
printf("%d: event dequeue expected to succeed\n",
|
||||
__LINE__);
|
||||
@ -1374,14 +1374,6 @@ test_delayed_pop(void)
|
||||
}
|
||||
}
|
||||
|
||||
timeout = 0x10000;
|
||||
|
||||
if (rte_event_dequeue_burst(evdev, 0, &ev, 1, timeout) != 0) {
|
||||
printf("%d: event dequeue expected to fail\n",
|
||||
__LINE__);
|
||||
goto err;
|
||||
}
|
||||
|
||||
cleanup();
|
||||
return 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user