Page MenuHomeFreeBSD

D30266.1794673090.diff
No OneTemporary

Authored By
Unknown
Size
623 B
Referenced Files
None
Subscribers
None

D30266.1794673090.diff

Index: tools/tools/netmap/pkt-gen.c
===================================================================
--- tools/tools/netmap/pkt-gen.c
+++ tools/tools/netmap/pkt-gen.c
@@ -1816,6 +1816,7 @@
struct netmap_ring *rxring;
int i;
struct my_ctrs cur;
+ uint64_t n = targ->g->npackets / targ->g->nthreads;
memset(&cur, 0, sizeof(cur));
@@ -1866,7 +1867,7 @@
int dump = targ->g->options & OPT_DUMP;
nifp = targ->nmd->nifp;
- while (!targ->cancel) {
+ while (!targ->cancel && (n == 0 || cur.pkts < n)) {
/* Once we started to receive packets, wait at most 1 seconds
before quitting. */
#ifdef BUSYWAIT

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 14, 4:18 PM (10 h, 20 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41727361
Default Alt Text
D30266.1794673090.diff (623 B)

Event Timeline