Another good example is vxlan.
Not sure what will happen if multiple graph nodes are fighting for the
same port though.
Ray K
https://git.fd.io/vpp/tree/src/vnet/vxlan/vxlan.c
|clib_error_t *vxlan_init (vlib_main_t *vm) { vxlan_main_t * vxm =
&vxlan_main; vxm->vnet_main = vnet_get_main(); vxm->vlib_main = vm; /*
initialize the ip6 hash */ vxm->vxlan6_tunnel_by_key =
hash_create_mem(0, sizeof(vxlan6_tunnel_key_t), sizeof(uword));
vxm->vtep6 = hash_create_mem(0, sizeof(ip6_address_t), sizeof(uword));
vxm->mcast_shared = hash_create_mem(0, sizeof(ip46_address_t),
sizeof(mcast_shared_t)); udp_register_dst_port (vm, UDP_DST_PORT_vxlan,
vxlan4_input_node.index, /* is_ip4 */ 1); udp_register_dst_port (vm,
UDP_DST_PORT_vxlan6, vxlan6_input_node.index, /* is_ip4 */ 0);
fib_node_register_type(FIB_NODE_TYPE_VXLAN_TUNNEL, &vxlan_vft); return
0; } |
On 04/12/2017 08:19, Klement Sekera -X (ksekera - PANTHEON TECHNOLOGIES
at Cisco) wrote:
Are you implementing a new graph node, which consumes UDP traffic? If so, then
the BFD example is a way to redirect interesting traffic to your new node...
-----Original Message-----
From: lin huang [mailto:mit...@outlook.com]
Sent: Monday, December 4, 2017 9:16 AM
To: Klement Sekera -X (ksekera - PANTHEON TECHNOLOGIES at Cisco)
<ksek...@cisco.com>; vpp-dev@lists.fd.io
Subject: RE: [vpp-dev] FW: how to redirect specific UDP port data to a new
node?
Hi Klement,
I want to redirect data to a new udp port. Do I need to modify VPP
code?
Adding a new UDP_DST_PORT_xxxx enum types??
Thanks a lot!!!
-----Original Message-----
From: Klement Sekera -X (ksekera - PANTHEON TECHNOLOGIES at Cisco)
[mailto:ksek...@cisco.com]
Sent: Monday, December 04, 2017 4:12 PM
To: lin huang <mit...@outlook.com>; vpp-dev@lists.fd.io
Subject: RE: [vpp-dev] FW: how to redirect specific UDP port data to a
new node?
Hi Lin Huang,
You can take a look at bfd_udp_init() in bfd_udp.c to see how the BFD
feature registers to listen on BFD ports using udp_register_dst_port().
Thanks,
Klement
-----Original Message-----
From: vpp-dev-boun...@lists.fd.io
[mailto:vpp-dev-boun...@lists.fd.io]
On Behalf Of lin huang
Sent: Monday, December 4, 2017 9:03 AM
To: vpp-dev@lists.fd.io
Subject: [vpp-dev] FW: how to redirect specific UDP port data to a new
node?
From: lin huang
Sent: Monday, December 04, 2017 2:53 PM
To: vpp-dev-boun...@lists.fd.io
Subject: how to redirect specific UDP port data to a new node?
Hi, all.
I want to know how to redirect specific UDP port data to a
new
node?
Dose udp_register_dst_port make effecet? Or using the arc with feature?
Thanks!!!
_______________________________________________
vpp-dev mailing list
vpp-dev@lists.fd.io
https://lists.fd.io/mailman/listinfo/vpp-dev
_______________________________________________
vpp-dev mailing list
vpp-dev@lists.fd.io
https://lists.fd.io/mailman/listinfo/vpp-dev