FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
tx_queue_funcs.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: Apache-2.0
2  * Copyright(c) 2021 Cisco Systems, Inc.
3  */
4 
5 #include <vnet/vnet.h>
6 
7 /* funciton declarations */
8 
10  u32 queue_id);
12  u32 queue_id);
13 void vnet_hw_if_unregister_tx_queue (vnet_main_t *vnm, u32 queue_index);
14 void vnet_hw_if_unregister_all_tx_queues (vnet_main_t *vnm, u32 hw_if_index);
15 void vnet_hw_if_tx_queue_assign_thread (vnet_main_t *vnm, u32 queue_index,
19 
20 /* inline functions */
21 
24 {
26  if (pool_is_free_index (im->hw_if_tx_queues, queue_index))
27  return 0;
28  return pool_elt_at_index (im->hw_if_tx_queues, queue_index);
29 }
im
vnet_interface_main_t * im
Definition: interface_output.c:395
thread_index
u32 thread_index
Definition: nat44_ei_hairpinning.c:492
vnet_hw_if_register_tx_queue
u32 vnet_hw_if_register_tx_queue(vnet_main_t *vnm, u32 hw_if_index, u32 queue_id)
Definition: tx_queue.c:35
pool_elt_at_index
#define pool_elt_at_index(p, i)
Returns pointer to element at given index.
Definition: pool.h:553
vnet_hw_if_unregister_tx_queue
void vnet_hw_if_unregister_tx_queue(vnet_main_t *vnm, u32 queue_index)
Definition: tx_queue.c:62
vnet_interface_main_t
Definition: interface.h:989
vnet_hw_if_tx_queue_unassign_thread
void vnet_hw_if_tx_queue_unassign_thread(vnet_main_t *vnm, u32 queue_index, u32 thread_index)
Definition: tx_queue.c:120
vnet_hw_if_tx_queue_assign_thread
void vnet_hw_if_tx_queue_assign_thread(vnet_main_t *vnm, u32 queue_index, u32 thread_index)
Definition: tx_queue.c:109
vnet_hw_if_get_tx_queue_index_by_id
u32 vnet_hw_if_get_tx_queue_index_by_id(vnet_main_t *vnm, u32 hw_if_index, u32 queue_id)
Definition: tx_queue.c:25
pool_is_free_index
#define pool_is_free_index(P, I)
Use free bitmap to query whether given index is free.
Definition: pool.h:302
static_always_inline
#define static_always_inline
Definition: clib.h:112
vnet_hw_if_unregister_all_tx_queues
void vnet_hw_if_unregister_all_tx_queues(vnet_main_t *vnm, u32 hw_if_index)
Definition: tx_queue.c:86
vnet_hw_if_get_tx_queue
static_always_inline vnet_hw_if_tx_queue_t * vnet_hw_if_get_tx_queue(vnet_main_t *vnm, u32 queue_index)
Definition: tx_queue_funcs.h:23
vnet_main_t
Definition: vnet.h:76
u32
unsigned int u32
Definition: types.h:88
vnet_hw_if_tx_queue_t
Definition: interface.h:602
vnet_interface_main_t::hw_if_tx_queues
vnet_hw_if_tx_queue_t * hw_if_tx_queues
Definition: interface.h:999
vnet.h
vnet_main_t::interface_main
vnet_interface_main_t interface_main
Definition: vnet.h:81