| 487 | } |
| 488 | |
| 489 | uint64_t |
| 490 | rte_gro_get_pkt_count(void *ctx) |
| 491 | { |
| 492 | struct gro_ctx *gro_ctx = ctx; |
| 493 | gro_tbl_pkt_count_fn pkt_count_fn; |
| 494 | uint64_t gro_types = gro_ctx->gro_types, flag; |
| 495 | uint64_t item_num = 0; |
| 496 | uint8_t i; |
| 497 | |
| 498 | for (i = 0; i < RTE_GRO_TYPE_MAX_NUM && gro_types; i++) { |
| 499 | flag = 1ULL << i; |
| 500 | if ((gro_types & flag) == 0) |
| 501 | continue; |
| 502 | |
| 503 | gro_types ^= flag; |
| 504 | pkt_count_fn = tbl_pkt_count_fn[i]; |
| 505 | if (pkt_count_fn) |
| 506 | item_num += pkt_count_fn(gro_ctx->tbls[i]); |
| 507 | } |
| 508 | |
| 509 | return item_num; |
| 510 | } |
no outgoing calls
no test coverage detected