- /* Table */
- for (table_id = port_in->table_id; pkts_mask != 0; ) {
- struct rte_table *table;
- uint64_t lookup_hit_mask, lookup_miss_mask;
-
- /* Lookup */
- table = &p->tables[table_id];
- table->ops.f_lookup(table->h_table, p->pkts, pkts_mask,
- &lookup_hit_mask, (void **) p->entries);
- lookup_miss_mask = pkts_mask & (~lookup_hit_mask);
-
- /* Lookup miss */
- if (lookup_miss_mask != 0) {
- struct rte_pipeline_table_entry *default_entry =
- table->default_entry;
-
- /* Table user actions */
- if (table->f_action_miss != NULL) {
- uint64_t mask = lookup_miss_mask;
-
- table->f_action_miss(p->pkts,
- &lookup_miss_mask,
- default_entry, table->arg_ah);
- mask ^= lookup_miss_mask;
- p->action_mask0[RTE_PIPELINE_ACTION_DROP] |= mask;
- RTE_PIPELINE_STATS_ADD_M(
- table->n_pkts_dropped_by_lkp_miss_ah, mask);
- }
-
- /* Table reserved actions */
- if ((default_entry->action ==
- RTE_PIPELINE_ACTION_PORT) &&
- (lookup_miss_mask != 0))
- rte_pipeline_action_handler_port_bulk(p,
- lookup_miss_mask,
- default_entry->port_id);
- else {
- uint32_t pos = default_entry->action;
-
- p->action_mask0[pos] = lookup_miss_mask;
- if (pos == RTE_PIPELINE_ACTION_DROP) {
- RTE_PIPELINE_STATS_ADD_M(table->n_pkts_dropped_lkp_miss,
- lookup_miss_mask);
- }
- }
- }
+ /* Input port user actions */
+ if (port_in->f_action != NULL) {
+ port_in->f_action(p, p->pkts, n_pkts, port_in->arg_ah);
+
+ RTE_PIPELINE_STATS_AH_DROP_READ(p,
+ port_in->n_pkts_dropped_by_ah);
+ }
+
+ /* Table */
+ for (table_id = port_in->table_id; p->pkts_mask != 0; ) {
+ struct rte_table *table;
+ uint64_t lookup_hit_mask, lookup_miss_mask;