Commit 9f7dfb1
samples/bpf: xdpsock: add time-out for cleaning Tx
When user sets tx-pkt-count and in case where there are invalid Tx frame,
the complete_tx_only_all() process polls indefinitely. So, this patch
adds a time-out mechanism into the process so that the application
can terminate automatically after it retries 3*polling interval duration.
sock0@enp0s29f1:2 txonly xdp-drv
pps pkts 1.00
rx 0 0
tx 136383 1000000
rx dropped 0 0
rx invalid 0 0
tx invalid 35 245
rx queue full 0 0
fill ring empty 0 1
tx ring empty 957 7011
sock0@enp0s29f1:2 txonly xdp-drv
pps pkts 1.00
rx 0 0
tx 0 1000000
rx dropped 0 0
rx invalid 0 0
tx invalid 0 245
rx queue full 0 0
fill ring empty 0 1
tx ring empty 1 7012
sock0@enp0s29f1:2 txonly xdp-drv
pps pkts 1.00
rx 0 0
tx 0 1000000
rx dropped 0 0
rx invalid 0 0
tx invalid 0 245
rx queue full 0 0
fill ring empty 0 1
tx ring empty 1 7013
sock0@enp0s29f1:2 txonly xdp-drv
pps pkts 1.00
rx 0 0
tx 0 1000000
rx dropped 0 0
rx invalid 0 0
tx invalid 0 245
rx queue full 0 0
fill ring empty 0 1
tx ring empty 1 7014
sock0@enp0s29f1:2 txonly xdp-drv
pps pkts 1.00
rx 0 0
tx 0 1000000
rx dropped 0 0
rx invalid 0 0
tx invalid 0 245
rx queue full 0 0
fill ring empty 0 1
tx ring empty 0 7014
sock0@enp0s29f1:2 txonly xdp-drv
pps pkts 0.00
rx 0 0
tx 0 1000000
rx dropped 0 0
rx invalid 0 0
tx invalid 0 245
rx queue full 0 0
fill ring empty 0 1
tx ring empty 0 7014
Signed-off-by: Ong Boon Leong <[email protected]>1 parent 38ab5f4 commit 9f7dfb1
1 file changed
+3
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1410 | 1410 | | |
1411 | 1411 | | |
1412 | 1412 | | |
| 1413 | + | |
1413 | 1414 | | |
1414 | 1415 | | |
1415 | 1416 | | |
| |||
1421 | 1422 | | |
1422 | 1423 | | |
1423 | 1424 | | |
1424 | | - | |
| 1425 | + | |
| 1426 | + | |
1425 | 1427 | | |
1426 | 1428 | | |
1427 | 1429 | | |
| |||
0 commit comments