void
adj_midchain_setup (adj_index_t adj_index,
adj_midchain_fixup_t fixup,
+ const void *data,
adj_flags_t flags)
{
u32 feature_index, tx_node;
adj = adj_get(adj_index);
adj->sub_type.midchain.fixup_func = fixup;
+ adj->sub_type.midchain.fixup_data = data;
adj->ia_flags |= flags;
arc_index = adj_midchain_get_feature_arc_index_for_link_type (adj);
void
adj_nbr_midchain_update_rewrite (adj_index_t adj_index,
adj_midchain_fixup_t fixup,
+ const void *fixup_data,
adj_flags_t flags,
u8 *rewrite)
{
*/
ASSERT(NULL != rewrite);
- adj_midchain_setup(adj_index, fixup, flags);
+ adj_midchain_setup(adj_index, fixup, fixup_data, flags);
/*
* update the rewirte with the workers paused.
ip_adjacency_t * adj = adj_get(index);
s = format (s, "%U", format_vnet_link, adj->ia_link);
- s = format (s, " via %U ",
- format_ip46_address, &adj->sub_type.nbr.next_hop);
+ s = format (s, " via %U",
+ format_ip46_address, &adj->sub_type.nbr.next_hop,
+ adj_proto_to_46(adj->ia_nh_proto));
s = format (s, " %U",
format_vnet_rewrite,
&adj->rewrite_header, sizeof (adj->rewrite_data), indent);
.dv_lock = adj_dpo_lock,
.dv_unlock = adj_dpo_unlock,
.dv_format = format_adj_midchain,
+ .dv_get_urpf = adj_dpo_get_urpf,
};
/**