3 /** \brief Set flags on the interface
4 @param client_index - opaque cookie to identify the sender
5 @param context - sender context, to match reply w/ request
6 @param sw_if_index - index of the interface to set flags on
7 @param admin_up_down - set the admin state, 1 = up, 0 = down
8 @param link_up_down - Oper state sent on change event, not used in config.
10 autoreply define sw_interface_set_flags
15 /* 1 = up, 0 = down */
19 /** \brief Set interface MTU
20 @param client_index - opaque cookie to identify the sender
21 @param context - sender context, to match reply w/ request
22 @param sw_if_index - index of the interface to set MTU on
25 autoreply define sw_interface_set_mtu
33 /** \brief Interface Event generated by want_interface_events
34 @param client_index - opaque cookie to identify the sender
35 @param pid - client pid registered to receive notification
36 @param sw_if_index - index of the interface of the event
37 @param admin_up_down - The administrative state; 1 = up, 0 = down
38 @param link_up_down - The operational state; 1 = up, 0 = down
39 @param deleted - interface was deleted
41 define sw_interface_event
51 /** \brief Register for interface events
52 @param client_index - opaque cookie to identify the sender
53 @param context - sender context, to match reply w/ request
54 @param enable_disable - 1 => register for events, 0 => cancel registration
55 @param pid - sender's pid
57 autoreply define want_interface_events
65 /** \brief Interface details structure (fix this)
66 @param sw_if_index - index of the interface
67 @param sup_sw_if_index - index of parent interface if any, else same as sw_if_index
68 @param l2_address_length - length of the interface's l2 address
69 @param pid - the interface's l2 address
70 @param interface_name - name of the interface
71 @param link_duplex - 1 if half duplex, 2 if full duplex
72 @param link_speed - 1 = 10M, 2 = 100M, 4 = 1G, 8 = 10G, 16 = 40G, 32 = 100G
73 @param link_MTU - max. transmittion unit
74 @param sub_if_id - A number 0-N to uniquely identify this subif on super if
75 @param sub_dot1ad - 0 = dot1q, 1 = dot1ad
76 @param sub_dot1ah - 1 = dot1ah, 0 = otherwise
77 @param sub_number_of_tags - Number of tags (0 - 2)
78 @param sub_outer_vlan_id
79 @param sub_inner_vlan_id
80 @param sub_exact_match
82 @param sub_outer_vlan_id_any
83 @param sub_inner_vlan_id_any
84 @param vtr_op - vlan tag rewrite operation
88 @param pbb_outer_tag - translate pbb s-tag
89 @param pbb_b_dmac[6] - B-tag remote mac address
90 @param pbb_b_smac[6] - B-tag local mac address
91 @param pbb_b_vlanid - B-tag vlanid
92 @param pbb_i_sid - I-tag service id
94 define sw_interface_details
99 /* index of sup interface (e.g. hw interface).
100 equal to sw_if_index for super hw interface. */
103 /* Layer 2 address, if applicable */
104 u32 l2_address_length;
108 u8 interface_name[64];
110 /* 1 = up, 0 = down */
114 /* 1 = half duplex, 2 = full duplex */
117 /* 1 = 10M, 2 = 100M, 4 = 1G, 8 = 10G, 16 = 40G, 32 = 100G */
123 /* Subinterface ID. A number 0-N to uniquely identify this subinterface under the super interface */
126 /* 0 = dot1q, 1=dot1ad */
128 /* 1 = dot1h, 1=otherwise */
131 /* Number of tags 0-2 */
132 u8 sub_number_of_tags;
133 u16 sub_outer_vlan_id;
134 u16 sub_inner_vlan_id;
137 u8 sub_outer_vlan_id_any;
138 u8 sub_inner_vlan_id_any;
140 /* vlan tag rewrite state */
142 u32 vtr_push_dot1q; // ethertype of first pushed tag is dot1q/dot1ad
143 u32 vtr_tag1; // first pushed tag
144 u32 vtr_tag2; // second pushed tag
147 /* pbb tag rewrite info */
156 define sw_interface_dump
160 u8 name_filter_valid;
164 /** \brief Set or delete one or all ip addresses on a specified interface
165 @param client_index - opaque cookie to identify the sender
166 @param context - sender context, to match reply w/ request
167 @param sw_if_index - index of the interface to add/del addresses
168 @param is_add - add address if non-zero, else delete
169 @param is_ipv6 - if non-zero the address is ipv6, else ipv4
170 @param del_all - if non-zero delete all addresses on the interface
171 @param address_length - address length in bytes, 4 for ip4, 16 for ip6
172 @param address - array of address bytes
174 autoreply define sw_interface_add_del_address
186 /** \brief Associate the specified interface with a fib table
187 @param client_index - opaque cookie to identify the sender
188 @param context - sender context, to match reply w/ request
189 @param sw_if_index - index of the interface
190 @param is_ipv6 - if non-zero ipv6, else ipv4
191 @param vrf_id - fib table/vrd id to associate the interface with
193 autoreply define sw_interface_set_table
202 /** \brief Get VRF id assigned to interface
203 @param client_index - opaque cookie to identify the sender
204 @param context - sender context, to match reply w/ request
205 @param sw_if_index - index of the interface
207 define sw_interface_get_table
215 /** \brief Reply to get_sw_interface_vrf
216 @param context - sender context which was passed in the request
217 @param vrf_id - VRF id assigned to the interface
219 define sw_interface_get_table_reply
226 typeonly manual_print manual_endian define vlib_counter
228 u64 packets; /**< packet counter */
229 u64 bytes; /**< byte counter */
232 /** \brief Combined interface counter data type for vnet_interface_combined_counters
233 @param sw_if_index - interface indexes for counters
234 @param rx_packets - received packet count
235 @param rx_bytes - received byte count
236 @param tx_packets - transmitted packet count
237 @param tx_bytes - transmitted byte count
240 typeonly manual_print manual_endian define vnet_combined_counter
243 u64 rx_packets; /**< packet counter */
244 u64 rx_bytes; /**< byte counter */
245 u64 tx_packets; /**< packet counter */
246 u64 tx_bytes; /**< byte counter */
249 /** \brief Simple interface counter data type for vnet_interface_simple_counters
250 @param sw_if_index - interface indexes for counters
251 @param drop - RX or TX drops due to buffer starvation
252 @param punt - used with VNET "punt" disposition
253 @param rx_ip4 - received IP4 packets
254 @param rx_ip6 - received IP6 packets
255 @param rx_no_buffer - no RX buffers available
256 @param rx_miss - receive misses
257 @param rx_error - receive errors
258 @param tx_error - transmit errors
259 @param rx_mpls - received MPLS packet
262 typeonly manual_print manual_endian define vnet_simple_counter
276 /** \brief Simple stats counters structure
277 @param vnet_counter_type- such as ip4, ip6, punts, etc
278 @param first_sw_if_index - first sw index in block of index, counts
279 @param count - number of counters, equal to the number of interfaces in
281 @param data - contiguous block of u64 counters
283 vnet_counter_type defined in enums - plural - in vnet/interface.h
285 manual_print manual_endian define vnet_interface_simple_counters
287 u8 vnet_counter_type;
288 u32 first_sw_if_index;
293 /** \brief Combined stats counters structure
294 @param vnet_counter_type- such as ip4, ip6, punts, etc
295 @param first_sw_if_index - first sw index in block of index, counts
296 @param count - number of counters, equal to the number of interfaces in
298 @param data - contiguous block of vlib_counter_t structures
300 vnet_counter_type defined in enums - plural - in vnet/interface.h
302 manual_print manual_endian define vnet_interface_combined_counters
304 u8 vnet_counter_type;
305 u32 first_sw_if_index;
307 vl_api_vlib_counter_t data[count];
311 /** \brief Simple per interface stats counters structure
312 @param count - number of elements in message
313 @param timestamp - u32 vlib timestamp for control plane
314 @param data[count] - vl_api_vnet_simple_counter_t
317 manual_print manual_endian define vnet_per_interface_simple_counters
321 vl_api_vnet_simple_counter_t data[count];
324 /** \brief Combined stats counters structure per interface
325 @param count - number of elements in message
326 @param timestamp - u32 vlib timestamp for control plane
327 @param data[count] - vl_api_vnet_combined_counter_t
329 manual_print manual_endian define vnet_per_interface_combined_counters
333 vl_api_vnet_combined_counter_t data[count];
336 /** \brief Set unnumbered interface add / del request
337 @param client_index - opaque cookie to identify the sender
338 @param context - sender context, to match reply w/ request
339 @param sw_if_index - interface with an IP address
340 @param unnumbered_sw_if_index - interface which will use the address
341 @param is_add - if non-zero set the association, else unset it
343 autoreply define sw_interface_set_unnumbered
347 u32 sw_if_index; /* use this intfc address */
348 u32 unnumbered_sw_if_index; /* on this interface */
352 /** \brief Clear interface statistics
353 @param client_index - opaque cookie to identify the sender
354 @param context - sender context, to match reply w/ request
355 @param sw_if_index - index of the interface to clear statistics
357 autoreply define sw_interface_clear_stats
364 /** \brief Set / clear software interface tag
365 @param client_index - opaque cookie to identify the sender
366 @param context - sender context, to match reply w/ request
367 @param sw_if_index - the interface
368 @param add_del - 1 = add, 0 = delete
369 @param tag - an ascii tag
371 autoreply define sw_interface_tag_add_del
380 /** \brief Set an interface's MAC address
381 @param client_index - opaque cookie to identify the sender
382 @param context - sender context, to match reply w/ request
383 @param sw_if_index - the interface whose MAC will be set
384 @param mac_addr - the new MAC address
386 autoreply define sw_interface_set_mac_address
394 /** \brief Set an interface's rx-mode
395 @param client_index - opaque cookie to identify the sender
396 @param context - sender context, to match reply w/ request
397 @param sw_if_index - the interface whose rx-mode will be set
398 @param queue_id_valid - 1 = the queue_id field is valid. 0 means all
400 @param queue_id - the queue number whose rx-mode will be set. Only valid
401 if queue_id_valid is 1
402 @param mode - polling=1, interrupt=2, adaptive=3
404 autoreply define sw_interface_set_rx_mode
416 * eval: (c-set-style "gnu")