| 415 | } |
| 416 | |
| 417 | static void |
| 418 | acl_calc_counts_indices(struct acl_node_counters *counts, |
| 419 | struct rte_acl_indices *indices, |
| 420 | struct rte_acl_bld_trie *node_bld_trie, uint32_t num_tries, |
| 421 | uint64_t no_match) |
| 422 | { |
| 423 | uint32_t n; |
| 424 | |
| 425 | memset(indices, 0, sizeof(*indices)); |
| 426 | memset(counts, 0, sizeof(*counts)); |
| 427 | |
| 428 | /* Get stats on nodes */ |
| 429 | for (n = 0; n < num_tries; n++) { |
| 430 | acl_count_trie_types(counts, node_bld_trie[n].trie, |
| 431 | no_match, 1); |
| 432 | } |
| 433 | |
| 434 | indices->dfa_index = RTE_ACL_DFA_SIZE + 1; |
| 435 | indices->quad_index = indices->dfa_index + |
| 436 | counts->dfa_gr64 * RTE_ACL_DFA_GR64_SIZE; |
| 437 | indices->single_index = indices->quad_index + counts->quad_vectors; |
| 438 | indices->match_start = indices->single_index + counts->single + 1; |
| 439 | indices->match_start = RTE_ALIGN(indices->match_start, |
| 440 | (XMM_SIZE / sizeof(uint64_t))); |
| 441 | indices->match_index = 1; |
| 442 | } |
| 443 | |
| 444 | /* |
| 445 | * Generate the runtime structure using build structure |
no test coverage detected